Jump to content

Search the Community

Showing results for tags 'library'.

More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


  • General Electric Unicycle Forums
    • Forum Rules (and topics relating to this forum)
    • General Discussion
    • Videos
    • Reviews
    • Which Electric Unicycle to get?
    • Learning to Ride
    • Advanced Skills and Tricks
    • Riding Safety and Protective Gear
    • Apps and App-related Gadgets
    • Mods, Repairs, & DIY
    • Tires
    • Local Group Meet Ups
    • Private Sales (secondhand)
    • Commercial Advertisements
    • Video-Making and Gear
    • Off Topic Discussion
    • Testing Only
  • Brand-Specific Forums (euc only)
    • Gotway
    • Inmotion
    • Inmotion Official Announcements and Information
    • IRON Korea and Rockwheel
    • King Song
    • King Song Official Announcements and Information
    • Ninebot
    • Veteran
  • Inactive EUC brands
    • Airwheel
    • Firewheel
    • IPS
    • Solowheel
    • Uniwheel
  • One-Wheeled Skateboards
    • One-Wheeled Skateboards
  • Two-Wheeled Self-Balancing PEVs
    • Ninebot Mini, Segway MiniPRO, Xiaomi Mini, Airwheel S8 or equivalent
    • Segway (or equivalent)
    • Hoverboard
    • Commercial Advertisements (Ninebot Mini & equivalent only)
  • Non-Self-Balancing PEVs
    • e-Scooters
    • Other Non-Self-Balancing PEVs

Find results in...

Find results that contain...

Date Created

  • Start


Last Updated

  • Start


Filter by number of...


  • Start





Website URL







Found 1 result

  1. I just created a neat Arduino library to interface EUCs via Bluetooth or directly via the tx/rx connection of the motherboards. I have tested it with several older Gotway EUCs and I will try to add support for the newer Gotway protocol and also for the older King Song protocol. You can download the library on Github: https://github.com/T-vK/Electric-Unicycle-Interface I mainly wrote this for two main reasons: I wanted to make some cool LED effects like rotating LEDs at the precise speed of the Unicycle. To make a DIY Bluetooth smartwatch that displays the speed, battery status etc. The first one is ready to go as you can see in this video: A first prototype of the second one is sort of ready: Here is an example of how you can interface the EUC using my library: /* Simply receive the data the electric unicycle sends * and print it to the serial console on your PC. */ #include <SoftwareSerial.h> #include <EucInterface.h> //Bluetooth serial with rx on pin 9 and tx on pin 10 SoftwareSerial BluetoothSerial(9,10); Euc Euc(BluetoothSerial, BluetoothSerial); // Receive and transmit data via bluetooth void setup() { Serial.begin(250000); // We'll use the normal hardware serial to print out all the received data BluetoothSerial.begin(9600); // Most unicycles communicate @9600 baud over bluetooth Euc.setCallback(eucLoop); // Set a callback function in which we can receive all the data the unicycle sends } void loop() { Euc.tick(); // This simply needs to be called regularely } void eucLoop(float voltage, float speed, float tempMileage, float current, float temperature, float mileage, bool dataIsNew) { if (dataIsNew) { // new data received Serial.print("Voltage: "); Serial.print(voltage); Serial.println("V"); Serial.print("Current: "); Serial.print(current); Serial.println("A"); Serial.print("Speed: "); Serial.print(speed); Serial.println("km/h"); Serial.print("Total mileage: "); Serial.print(mileage,3); Serial.println("km"); Serial.print("Temp mileage: "); Serial.print(tempMileage,3); Serial.println("km"); Serial.print("Temperature: "); Serial.print(temperature); Serial.println(" deg Celsius"); Serial.println(""); Serial.println(""); } } This example uses the Bluetooth interface of the Unicycle. So you'll need a serial Bluetooth module for it. I highly recommend the HC-05 which can be found for less then 3 US$ on aliexpress. But don't worry, there are plenty of other examples in my repo: https://github.com/T-vK/Electric-Unicycle-Interface/tree/master/examples API docs Euc(ReceiverSerial, TransmitterSerial); //create new instance of this class Euc.tick(); // simply has to be called regularly Euc.setCallback(callbackFunction); // you have to specify a callback function to which the class can send the data it receives from the unicycle //Example callback function: void callbackFunction(float voltage, float speed, float tempMileage, float current, float temperature, float mileage, bool dataIsNew) { // Do something with the received data } Euc.beep(); // make the unicycle beep Euc.maddenMode(); // set it to madden mode Euc.comfortMode(); // set it to confort mode Euc.softMode(); // set it to soft mode Euc.calibrateAlignment(); // calibrate alignment Euc.disableLevel1Alarm(); // disable level 1 alarm Euc.disableLevel2Alarm(); // disable level 2 alarm Euc.enableAlarms(); // enable alarms Euc.enable6kmhTiltback(); // enable 6km/h tiltback Euc.disable6kmhTiltback(); // disable 6km/h tiltback
  • Create New...