30

The LEGO Super Mario theme includes an intelligent brick that interacts with various other elements present in the sets:

enter image description here

There are several Power-up sets available that provide Mario with additional powers and alter his behavior in various ways. How does the brick interact with these power up packs to know when they are in use?

Here's an example power-up pack:

Cat Mario

1
  • Try doing 001001 It has weird effects... Commented Jan 28, 2022 at 21:07

1 Answer 1

38

The Mario element has six switches on the front:

Mario Element

The inside of the pants in the power-up sets include six plastic ridges that can be either high or low. They interact with the switches on Mario's torso in much the same way as the cuts on a key interact with a particular lock. The torso reads the pattern on the buttons to determine the power-up state. Here's an example showing the six ridges on the regular pants from the starter set and the ridges on Cat Mario:

Pants photo

The switches expect the following states for each of the pants elements (bits are read from left to right when looking at Mario):

Bit Pattern Power-up
000000 None
001100 Propeller
010001 Cat
010010 Fire
100001 Normal
100010 Builder

Power-ups can be emulated by holding in the correct buttons. The play experience won't be great, but this could be used to see what a power-up does if you don't own it.

There's more detail on exactly what is read and presented via the Bluetooth interface on Shinichiro Oba's Github.

It's worth noting that the included hats are for decoration only. They have no impact on behavior, and there is no mechanism for them to be detected or identified.

10
  • 14
    And here I was thinking "oh, they're probably using NFC, that's pretty cool…" Nope. Low tech FTW. :) Commented Sep 11, 2020 at 15:27
  • 4
    My kids had a train with blocks that had similar (each block gave a different pattern). Then they started holding down with their fingers different combos until they found non-Roman letters and then even a combo that locked it up. Commented Sep 11, 2020 at 18:31
  • 7
    @DarrelHoffman: I suspect they're trying for an N-out-of-M encoding (2 out of 6, in this case). That way, your Builder Mario won't suddenly turn into Cat Mario just because his pants are a little loose and one of the switches doesn't get pushed all the way in. (Admittedly, they could've still used e.g. a 4 bit parity code to achieve the same result, but 6 bits still indeed leaves more room for expansion, and maybe they just got a good deal on six-switch arrays or something.) Commented Sep 11, 2020 at 18:35
  • 6
    @IlmariKaronen I've confirmed that the bit value for the propeller pants is 001100 and opened a PR to change the hex value to 0C.
    – jncraton
    Commented Sep 11, 2020 at 23:38
  • 4
    @IlmariKaronen - Whenever you can get away with low tech - do it. It's simpler, easier to build, cheaper, more robust and durable. Well, most of the time anyway. And it's always so satisfying to see something complicated and impressive being achieved by something absolutely elementary. :)
    – Vilx-
    Commented Sep 13, 2020 at 11:54

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.