rp2040-doom icon indicating copy to clipboard operation
rp2040-doom copied to clipboard

I2C Networked Play on Defcon32 Badge

Open bhass1 opened this issue 6 months ago • 3 comments

Basic sanity testing of the networked play isn't working when I wire up the SAO I2C (I2C_SDA, I2C_SCL, GND).

Badge code appears to use different pins for I2C, pins 2 & 3: https://github.com/raspberrypi/pico-sdk/blob/master/src/boards/include/boards/defcon32_badge.h#L32.

If I remove the #ifdefs around the I2C PIN related #defines in defcon32_badge.h and compile, I2C begins working. With this change, the client can see the host. However after selecting the "Skill Level" on the host, the host just freezes (including the game loop running in the background of the initial menu). On the client side, the lobby and 2 players are shown, and the game loop continues running in the background (this seems normal).

PXL_20240815_145152946~2

Nothing is jumping out at me from the piconet_start_host function in piconet.c - except maybe this DMA stuff related to I2C? I will need to hook up a debugger and see where we get held up.

Any recommendations from @kilograham would be greatly appreciated ;)

bhass1 avatar Aug 15 '24 15:08 bhass1