Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

Packet decoder not working through USB

Status
Not open for further replies.

upand_at_them

Active Member
I'm having real difficulty getting my packet radio decoder working over USB, via a CP2102 USB/UART adaptor.

The packet decoder works flawlessly when it's powered from a breadboard supply (wall wart feeding a 7805) and the communication is through the PC's regular COM (RS232) port.

And If I power the decoder from the CP2102 USB/UART adaptor and feed the comm through the regular COM port, it still works.

But if I power the decoder from the USB adaptor as well as feed the comm through the USB adaptor...Well, the communication link works (intro message transmits), but the packet decoder fails to decode any packets at all. It looks like there are ground/noise/capacitance issues that I can't figure out.

I have 0.1uF decoupling caps at both power rails. And the handheld (battery powered) radio shares the ground with the circuits in all of my tests. Do I need to isolate the USB adaptor in some way? Is there something I should be doing to prevent ground loops? I'm really clueless here.

Mike
 
Last edited:
I noticed no where above says you've successfully tested the USB serial adapter itself successfully, just it as a power source.. serial to USB adapters can sometimes ignore standard flow control signals such as CTS/RTS where your decoder may need them, what are the signal lines required by your packet decoder?

Have you tested the serial to USB adapter with any other serial device and had it work properly?
 
Yes, sorry, the USB adapter works perfectly by itself. It just causes interference with the incoming audio signal when used with the packet decoder, which also works by itself.

This is the audio circuit:
10-07-2011-7-15-39-pm-png.57355
 
What kind of decoupling caps are you using on the PIC pin and the audio source itself?
 
.1uf what kind of caps? .1uf are supposed to be used right at the chip leads. If the power supply leads are longer than a few inches you need a 10-100uF cap as well.
 
Last edited:
What about the audio source? There's so much missing from the schematics that you've posted so far it's impossible to help. You've fed us so far a few chocolate chips from an entire chocolate chip cookie and are asking us what the cookie tastes like..

Sorry for the allegorical response, but you can keep feeding us chocolate chips but we'll never taste the cookie that way!
 
Last edited:
Okay. I'm not leaving much out, though. That circuit above is the audio input circuit. Aside from that part the PIC has the decoupling caps, crystal with caps, and that's it.

The audio source is a handheld transceiver output jack. The cable is a salvaged PS2 mouse cable. The shield is used for ground.

I'll have to download a schematic drawing program...My old HD crashed and this is a new one.
 
I'm at a loss..
 
I pulled out the scope today and recorded the USB/UART adapter's power rails:

I added 10uF and 0.1uF caps and the result was the same. I also ran it through a MIC2950 regulator and it was also the same.

Chalk it up to Chinese crap?
 
Last edited by a moderator:
Noisy sure, but still in spec.
https://www.beyondlogic.org/usbnutshell/usb2.shtml

USB 2.0 specs shows low current mode has an allowance of -600mv, and +250mv

To reduce noise you could try to put a small resistance in line with the input it to make it act as a true lowpass filter. Bypass caps alone won't do a damn thing about noise.
 
Last edited:
I tried several small resistors on the 5V line, but none had a noticeable effect. Biggest cap I have is 330uF and that brought the noise down to 50mV P-P. Added a 100ohm resistor in series and it came down to 30mV P-P.

The funny thing is that the 3.3V output line is pretty clean and the 5V line is going through some type of regulator.

FYI, this is the adapter: **broken link removed**
 
Status
Not open for further replies.

New Articles From Microcontroller Tips

Back
Top