Spine Iron

by wittmermomo in Circuits > Arduino

365 Views, 5 Favorites, 0 Comments

Spine Iron

spine iron

Do you know someone whose posture is projected to land them in retirement before they even join the workforce?

I’m sure all of us know at least one person who is good at everything except sitting up straight. We believe the secret to their genius is their shrimp-like slouch. But don’t worry, we now have a way to make them as useless as the rest of us. Introducing the SpineIron, a robot that makes your laptop mirror your posture, losing functionality at the same rate as your spine! In just three days, you could create your very own.

Supplies

Supplies_wip full.png

Electronics:

  1. Arduino Uno + cable to USB port
  2. 2 Breadboards
  3. 12V power supply
  4. Jumper wires
  5. Gear DC motor 25GA-370 12V

Sensors:

  1. L293D H-Bridge
  2. Gyroscope MPU6050
  3. Pushbutton
  4. 1 Resistor (1000 Ohms)
  5. 2 Resistors (200 Ohms)
  6. 2 Tilt sensors
  7. Wire

DIY Motor rotation counter sensor:

  1. Copper wire
  2. Rubber band
  3. Jumper wires
  4. Long screw

Mechanics:

  1. Wood board (approx. 30 cm x 60 cm)
  2. 3D printed parts
  3. Stiff cord
  4. 2 Springs (⌀ 5.7 mm, length: 59.2 mm)
  5. Threaded rod (⌀ 8mm)
  6. 12 Ball bearings (outer ⌀ 22mm, inner ⌀: 8mm, depth: 7 mm)
  7. Coupling (8mm)
  8. 23 M8 Nuts
  9. Assorted screws
  10. 4 Eye hooks (8mm hole)
  11. Foldback clip
  12. Steel plates
  13. Duct tape

Assembly

001.gif
useless mechanics

MECHANICS

  1. Ensure the base plate you have chosen is big enough to fit both the frame and laptop. You can optionally pre drill the holes for the eye hooks and motor brackets.
  2. Press the ball bearings into the respective holes in the 3D printed frame components. The holes may require a bit of sanding, but just enough so that the bearings are still securely friction fit.
  3. Measure and fix the eye hooks so that they are ?? mm apart.
  4. Slide the base (lower) rods through the eye hooks and for each rod fit a vertical frame component, two nuts, a pulley wheel, two more nuts, and another vertical frame component. Slide the rods through the opposite eye hooks and secure with an extra nut on each side.
  5. Install the top rods and horizontal frame parts as shown and don’t forget the nuts sandwiching each pair of vertical and horizontal frame components.
  6. Adjust all of the nuts and frame components such that the frame is rectilinear and doesn’t have any torsion.
  7. Screw the 3D-printed motor bracket onto your motor.
  8. Fix the motor bracket to the baseplate. The exact placement doesn’t matter too much, but consider the space the coupling and spindle will take up as well.
  9. Secure the coupling onto the motor shaft, followed by the shorter threaded rod (the spindle) on the other side.
  10. Slide on the spindle brackets and screw these into the base plate. These prevent moment from being applied to the motor by the cords.
  11. Tie the ends of the cord to the springs.
  12. Attach one spring to an upper rod. This may require some wire. Then, while tensioned, wind the cord around the pulley wheel diagonally across, seven times around the spindle, and then back around the other pulley wheel, finally attaching it to the other upper rod.

SENSORS & ELECTRONICS

  1. Install the tilt sensors and rotation sensor as specified in the sensors section.
  2. Install the integration box or platform for your electronics. Here, we screwed some metal plates into the base plate beside the motor to hold the Arduino and one of the breadboards.
  3. Wire up the circuit and position the electronics how you see fit.
  4. Secure all the cables to the frame or base plate using tape to prevent them from shifting during operation.
  5. Connect the motor control wires from the Arduino to the motor as per the wiring diagram.
  6. Attach the rotary sensor to the Arduino using the appropriate pins and ensure it is aligned correctly.
  7. Connect the tilt sensors to the Arduino following the sensor orientation and placement guidelines.

FINAL STEPS

  1. Install the laptop-specific grips onto the frame to hold the device in place securely.
  2. Attach the foldback clamp, foam padding, and rope as needed to further stabilize and protect the laptop.
  3. Place the laptop onto the frame and adjust all grips and supports to ensure a snug fit.
  4. Connect the Arduino to the laptop using a USB cable.
  5. Plug the 12-volt power supply into a wall outlet to provide power to the system.
  6. Finally, securely attach the gyroscope board to the user, making sure it is positioned properly for accurate movement tracking.

