Project

General

Profile

Bug #75

USB keyboard stops functioning after idle period

Added by Farb 12 months ago. Updated 11 months ago.

Status:
New
Priority:
Normal
Assignee:
-
Start date:
10/01/2018
Due date:
% Done:

0%


Description

I have noticed in the last few core builds (up to and including v29) that if the USB keyboard is idle for too long, it stops working. Sometimes unplugging/replugging the USB connector fixes the problem and sometimes it doesn't.

History

#1 Updated by foft 12 months ago

Two potential problems:
1) max number of devices was decreased in v28, should have no impact but it was a change.
2) SIO can block usb polling and there have been significant sio changes.

This really seems to be elapsed time? Did you check another keyboard? Any particular software running?

#2 Updated by Farb 12 months ago

I have seen it happen a few times using the same USB keyboard (which was also the same keyboard I used on the MiST and don't recall having a problem):

1. Last night using v28 playing a trivia game ("Millionaire" from the 2018 ABBUC software contest). We contemplated an answer a bit too long and the keyboard would no longer work. I unplugged/plugged it back in but it did not recover. No disk activity (or any other activity) occurred in the time between it working and not. Was forced to reboot the EclaireXL and the keyboard started working again. The game's ATR file was loaded from the built-in disk emulation and wasn't using any external device. Two joysticks were plugged in but not being used.

2. It happened a number of times several weeks ago while working on Sdrive Max ATX code (don't know which core version but it was a few back -- maybe v25 or v26). I was running Diskey to load individual disk sectors and let things sit idle to the point that the attract mode color cycling had been running a while. When I resumed trying to load sectors, the keyboard wouldn't respond. I distinctly remember unplugging/plugging the USB connector and recovering at least once but can't say with certainty that it fixed it consistently. One joystick was likely plugged in at that time.

Could a problematic ribbon cable between the main and daughter boards be a possible cause? Could be irrelevant but I haven't replaced a faulty ribbon cable that caused joystick problems. I merely swapped the two cables and joysticks started working properly.

#3 Updated by foft 12 months ago

Unlikely to be the ribbon, though if its iffy you should replace it. I say that because while the joysticks are connected via the ribbon, the usb ports are directly connected to the fpga.

Might be worth trying a different keyboard to see if it still happens.

Do you know if the core is still running? i.e. do the joysticks still work + the screen is still update + music playing?

#4 Updated by sadosp 12 months ago

Farb wrote:
Could be irrelevant but I haven't replaced a faulty ribbon cable that caused joystick problems. I merely swapped the two cables and joysticks started working properly.

Irrespective of the problem with the keyboard,I am very surprised, why you haven't change the ribbon cables till now with the new ones I sent you!

#5 Updated by sadosp 12 months ago

sadosp wrote:

Farb wrote:
Could be irrelevant but I haven't replaced a faulty ribbon cable that caused joystick problems. I merely swapped the two cables and joysticks started working properly.

Irrespective of the problem with the keyboard, I am very surprised, why you haven't change the ribbon cables till now with the new ones I sent you!

#6 Updated by Farb 12 months ago

Yes, the core is still running because we were hearing music play. The game we were playing didn't use a joystick so we couldn't test that. I can try to reproduce with something that uses both joystick and keyboard. I will also see if I can reproduce with my other USB keyboard.

@sadosp: I know, I was being distracted with other things and kept putting it off. The new cables are sitting right here waiting to be replaced. I will do that today :-P

#7 Updated by foft 12 months ago

Well I just received Millionaire on disk so I can give it a go and see if I have the same issue. My keyboard definitely keeps working when idle in basic since I leave it there all the time while debugging the core:-)

#8 Updated by foft 11 months ago

How is it going with the other keyboard?

#9 Updated by Farb 11 months ago

Frustratingly, I have not been easily able to reproduce the effect with the keyboard it occurred on before. I will spend some more time attempting to reproduce soon but will be traveling for the next week or so.

Also available in: Atom PDF