Ht Link

Created by @thetridentguy

title: ht-link author: @TheTridentGuy description: USB adapter to connect cheap handhelds to a computer

Total time: 14h 30m

Build/testing chronicle:

The build for this was fairly simple. I connected the 3.5mm jack from the dongle to the 3.5mm jack on the radio. For the 2.5mm jacks I connected them with a 3.5mm cable and two 3.5mm to 2.5mm adapters. On the radio side, the adapters barely fit, so I kinda had to hold the jack in, and the connection was a little fragile. The setup is below: I set the dip switches according to a random diagram I found online (https://www.wildtalk.com/kenwood-curly-cable/). The first thing I tried was playing audio over the radio (manually, with the PTT button), which surprisingly worked first try, when I keyed up the radio, it would play whatever I played over it. One thing that was tricky was wiring the power. When I set the dip switches to connect the ground, only playing audio over the radio worked, and I couldn't get PTT and recieving audio to work. But when I connected 5V and Ground the battery indicator on my radio drops, and I get a low battery warning, which doesn't stop it from working, but to me this suggested that the battery's >5V and the 5V line were being connected internally, which is probably damaging both my battery and USB bus every time I use this thing. Anyway, after a little trial and error I realized that the only way recording audio from the radio was gonna work was if I connected both lines, so I sucked up the low battery issue. And then I was able to use Audacity to record recieved audio. The dongle kept disconnecting from my PC, which appears to be because it's fairly heavy, and a little loose in my USB ports that are also sideways. Doing it in my laptop fixed this. As far as PTT, I wasn't sure if it needed to source or sink the PTT line, so I included a switch on the PCB to switch between both modes. I then tested to see which it was, by using the DIP switches to connect it to 5V and ground. Ground worked, so I knew I needed to sink the PTT line. I now knew how to key up the radio, so I tried to do it over USB. I tried with some code, and I tried using a random command line utility (https://github.com/twilly/cm108) I found online to change the state of the GPIO pin on the audio chip that I was using, but I was unsuccessful. Sadly, I don't know much about USB, but hopefully sometime I'll be able to debug the PTT over USB more.

August 7:

PCB ordering was hell, but they finally came. I've been testing, and the only thing that I havent gotten working yet is PTT. Demo coming today!

July 5:

2h

Update: I'm going to put this on hold until I can discuss PCB orderring with my reviewer.

And after going further down the ordering road i have determined that i am fucked, and so i am replacing all the non-basic parts with equivalent basic parts. I hate jlcpcb.

This project finally got approved, but I realized my USB connector is standard PCBA only, so I'm switching it to a economic compatible one. Since this took slightly more space for some reason, I had to move components, but everything except the exact model of USB connector is the same. The extended component fee was also exorbitant, so I chose not to place the LEDs and associated resistors.

June 27:

30m

Touch up pcb, and get everything ready for submission

June 24:

2h

struggled with JLCPCB's website, and submitted to the gallery, also made a few minor pcb updates.

June 23 (Part 2):

4h

I thought I had finally quit circuit design (I hadn't):

June 23:

6h

Did a ton of work on schematic and pcb, most of the time was spent reading the datasheet though.

June 22:

2h

Did a lot of research and started on a basic pcb prototype. I expect to have to iterate this pcb a few times.

June 21:

30m

research, probably gonna use the Cmedia CM108B as the main chip for this board.