Losing bytes on Yun-Bridge

Hallo everybody,

I try to stream a Midifile via Yun-Bridge. I used the following code for test purpose:

boolean readData() { 
  char dat[]="/mnt/sd/test01.mid";
  File myfile = FileSystem.open(dat, FILE_READ);
  
  byte data=myfile.read();
  if (data !='M'){   //Test ob Mididatei
    return false;
  }
  
  myfile.seek(12);//Dateizeiger auf Wert für Deltawert 4tel Note
  
  delta4= myfile.read();
  delta4=(delta4 << 8)+myfile.read();
  
  
  myfile.seek(23); //Dateizeiger auf erstes Midikomando
     
    if (myfile){
     while (myfile.available()>0){
      byte data=myfile.read();
      Serial.write(data);
     } 
     myfile.close();  // close the file
    }
  return true;
}

The problem is, that sometimes bytes are getting lost. I attached two pictures, the first one shows the original Hex-dump of the midi-file and the second one the data I received on the 32U4 side. I marked the lost byte (0x96).
If I use other files I have the same problem. Random bytes getting lost.
Yun is updated on 1.4.

Thank you for ideas...

Original.PNG

lositByte.PNG

How big is midi file?

hallo,
the midifile is just 100 bytes. All files I tested are very small.
I attach the midifile and my Arduino codefile...
I tested it on two Yuns but allways was missing this byte.

test01.mid (100 Bytes)

Yun_Fehler.ino (1.02 KB)

I updated Arduino IDE and the problem sees solved...

Ah so I guess you hit one of the first bugs we found. Indeed we fixed that but the fix requires you to update both the yun and the arduino IDE, as you did. 8)

What caused this bug?

I'm having similar problems, however I build the YUN openwrt myself from the source files, because I need to add my own C code to the linux side, but the serial communication is big problem.

I'm communicating using a C program from YUN linux, to YUN arduino (or whatever you call it), but 90% of the time it doesnt work, missing bytes, or different byte received.

I used /dev/ttyACH0

Any solutons,I'm very desperate!

thanks
rough