I'm trying to use an okai F350 (ES100) scooter, with an Arduino I got the display and lights to work. If you rotate the engine on the display, the speed will appear. But the engine does not respond to the accelerator. The code I am using on Arduino is as follows:
Code: Select all
#include <Arduino.h>
int PIN_SWITCH_1 = 13;
int powerPin = LED_BUILTIN;
byte messageOff[] = {0xA6, 0x12, 0x02, 0x90, 0x01, 0x42}; //If the scooter is on turn it off.
byte messageA[] = {0xA6, 0x12, 0x02, 0x10, 0x14, 0xCF}; // MAKES HEADLIGHT BLINK CODE BEFORE STARTUP
byte messageC[] = {0xA6, 0x00, 0x00, 0xF5, 0xFF, 0xFC}; // LIGHT ON & ESC ON & KPH & MAX SPEED & BLINK OFF & TURBO ON & FAST GAZ
void setup() {
Serial.begin(9600);
pinMode (PIN_SWITCH_1, OUTPUT);
pinMode(powerPin, OUTPUT);
digitalWrite(powerPin, HIGH);
Serial.write(messageOff, sizeof(messageOff));
delay(500);
Serial.write(messageC, sizeof(messageC));
}
void loop() {
delay(500);
Serial.write(messageC, sizeof(messageC));
}
Is it possible to put the firmware of another scotter in this, by JTAG? Example (Ninebot, xiaomi)
Best regards