BLE Motor is a kind of motor driver board compatible with Arduino UNO. It has integrated BLE Bluetooth 4.0 module, MEGA328 main control and L298P motor driver, which can be used to drive one-channel stepping motor or two-channel DC motor. Benefit to the sensor port on BLE Motor, we can plug in all kinds of Octopus brick sensors directly. At the same time, it can support various Shield extension for it has Arduino Shield compatible connector. A BLE Motor equals the combination of “Arduino UNO + BLE module + Sensor Shield + L298P MOTOR Shield”. We have integrated all these modules together to avoid messy cabling and the instability it caused while the size is well-controlled. The integrated BLE 4.0 enables us to connect mobile more easily. It is a convenient development board for robotics and intelligent cars.
- Develop Environment: Arduino IDE, fully compatible with Arduino UNO
- BLE chip: TI CC2540
- Support Bluetooth HID
- Support Bluetooth serial port transparent transmission
- Support program updating by USB
- Micro-controller: ATMEGA328P
- Bootloader：Arduino UNO
- Auto shift input power
- ICSP download program interface
- With HC-11 433MHz RF module socket
- Carry two-channel 2A DC motor connector or one-channel stepping motor connector
- Input Voltage: DC 6-12V
- Size: 76.57mm X 69.23mm
- Weight: 40g
- Support Android and IOS mobile terminal use. Easy to use just like BLEduino.
- Built-in 3pin IO motor brick GVS extension port, compatible with ElecFreaks Octopus electric brick series.
- Can be used as development board for smart cars and mini balance cars.
- Users can develop mobile controlled robots or robot arms, etc..
3. Pins & Connectors:
|Bluetooth||BLE Bluetooth 4.0 Module|
|Micro USB||Micro USB communication port|
|Logic level switch||Footer voltage switch. Can shift between 3.3V and 5V.|
|ICSP||Bootloader Burning Port/Connector|
|SCK MISO MOSI||SPI Pin|
|RXD TXD||UART Serial Port Pin|
|SDA SCL||IIC Pin|
|SW1-SW5||Undefined Function Key|
|Power Switch||External Power Supply Switch|
|7-12V GND||Outer Power Supply Port|
|M1+ M1- M2+ M2-||Two-channel DC motor or one-channel stepping motor|
|RF Connector||CC1101 433MHz Wireless RF Transceiver Module Connector|
|LED PWR||Power Indicator|
|LED D13||D13 Indicator|
|LED ST1,ST2||Bluetooth Status Indicator|
4. Details about Partial Pins & Connectors:
a. Logic level switch:
When switched to 5V end, the footer operate voltage level of BLE MOTOR is 5V, which is the same with GVS red power supply port. Similarly, when we choose 3.3V, both BLE motor footeroperatevoltage and GVS red power supply port voltage is 3.3V. Therefore, we can connect 3.3V sensor directly without any voltage level transformation. It is more convenient to use.
Digital port D0-D13. V in GVS stands for VCC, G for GND, S for signal. GVS is standard sensor port which enables us to connect steering engine and all kinds of sensors easily. At the same time, it can support all of Octopus Bricks products.
Analog pin A0-A6. GVS port can connect steering engine and all kinds of sensors easily. It supports all of Octopus Bricks products.
d. Motor Control Switch Option Footer
Two connection methods in total. Different connections have different motor control methods. After disconnected, it can be used as common IO port.
Note: The silk mark on main board is wrong. And the right mark should be 4-M1, 5-E1, 6-E2, 7-M2.
- PWM Control Mode. This mode can connect jumper cap directly. D5 and D6 are PWM pins for controlling motor speed; D4 and D7 are used to control the positive and negative rotation of control motor.
Motor 1 Direction Control
Motor 1 Speed Control
Motor 2 Speed Control
|Motor 2 Direction Control|
- PLL Control Mode, i.e. Lock Loop Control Mode. Connect pins according to the picture below.
Motor 1 Start Control
Motor 1 Direction Control
Motor 2 Direction Control
Motor 2 Start Control
- When start control pin output high voltage level, the motor start move; when output low voltage level, it stop move.
- When PWM signal of direction control pin is median (about 100 or so, different motors have to be tested for it), the motor stops.
- Bigger PWM signal median deviation of direction control pin, the motor speed will be faster.
- When PWM signal of direction control pin is bigger than median, the motor rotates positively. Lower than median, it will rotate negatively.
1. Key Function Introduction:
PWM Function for speed control: analogWrite(pin, value)
Parameters： 1.pin: the pin to write to.analogWrite(pin, value)
Under DC motor control, it represents motor speed control pin.
2.value: the duty cycle: between 0 (always off) and 255 (always on).
Under DC control, it represents speed value. 0 is for minimum speed(stop) and 255 for maximum speed.
Direction control uses digital pin operate function: digitalWrite(pin, value)
Parameters pin: the pin numberdigitalWrite(pin, value)
Under DC motor control, it represents the motor’s corresponding pins in control end.
value: HIGH or LOW，
HIGH is for motor positive rotation, LOW is for motor negative rotation.
The code below can realize motor positive rotation in full speed.
int E1 = 5; //Define D5 as M1 speed control pin
int M1 = 4; //Define D4 as M1 direction control pin
analogWrite (E1, 255); // M1 full speed rotation
digitalWrite(M1, HIGH); // M1 positive rotation
Set baud rate:
1. Installation of operate environment and drive:
Based on Arduino UNO design, the usage of BLE Motor is as simple as Arduino UNO. It supports Arduino IDE programming and burning software. You don’t have to install any drives so that it can work properly.
1. Like the following picture showed: Plug into USB, we will see serial port number in computer device manager. (Com number will differentiate according to the practical situation.)
2. Open the sample code we provided and choose Arduino UNO, then we can start programming and software burning.
2. Wiring Diagram:
1. DC Motor connection:
2. Stepping Motor connection:
1. Search on Google Application Market or APP Store: BLE CENTER, download and install “BLE Center App”, then you can connect BLE MOTOR with mobile to realize remote control:
2. Burn the sample code we provided and connect DC motor according to the instruction.
3. Open BLECenter App. When we hear the vocal message of “connected”, then we have connected it successfully. Enter Console interface:
4. Use mobile Bluetooth to send “0” to “BLE MOTOR”. Motor 1 will rotate positively at first, then negatively, and stop in the end. Next, motor 2 will repeat the movement of motor 1.
5. When test is finished, it will return “0”. This shows everything is ok.
6. Press the button, we can see key value “SWX OK” on mobile.
4． Relative Parts:
Things we have to pay attention:
- When we shift voltage level switch to 5V, the current of red pins power output can reach 2A, while shifting to 3.3V, the maximum current of red pins power output is 800mA.
- Connect Serial port and Bluetooth together, one of them will have no signal. So they cannot use at the same time.
- Motors must have outer power supply, or we cannot drive it by USB only.
- The input current of Micro USB shall not over 500mA. Once it over 500mA, the fuse will enter into protection status. Then we have to cut off power supply and wait fuse cool down so that we can use it again.
5. Revision History
6. Contact Information
If you need more information, please log on: http://www.elecfreaks.com .