The RedBot MainBoard is a versatile and user-friendly robotic platform designed to serve as the central unit for building and controlling small robots. It integrates motor drivers, a built-in accelerometer, and line following sensors, making it an ideal choice for educational purposes, hobbyists, and prototype development. Common applications include autonomous vehicles, educational robots, and hobbyist robotic projects.
Pin Number | Function | Description |
---|---|---|
1-7 | Digital I/O | General purpose digital input/output pins |
8-13 | PWM/Digital I/O | PWM output capable pins and digital I/O |
A0-A4 | Analog Input | Analog sensor inputs for line following sensors |
A5 | I2C SCL | I2C clock line |
A6 | I2C SDA | I2C data line |
A7 | Interrupt | External interrupt for additional sensors |
VIN | Voltage Input | Input voltage for the board (6V to 9V recommended) |
GND | Ground | Ground connection |
5V | 5V Output | Regulated 5V output |
3V3 | 3.3V Output | Regulated 3.3V output |
RST | Reset | Reset pin for the microcontroller |
RX0, TX0 | UART | UART communication pins |
// Include the RedBot library
#include <RedBot.h>
// Instantiate a motor object
RedBotMotor motor;
void setup() {
// Set the baud rate for serial communication
Serial.begin(9600);
}
void loop() {
// Drive both motors forward at full speed
motor.drive(255); // 255 is the maximum speed value
delay(2000); // Drive forward for 2 seconds
// Stop the motors
motor.brake();
delay(1000); // Wait for 1 second
// Drive both motors in reverse at half speed
motor.drive(-127); // Negative values for reverse direction
delay(2000); // Drive reverse for 2 seconds
// Stop the motors
motor.brake();
delay(1000); // Wait for 1 second
}
Q: Can I use the RedBot MainBoard with other microcontrollers? A: The RedBot MainBoard is designed to be compatible with the Arduino Uno form factor, but it can be used with other microcontrollers that support the same pin configuration and voltage levels.
Q: How do I update the firmware on the RedBot MainBoard? A: The RedBot MainBoard uses the standard Arduino bootloader, so you can update the firmware using the Arduino IDE.
Q: What is the maximum number of motors I can control with the RedBot MainBoard? A: The onboard TB6612FNG motor driver can control up to two DC motors. Additional motors would require external motor driver modules.
Q: Can I power the RedBot MainBoard using a USB connection? A: While the board can be powered via USB for programming, it is recommended to use an external power supply for motor operation to provide sufficient current.