void setup() {
// put your setup code here, to run once:
Serial.begin(115200);
Serial.println("Hello, STM32!");
}
void loop() {
// put your main code here, to run repeatedly:
delay(10); // this speeds up the simulation
byte low, high;
int Vbatint;
for (int x = 0; x <= 64; x++) { // zapisanie testowego
Vbatint = round((3 + x / 60.0) * 1000);
low = Vbatint & 0xFF;
high = Vbatint >> 8;
Serial.print("LOW ");Serial.println(low);
Serial.print("HIGH ");Serial.println(high);
Serial.println(high * 256 + low);
delay(500);
}
}