fieldofcows / atari-st-rpikb

Connect USB keyboard and mouse to Atari ST using a Raspberry PI emulating the HD6301 keyboard controller
GNU General Public License v3.0
31 stars 10 forks source link

Crossover with a project I am working on (not a bug!) #1

Open borb opened 2 years ago

borb commented 2 years ago

Hello! I did a project similar to yours for the Amiga a while back, but on Arduino. Cut a long story short, I started recently porting that project to the Pico/RP2040, and during the process found tinyusb is a bit wobbly in terms of reliability (but typically, only when I'm not far from completing the first release of it).

A helpful friend (say hello @M1kerochip) mentioned spotting this (your) project in an Atari forum, and hence you've apparently encountered some of the issues with tinyusb as well (love how building with the pico sdk debug flag causes tinyusb to completely fail, but I suppose it is a very early version). And thus, my question:

Other than that, props for a neat project from across the Tramiel 68k divide 😄

fieldofcows commented 2 years ago

Hi @borb. Good to see this project getting some interest. I wrote it purely for a bit of fun when I got a cheap mega ST that had no keyboard. I enjoyed working with the RP2040. The USB was a bit frustrating because there were portions that just were not implemented, things that didn't work correctly and a few protocol/driver bugs.

It was made twice as hard because I did not have a USB analyser - an essential tool for this type of work. I did raise a PR against TinyUSB that fixed the issues I saw (https://github.com/raspberrypi/tinyusb/pull/7). Although this PR solved the problem I didn't really have the time or the tools to determine whether I was implementing a workaround or fixing the root cause. Subsequently the PR has been closed without being merged.

I packaged up my pico board into a case with connectors for joysticks, keyboard and mouse and connected it to my ST but for some reason the firmware now keeps freezing. It's definitely related to USB but I haven't had the time to go back and take a look.

I've actually just got a USB analyser on the way now and it's made me think again about resurrecting this and fixing the freezing issue. Hopefully I'll come up with a solution in the next couple of week and I'll update this repo.

Anyway, good to hear from you and bad luck for picking the wrong machine!! :)