SerAccel v3/v4 to USB Howto??

Have questions about a SparkFun product or board? This is the place to be.
Locked
UberSteve
Posts: 9
Joined: Tue Jul 19, 2005 8:33 pm

SerAccel v3/v4 to USB Howto??

Post by UberSteve » Wed Sep 28, 2005 8:51 pm

Hi,

I would like to connect the SerAccel v3 to a CP2103 USB-Serial converter, but I can't get it working and don't fully understand how it can work.

The SerAccel v3 is designed to talk directly with the RS-232 port on a PC, which works on the RS-232 voltage levels (ie +12V for 0, and -12V for 1) ,right? However, the CP2103 is expecting TTL levels isn't it? (ie +5V for 1, and 0V for 0).

So, how do you connect them together?

Anyway, this is what i've tried so far:
I currently have it connected like this:
Image

I plug in the CP2103, load the drivers and open the comm port in hyperterminal. I set the baud rate to 115200 and all I get is corrupted data :S

While it's all still plugged in, if I connect the TX terminal on the SerAccel to a real comm port on the PC, the data is fine.

Any ideas??

Cheers,
Steve

UberSteve
Posts: 9
Joined: Tue Jul 19, 2005 8:33 pm

Post by UberSteve » Mon Oct 03, 2005 4:20 pm

bump.

It says on the Sparkfun site that this should work, has anyone got it working??

dvukovic
Posts: 14
Joined: Wed Sep 14, 2005 1:26 pm

Post by dvukovic » Tue Oct 04, 2005 6:57 am

Hi Steve,


When you loaded the USB drivers, did a new comm port appear in the hardware manager ???

Which Win OS are you using ??


Thanks

Donald

UberSteve
Posts: 9
Joined: Tue Jul 19, 2005 8:33 pm

Post by UberSteve » Wed Oct 05, 2005 3:16 pm

Hi Donald,

When I load the Sparkfun USB drivers, I get a new Comm Port in device manager, COM16.

I am using WinXP Pro.

Please see the output I get below:
Image

Cheers,
Steve

JonChandler
Posts: 174
Joined: Fri Jun 17, 2005 1:05 pm
Contact:

Post by JonChandler » Thu Oct 06, 2005 6:56 am

It seems the basic problem is the accelerometer board puts out RS-232 levels and the USB converter is expecting TTL (+5V) levels. This means the signals are both at the wrong level and inverted.

I can't find a schematic for the serial accelerometer, but I assume it has some flavor of MAX232 chip to have an RS-232 output. The options are to remove this so the TTL-level serial is available to the USB or add a MAX232 to the input of the USB convertor so it sees the levels it's expecting.

Been there, done that. Seems silly to have 1 MAX chip convert TTL levels to serial and another convert them back but that's how I do it in one of our products. This was easier than getting rid of the first MAX chip...which is actually a good feature sometimes.

Jon
Jon

UberSteve
Posts: 9
Joined: Tue Jul 19, 2005 8:33 pm

Post by UberSteve » Thu Oct 06, 2005 8:14 pm

Hi Jon,

Thanks for your response. However, there is no MAX323 chip!? The only chips on the board are the AD Accelerometer and the PIC.

I scoped the serial output from the PIC and it seems +3V is 0, and 0V is 1. I have no idea how the hell a PC's RS-232 port reads this!?

Someone from Sparkfun care to comment?

Cheers,
Steve

JonChandler
Posts: 174
Joined: Fri Jun 17, 2005 1:05 pm
Contact:

Post by JonChandler » Thu Oct 06, 2005 10:02 pm

Ohhhhhhh.....a schematic would be helpful.

I know PicBasicPro has a debug mode that inverts the normal serial signals, to provide a no-parts "debug" interface that works with many serial ports. If the output lines of the PIC go directly to the TxD/RxD lines on the PC 9-pin interface, this must be what they're doing.

The inverted signals are going to be giberish to the USB chip. The hardware solution is to add an inverter to each line to undo the inversion that that software is doing.

Jon
Jon

Locked

Return to “SparkFun Product Questions”