Sensors

sensors.png

DIY Rotation Sensor

In order to match the motion of the motor to the angle of the user’s back, you will need some way of counting the rotations or rotational speed of your motor. This can be done with a rotary encoder or by substituting the current motor with a stepper motor. Or you could simply have another gyroscope on the frame. However, if these are not viable for you, you can create your own rotation sensor like we did. For this you need to set up a circuit where the rotating metal components (shaft, coupling, or spindle) acts like a switch for a simple circuit where the Arduino reads a voltage. Here, we used the coupling as a switch by adding four strips of electrical tape to be able to detect every quarter turn of the motor. The accuracy in this sensor lies in the ability of the ‘pole’ of the switch (the copper wire in this case) to stay in contact with the throw (the rotating metal part). The setup can look something like this: the wire taped to the motor is the throw and connects to 5V from the Arduino while the copper wire is connected to ground.


Tilt Sensors

In addition to the rotation sensor, it is useful to have a sensor that detects when the frame’s angle limits have been reached. Otherwise, the frame may fall into an unrecoverable state. For this, you can use a gyroscope as previously mentioned or two tilt sensors attached to the frame. Glue the tilt sensors in the orientation shown in the above video and follow the circuit wiring diagram.


Gyroscope

The gyroscope needs five very long wires to connect its pins to the arduino because of the distance from the user’s back to the motor. It helps to mark the ends of each wire with tape and the pin it should connect to.

Electronics

circuit_image.png
Screenshot 2025-06-09 182420.png

Integration

This workflow describes the integration from a user's back to the automated folding mechanism of a laptop.

  1. Tilt Detection: A gyroscope sensor measures the tilt angle of the user's back. This real-time posture data is transmitted to an Arduino microcontroller for processing.
  2. Angle Mapping: The measured tilt angle is mapped to a corresponding target angle for the laptop's folding mechanism, determining how much the device should move in response to the user's posture.
  3. Motor Activation and Control: A DC motor is engaged to adjust the folding mechanism. It rotates until one of the following conditions is met:
  4. The target angle is reached (estimated using rotation feedback),
  5. A timeout threshold is exceeded,
  6. Or a boundary condition is detected via tilt sensors positioned at the motion limits.
  7. Motor Rotation Estimation: Since standard DC motors lack precise positional control, an auxiliary sensor estimates rotation by detecting voltage fluctuations in the motor wiring. This provides a rough approximation of how far the motor has turned.
  8. Folding Adjustment: Based on the detected posture and estimated motor position, the system adjusts the folding mechanism accordingly, effectively folding or unfolding the laptop in real time to reflect the user's posture.

https://app.cirkitdesigner.com/project/b8f4f9ab-3900-4dd5-8287-ad47d0d9e9ef

Code


Tuning parameters:

kMotorRotationFactor: Scales the motor rotation estimate.

outputEvery: Sets frequency of pitch comparison (every N cycles).

kDelayTime: Loop delay (5ms) for system responsiveness.


Function Descriptions

handleSwitchToggle()

  1. Implements debouncing.
  2. Switches systemActive flag with delays to avoid bouncing.

readMpu6050(outputEvery)

  1. Reads raw accelerometer values.
  2. Computes pitch and roll angles using trigonometry.
  3. Performs calibration during the first 3 seconds.
  4. Computes the difference in pitch (diffPitch) every outputEvery frames.
  5. Triggers motor activation if pitch deviation exceeds ±1.5°.

controlMotor(diffRoll, run, direction, detector)

  1. Controls motor direction and speed via digital writes.
  2. Turns the motor off if not running.
  3. Sets direction and activates runDetector when motion starts.

detectRotation()

  1. Uses a copper coil to monitor rotation.
  2. Increments the rotation count when a pulse edge is detected.
  3. Stops motor if pitch correction exceeds threshold (with safety margin).

Also halts motor if:

  1. Timeout exceeds 4 seconds.
  2. Tilt sensors detect a physical boundary.

checkTiltBoundary()

  1. Reads tilt sensors.
  2. Detects if a tilt boundary (top or bottom) is reached based on diffPitch direction.
  3. Prevents over-rotation by stopping the motor.


Downloads

References / Where to Nab Your Parts

Mechanics inspiration: https://hackaday.com/2024/06/03/gears-are-old-and-busted-capstans-are-cool/

Arduino Libraries: wire.h, math.h

Reused Parts: Power supply, 6 bearings, fasteners, plate, gyro,... salvaged from studio + borrowed from Rebecca and previous graduates