Getting Started
Follow these steps to set up the UNI library and start programming your robot.
Installation
Method 1: Arduino Library Manager (Recommended)
- Open the Arduino IDE.
- Go to Sketch > Include Library > Manage Libraries...
- Search for
UNI/UniBase. - Click Install on the latest version.
Method 2: Manual Installation
- Download the latest release zip from the GitHub repository.
- In Arduino IDE, go to Sketch > Include Library > Add .ZIP Library...
- Select the downloaded zip file.
Hello Robot
Here is a minimal example to verify that your environment is set up correctly. This sketch initializes the robot and prints "Hello Robot!" to the OLED display.
#include <UNI.h>
// Create the robot instance
UniBase robot;
void setup() {
// Initialize the robot
robot.begin();
// Display a greeting
robot.displayPrint("Hello Robot!");
// Blink the LED to show activity
robot.blinkLED(500);
}
void loop() {
// Your main logic here
delay(100);
}
Uploading to ESP32
Make sure you have the ESP32 Board Package installed in your Arduino IDE.
- Select your board: Tools > Board > ESP32 Dev Module.
- Select the correct Port.
- Click Upload.