'Beating' Heart Plushie

by Adityadp in Circuits > Arduino

1035 Views, 6 Favorites, 0 Comments

'Beating' Heart Plushie

Screenshot 2022-11-19 at 2.01.29 PM.png

This project was designed as a Valentine's Day Gift. Handmade items always are far more personal, and a great opportunity to test your technical skills.


The final product is a heart-shaped pillow, which 'beats' when you press into it. Very similar to a plushie toy which speaks after you press it. The design is very simple with minimal parts and skills required, thus anyone looking to make their partner happy can build it.

Supplies

  1. Arduino Nano x1 (link)
  2. Electrical Wire
  3. Vibration Motor x1 (link)
  4. Thin Film Pressure Sensor (or any kind of strain gauge) x1 (link)
  5. Thick paper/card
  6. 1k Ohm Resistor x1
  7. NPN transistor (3904N, 2222N, BC547) x1
  8. 9V battery and connector x1 (This can be replaced with 6 x AA batteries and a respective holder)
  9. Perfboard x1
  10. Shirt buttons x2
  11. On/off switch x1

Tools

  1. Soldering iron and wire
  2. Desoldering pump
  3. Sewing needle and thread

Building the Circuit

Screenshot 2022-11-19 at 12.32.39 PM.png
20221118_122105.jpg
20221118_122145.jpg
20221118_132248.jpg
20221118_122205.jpg

There are two sections to the circuit: sensing the press and the motor activation.

Detecting the press of the heart can be achieved quite easily. A strain gauge or pressure sensor experiences a change in resistance, whenever its shape is deformed, which would happen if it was in the heart as it was pressed.

Therefore, by placing the strain gauge component in a potential divider circuit, the voltage across the sensor will vary depending on whether it's being deformed or not. We can use the analogRead function to allow the Arduino to detect this change in voltage across the sensor and act accordingly.


Activation of the motor is not as straightforward. The output current of the Arduino Nano is not sufficient to fully activate the vibration motor. Therefore a transistor is added to the circuit to act as a switch. When the base of the transistor is triggered, the collector and emitter of the transistor are connected completing the vibration motor and 9V battery circuit.

Finally, the Arduino Nano is powered by a 9V battery source connected to its VIN pin, since the entire circuit had to completely fit into the heart pillow and couldn't be powered with a cable sticking out.

The Code

The code is really straightforward. Part 1 is to detect the heart being pressed, and part 2 is to activate the vibration motor in the rhythm of a beating heart.


Part 1:

Connecting the Arduino Nano to my laptop I measured the analogRead values I was getting off the thin film sensor potential divider. And then I pressed the sensor to see what the values changed too. When unpressed, the analogRead function was outputting 1023 constantly. When pressed the value dropped to around 950.

Using that I set the threshold at anything less than 1020 will activate the heartbeat function


Part 2: (heartbeat function)

I played around with the delay values to get the most heartbeat-like vibration. When digitalWrite is HIGH, the motor is on. When digitalWrite is LOW the motor is off.

I made it so that the vibration motor will beat only 10 times and then return back to sensing for a press.


I have uploaded the code with comments to this step

Downloads

Testing the Circuit

WhatsApp Video 2022-11-19 at 12.46.11

Video of the circuit being tested before being placed into the heart

When the thin film sensor is flexed, the motor is activated to beat for 10 seconds and then returns back to normal

Protecting the Vibration Motor

20221118_135032.jpg

Since the vibration motor will be spinning quite fast, there is a chance it may tangle up with the stuffing and wires inside the pillow. Therefore to protect it, I created a tube out of thick card and taped it around the motor, shielding the motor from the stuffing and wires.

Final Assembly

20221118_132533.jpg
20221118_132526.jpg
20221118_141353.jpg

This step requires skill with a needle and thread. An incision is first made on the side of the pillow. Some of the stuffing will have to be removed to fit all of the circuitry through the gap.


Buttons are sewn onto one side of the cut and holes for the buttons are made on the other side of the cut. This opening is left accessible so the circuit and/or the battery can be easily replaced when it breaks down or runs out of power. After buttoning it up the stuffing is not visible.

Final Test

WhatsApp Video 2022-11-19 at 12.42.18

The heart can be seen to be vibrating from the paper on top after I've pressed the heart.