Xtreme STEM
DashX

RoboBloX

MagBlock

MagBlock

 

Theory

  • Hall Effect Sensors can detect a magnet field. If the magnet is the correct way around the sensor will send a signal to the Arduino.

    HallHall

 

 

 

Assembly

  1. Block
  2. SensorFront
    The sensor should be bent like the picture
    The wires should run past the back of the hall sensor.
  3. Pin
    Use a pin to bend the little black plastic "tongue" up

    Wire
    Gently slide the plastic housing off the ends of the wires
    Remove all 3 of the black plastic housings from the ends of the wires
  4. Wires
    Insert the ends of 2 of the wire into the block
    (From the inside of the block)
    You may need to push the ends of 2 wires through the hole before you can get the third through.

    Wires in
    Push the third wire through
  5. Pull
    Pull the wires through until the sensor is almost in the block
    Make sure it is the same way up as in the picture
    If you need to flip it over, pull it back to the ends of the wires, flip, and pull it back.
  6. Block
    Carefully position the sensor in the block
  7. Stop
    Check with Mr. Dash before continuing
  8. Glue
    Make sure you have all the materials in the picture before gluing
    (Extra Brick & Wax Paper)

    Glue
    Fill your block with hot glue
    Only use enough glue to cover the wires and sensor
    (too much and it will squish out the sides)
  9. Paper
    Cover the block with wax paper (baking paper)
  10. Gluing
    Place another block onto your MagBlock
    This makes sure the glue is squished down enough
  11. Wires

    Place all 3 wires into the connector so they match the diagram
    Mark the G side with a silver pen

 

 

Connection Diagram

  • Connect

    The MagBlock can be connected to any digital pin.
    (Don't use 0 or 1 as they are used for mBlock)

    Remember the silver stripe always goes to G (Ground).

 

 

 

mBlock

Hints

  • The MagBlock can only detect one pole (side) of a magnet.
    When testing the MagBlock try both sides of your magnet.
  • mblock
    You can check the signal from the MagBlock using a read digital pin block
    Each time you click on the block it will show true or false

    Remember it will be backward (active high)
    True (High) = No Magnet near sensor
    False (Low) = Magnet near sensor
  • mblock
    You can use a not block to flip the signal the right way around
    True (High) = Magnet near sensor
    False (Low) = No Magnet near sensor
  • mblock
    You can use a loop to display the result without having to click on it over and over

 

 

Magnet and Wand

  1. Mag
    The MagBlock can only detect one pole (side) of a magnet.

    You should figure out which side of your magnet works, and mark it with a marker.
  2. X
    Mark the side that doesn't activate the sensor with an X
  3. Dot
    Mark the side that activates the sensor with an dot
  4. Glow stickHot glue
    Hot-glue the X-end of the magnet to a glow-stick
  5. Heat shrink
    Cover the glow-stick and magnet with heat-shrink-tube
  6. Fire
    Carefully shrink the tubing with a lighter by
    Waving the flame back and forth
    and slowly spinning the stick
Scroll to Top