Skip to main content

Using a Whadda Vibration Motor Module

What is a Whadda Vibration Motor Module vibration motor?

VibrationWe already have a tutorial on how to use a vibration motor ison its own. The Whadda Vibration Motor Module simplifies this process by integrating all the essential components—such as a DCtransistor, motorcapacitor, inand diode—into a compactsingle sizemodule thatalong is used to informwith the users by vibrating on receiving signals. It is commonly found inside a mobile phone. The one that is available in the lab is coin vibration motor.

vibrationMotor.png

This

It requires more currnet than an Arduino pin can provide, soensures a transistorsafe isand neededstable circuit, allowing you to switcheasily control the motor currentwithout onneeding andto off.worry Any NPN transistor can be used. In this tutorial, we are using 2N2222. The diode acts as a surge protector against voltage spikes thatabout the motorelectronic maysetup.

produce. The 0.1µF capacitor absorbs voltage spikes produced when the brushes, which are contacts connecting electric current to the motor windings, open and close. To make sure that not too much current flow from the output of the transistor, we place a 1KΩ (or up to 5KΩ) in series with the base of the transistor.

Wiring

These are the electronics used in the circuit.

  1. vibrationG motorto GND
  2. 2N2222V transistorto (or any other NPN transistor)5V
  3. 0.1µFS capacitor
  4. to
  5. 1N4001pin diode
  6. 1KΩ resistor13

It is a quite complex circuit but try your best to follow!

Other NPN transistors
You can use other NPN transistors for this tutorial, BUT, they may have a different pinout with 2N2222. Check the pinout of your transistor and make sure the pins go as the following.

1. Emitter (E) to Ground (GND)
2. Base (B) to Data pin (pin 3) with 1KΩ resistor
3. Collector (C) to Ground of the actuator (black wire of the motor)

vibrationMotorCircuit.png

Getting started

This code is getting the motor to vibrate for 1 second and stop for 1 second.

int motorPin = 3;13; //motor transistor is connected to pin 3

void setup()
{
  pinMode(motorPin, OUTPUT);
}

void loop()
{
  digitalWrite(motorPin, HIGH); //vibrate
  delay(1000);  // delay one second
  digitalWrite(motorPin, LOW);  //stop vibrating
  delay(1000); //wait 50 seconds.
}