Split variable to prevent warnings on the ESP8266 platform

See: https://travis-ci.org/felis/USB_Host_Shield_2.0/jobs/230952435#L1149
This commit is contained in:
Kristian Sloth Lauszus 2017-05-11 17:55:13 +02:00
parent 14fec8dab8
commit 18a36f8627

View file

@ -69,7 +69,8 @@ void MIDI_poll()
pid = Midi.pid; pid = Midi.pid;
} }
if (Midi.RecvData( &rcvd, bufMidi) == 0 ) { if (Midi.RecvData( &rcvd, bufMidi) == 0 ) {
sprintf(buf, "%08lX: ", (uint32_t)millis()); uint32_t time = (uint32_t)millis();
sprintf(buf, "%04X%04X: ", (uint16_t)(time >> 16), (uint16_t)(time & 0xFFFF)); // Split variable to prevent warnings on the ESP8266 platform
Serial.print(buf); Serial.print(buf);
Serial.print(rcvd); Serial.print(rcvd);
Serial.print(':'); Serial.print(':');