18 Commits

Author SHA1 Message Date
Glenn Maynard
880774f9e4 Make sure we call the callback from SendCommandLocked if the device isn't connected and we're not queueing the command. 2018-12-09 16:11:12 -06:00
Glenn Maynard
4691ce5ecf If commands are buffered and not sent when the device is disconnected, call any completion callbacks.
This is to guarantee that completion callbacks are always called, so if any
resource collection happens in them it'll always happen.
2018-12-09 16:11:12 -06:00
Glenn Maynard
135e3c5401 Add a UI to set panel animations.
This is driven by the config tool, which needs to stay running.
2018-12-09 16:11:12 -06:00
Glenn Maynard
2628c078fa Add SMXPanelAnimation. 2018-12-09 16:11:10 -06:00
Glenn Maynard
303283624a Add SMX_SetLights2.
This is the same as SMX_SetLights, but instead of taking one buffer with a
fixed size, it takes a separate buffer for each pad, and explicitly includes
the size of the buffer rather than assuming it's 864 bytes.  SMX_SetLights
and SMX_SetLights2 call into the same underlying update.
2018-12-09 16:10:45 -06:00
Glenn Maynard
d576545266 Split out low-level thread handling into SMXThread, and use it in SMXHelperThread.
This isn't used by the SMXManager thread for now.

This also separates out SMX::Event for thread event handling.
2018-12-09 16:10:45 -06:00
Glenn Maynard
a7cb6ad51d Replace SMXHelperThread::GetThreadId() with SMXHelperThread::IsCurrentThread(). 2018-12-09 16:10:45 -06:00
Glenn Maynard
ad2e7dcb74 Move extern "C" into the SMX_API define. 2018-12-09 16:10:45 -06:00
Glenn Maynard
4c0da63842 Add debounceDelayMs.
This isn't turned on, this is just to sync up the config packet with the
firmware.
2018-12-09 16:10:44 -06:00
Glenn Maynard
7a4bbc6eab Pad the configuration struct to 250 bytes, so the SDK.DLL ABI doesn't change when fields are added. 2018-12-09 16:10:16 -06:00
Glenn Maynard
2c07942478 Move the SMXManager from SMX to SMXManager. 2018-11-08 19:13:35 -06:00
Glenn Maynard
65f4a7102c Check for out of sequence PACKET_FLAG_START_OF_COMMAND.
This improves recovery if a start packet is received when we didn't receive a complete
packet earlier.  This doesn't normally happen, this just matches the error recovery used
in game.
2018-10-19 18:55:50 -05:00
Glenn Maynard
e57fa5d28e Add a version display based on the git tag. 2018-06-11 19:56:21 -05:00
Glenn Maynard
8ea8070d51 Some disabled logs for testing (disabled because they're noisy). 2018-06-07 16:06:50 -05:00
Glenn Maynard
78d6be9341 Fix up ssprintf. 2018-06-01 18:15:29 -05:00
Glenn Maynard
9b6eb07e0b Add more logs for device connections. 2018-06-01 18:15:28 -05:00
Glenn Maynard
eb84ffe29d Fix SMX_GetConfig not returning a result.
This caused SMXConfig to think it was setting both controller configurations even
when only one was connected, which made the UI not refresh correctly if only P2
was connected.
2018-01-06 20:32:02 -06:00
Glenn Maynard
57379383c0 Import for release. 2017-12-15 02:55:34 -06:00