The BrainPower pack is handy for taking our BrainPad Pulse and wearing it to show off what we’ve created. The power pack contains a rechargeable battery, an on-board buzzer, and a vibration motor.
This assumes you’ve already assembled your BrainPower pack and are ready to learn more about it.
Charging the BrainPower pack
Make sure the rechargeable battery is plugged into the connector of BrainPower. Plug in a micro-USB connector into the charging port of BrainPower. You can use the same cord that came with your BrainPad Pulse. The Charge LED will illuminate. The battery will charge even when the BrainPower switch is turned off. The battery will be fully charged once the Charge LED turns off. Disconnect when transporting inside the case. The battery inside BrainPower is a Li-Po battery that requires special care. Please read the Safety Page carefully.
The BrainPower pack connects to the BrainPad Pulse through the edge connector. The pinout of the BrainPad is shown on its product page. This section shows the BrainPad pin connections on the BrainPower pack and its features.
Controlling the vibrator is done through Digital and Analog elements. The linked lessons have all the details, but here is everything you need to know.
The Vibrator can be controlled using a Digital pin. Setting the pin to 1 will enable the vibrator and 0 will turn it off. Let’s turn it on (activate it) for one second.
var pin = Digital(P1); Out(pin, 1); Wait(1); Out(pin, 0);
pin = Digital(P1) Out(pin, 1) Wait(1) Out(pin,0)
It is also possible to activate the vibrator at less than full power, like at 50% power.
var pin = Analog(P1); Out(pin, 100); Wait(1) Out(pin, 50); Wait(1); Out(pin, 0);
pin = Analog(P1) Out(pin, 100) Wait(1) Out(pin,50) Wait(1) Out(pin,0)
The buzzer is a passive element that is connected to a pin that supports Sound element (it has PWM feature). Let’s generate notes CDEF for one second each. If you search the web, these correspond to these frequencies: 523, 587, 659, 698. Setting the frequency to 0 will stop the sound.
var pin = Sound(P2,0,100); Out(pin, 523); Wait(1); Out(pin, 587); Wait(1); Out(pin, 659); Wait(1); Out(pin, 698); Wait(1); Out(pin, 0);
pin = Sound(P2,0,100) Out(pin, 523) Wait(1) Out(pin, 587) Wait(1) Out(pin, 659) Wait(1) Out(pin, 698) Wait(1) Out(pin, 0)
Let’s start coding something we can put on our BrainPad Pulse and use the BrainPower to take it with us. Now how about a countdown timer?
How does BrainPower differ from a modern smartwatch? On a basic level, they are the same thing! They have a processor, a display and battery. However, a modern smart watch will have a lot more sensors and a more capable processor to drive a high resolution color screen.