Romeo_BLE_mini_V2.0_SKU_DFR0351-DFRobot

DFR0351 Small Control Board

Introduction

Romeo BLE mini is a simplified version of Romeo board. It inherits all functions of Romeo BLE. Moreover, IT GOT A SMALLER SIZE! Yes, you got it all. It has 8 Digital pins, 4 analog pins and integrates Bluetooth 4.0 wireless communication function. And it can easy to drive the mobile platform using two 1.2A H-bridged Motor Driver to meet the needs of small scale robots. We hope Romeo BLE mini will be a good assistant to Makers.

Version Update: V2 has upgraded its motor driver IC, it replaces HR8833 with TB6612 motor driver chip. TB6612 has the same control logic with L298 motor driver. The code will be compatible with Romeo robot control board. And it finally breakouts 2 interrupt pins now! You can connect encoders to make PID motor control.

Features

Specification

Board Overview

DFR0351 Small Control Board Board Overview
Label Name Description
1 +VIN- Servo & Motor power input 6.5~10v
2 +Servo- Digital port power input 5~12V
3 M1 & M2 Terminals 2-Way Motor Controller:
Motor 1 : PIN4 (Direction), PIN5 (PWM Speed)
Motor 2 : PIN7 (Direction), PIN6 (PWM Speed)
4 I2C I2C interface (A4 & A5)
5 A 5V GND Gravity Analog Interface: A0, A1, A2, A3
6 D VCC GND Gravity Digital Interface: D2, D3, D8, D9, D10, D11, D12, D13;
7 LED light
PWR-power indicator
TX/RX-Data transmissing/receiving indicator
L-D13 led * LINK-Bluetooth link indicator
PAIR-Bluetooth pair indicator
8 RESET ATmega328P Reset button
9 BOOT Used for update BLE Firmware

Tutorial

In this tutorial, you can control two motors by enter("a","b","c","d","e") in Serial Monitor on PC.

Requirements

Connection Diagram

DFR0351 Small Control Board Connection Diagram

Sample Code

//Standard PWM DC control
int E1 = 5;     //M1 Speed Control
int E2 = 6;     //M2 Speed Control
int M1 = 4;    //M1 Direction Control
int M2 = 7;    //M1 Direction Control

void stop(void)                    //Stop
{
  digitalWrite(E1,LOW);
  digitalWrite(E2,LOW);
}
void advance(char a,char b)          //Move forward
{
  analogWrite (E1,a);      //PWM Speed Control
  digitalWrite(M1,HIGH);
  analogWrite (E2,b);
  digitalWrite(M2,HIGH);
}
void back_off (char a,char b)          //Move backward
{
  analogWrite (E1,a);
  digitalWrite(M1,LOW);
  analogWrite (E2,b);
  digitalWrite(M2,LOW);
}
void turn_L (char a,char b)             //Turn Left
{
  analogWrite (E1,a);
  digitalWrite(M1,LOW);
  analogWrite (E2,b);
  digitalWrite(M2,HIGH);
}
void turn_R (char a,char b)             //Turn Right
{
  analogWrite (E1,a);
  digitalWrite(M1,HIGH);
  analogWrite (E2,b);
  digitalWrite(M2,LOW);
}
void setup(void)
{
  int i;
  for(i=4;i<=7;i++)
    pinMode(i, OUTPUT);
  Serial.begin(9600);      //Set Baud Rate
  Serial.println("Run keyboard control");
}
void loop(void)
{
  if(Serial.available()){
    char val = Serial.read();
    if(val != -1)
    {
      switch(val)
      {
      case 'w'://Move Forward
        advance (255,255);   //move forward in max speed
        break;
      case 's'://Move Backward
        back_off (255,255);   //move back in max speed
        break;
      case 'a'://Turn Left
        turn_L (100,100);
        break;
      case 'd'://Turn Right
        turn_R (100,100);
        break;
      case 'z':
        Serial.println("Hello");
        break;
      case 'x':
        stop();
        break;
      }
    }
    else stop();
  }
}

BLE Configuration

Configure the BLE through AT command

There are three revolutionary BLE firmware versions now, maybe it will be more. For the reason of unified management, we will put all BLE AT command on the BLUNO wiki page Configure the BLE through AT command.

Bluno Beetle Basic Demo

In this section, you can use the Romeo BLE mini to connect with the Android phone or iPhone .The Step by Step tutorial of the Romeo BLE mini is almost the same with the Bluno.

Bluno Basic Demo

Wireless Programming via BLE

In this section, we will learn how to Upload the sketch on air via BLE. It is really amazing that you can do uploading process without a line.The Step by Step tutorial of the Romeo BLE mini is almost the same with the Bluno. How to Wireless Programming through BLE.

Update BLE Firmware

It is better to update the newest firmware for the better experience. As Romeo BLE mini is using CC2540 chip, the method of the updating is very close to BLUNO. Please choose "Bluno" firmware. Or it won't work. How to update the BLE firmware.

ICSP interface

image:Romeo_BLE_mini2.png|1 image:DFR0339 ICSP.png|2

FAQ

For any questions, advice or cool ideas to share, please visit the DFRobot Forum.

More Documents