I am in the process of troubleshooting the alteration of some data in my USBhost-64 replacement. I thought to share the details of the data alteration in the hope that it might ring some bells with others while I give it a thought.
Here’s a few couples of bytes that result in the second byte being read by the C64 as 0xFF:
01 FA 20 BF 38 EF 02 F7 10 FD 20 FD 04 FC 40 DF 00 CE 11 FE 05 FD 05 EF 09 FE 03 DF
There isn’t a pattern about their position in the data stream, just the fact the first byte seems to be <0x60 and the second one >0x60, although such couples are NOT always altered. In other words: if a couple is altered, then it satisfies the above condition, but if the above condition is satisfied the alteration might not happen. E.g.:
0B DF <- not altered
My initial suspicion was around bus signals, e.g. reading the data out of the bus when the bus is still set as input or similar. However, if I put some code in place to delay reading data and possibly cope with such a scenario, it does not make any difference. Besides, the second value in each couple is NOT altered elsewhere, e.g.:
7D DF <- not altered
Any thoughts before I dig deeper into this? The first one who solves the mystery gets a free device!