v0l / radio_tool

Radio firmware tool
https://discord.gg/V596cyatmv
GNU General Public License v3.0
74 stars 17 forks source link

Fix Fw Write for SGL radios #26

Closed cifred98 closed 9 months ago

cifred98 commented 9 months ago

Fixed the firmware upload for TYT SGL radios. The USB callback code wasn't working for me so I made it synchronous. The wrapping of the firmware isn't working yet. I've tested it only with the Radioddity GD77 flashing OpenRTX on Fedora, not sure if it works on Windows.

Please review it and let me know if there is anything to change.

v0l commented 9 months ago

Wow so it was almost correct, the code? I didnt have a GD-77 at the time of writing so i was kinda winging it from other sources and some USB captures. Really cool that you managed to get this to work!

v0l commented 9 months ago

std::bit_cast seems to be a problem, can you use something else instead?

cifred98 commented 9 months ago

It looks like GCC 9.5.0 had only experimental support for C++20, I've switched it to the built-in bswap. Good job on making it almost work without having a GD77 to test it!