mirror of
https://github.com/felis/USB_Host_Shield_2.0.git
synced 2024-03-22 11:31:26 +01:00
Fixed some warnings in the MIDI examples
This commit is contained in:
parent
412c6665e2
commit
738adc67f6
6 changed files with 11 additions and 10 deletions
|
@ -68,9 +68,10 @@ install:
|
|||
#
|
||||
# Libraries from PlatformIO Library Registry:
|
||||
#
|
||||
# http://platformio.org/#!/lib/show/416/TinyGPS
|
||||
# http://platformio.org/#!/lib/show/417/SPI4Teensy3
|
||||
- platformio lib install 416 417
|
||||
# http://platformio.org/lib/show/62/MIDI
|
||||
# http://platformio.org/lib/show/416/TinyGPS
|
||||
# http://platformio.org/lib/show/417/SPI4Teensy3
|
||||
- platformio lib install 62 416 417
|
||||
|
||||
script:
|
||||
- platformio ci --board=uno --board=teensy31 --board=due --lib="."
|
||||
|
|
|
@ -43,10 +43,10 @@ void setup()
|
|||
|
||||
void loop()
|
||||
{
|
||||
unsigned long t1;
|
||||
//unsigned long t1;
|
||||
|
||||
Usb.Task();
|
||||
t1 = micros();
|
||||
//t1 = micros();
|
||||
if ( Usb.getUsbTaskState() == USB_STATE_RUNNING )
|
||||
{
|
||||
MIDI_poll();
|
||||
|
@ -69,7 +69,7 @@ void MIDI_poll()
|
|||
pid = Midi.pid;
|
||||
}
|
||||
if (Midi.RecvData( &rcvd, bufMidi) == 0 ) {
|
||||
sprintf(buf, "%08X: ", millis());
|
||||
sprintf(buf, "%08lX: ", millis());
|
||||
Serial.print(buf);
|
||||
Serial.print(rcvd);
|
||||
Serial.print(':');
|
||||
|
|
|
@ -81,7 +81,7 @@ void doDelay(unsigned long t1, unsigned long t2, unsigned long delayTime)
|
|||
unsigned long t3;
|
||||
|
||||
if ( t1 > t2 ) {
|
||||
t3 = (4294967295 - t1 + t2);
|
||||
t3 = (0xFFFFFFFF - t1 + t2);
|
||||
} else {
|
||||
t3 = t2 - t1;
|
||||
}
|
||||
|
|
|
@ -89,7 +89,7 @@ void doDelay(unsigned long t1, unsigned long t2, unsigned long delayTime)
|
|||
unsigned long t3;
|
||||
|
||||
if ( t1 > t2 ) {
|
||||
t3 = (4294967295 - t1 + t2);
|
||||
t3 = (0xFFFFFFFF - t1 + t2);
|
||||
} else {
|
||||
t3 = t2 - t1;
|
||||
}
|
||||
|
|
|
@ -99,7 +99,7 @@ void doDelay(unsigned long t1, unsigned long t2, unsigned long delayTime)
|
|||
unsigned long t3;
|
||||
|
||||
if ( t1 > t2 ) {
|
||||
t3 = (4294967295 - t1 + t2);
|
||||
t3 = (0xFFFFFFFF - t1 + t2);
|
||||
} else {
|
||||
t3 = t2 - t1;
|
||||
}
|
||||
|
|
|
@ -69,7 +69,7 @@ void MIDI_poll()
|
|||
Midi.SendSysEx(exdata, sizeof(exdata));
|
||||
delay(500);
|
||||
}
|
||||
uint8_t size = Midi.RecvData(inBuf);
|
||||
Midi.RecvData(inBuf);
|
||||
}
|
||||
|
||||
//note On
|
||||
|
|
Loading…
Reference in a new issue