PDA

View Full Version : BootLoader with USB to Serial Convertors



mike101video
- 9th January 2006, 15:09
Hi,
I am developing using the easyPIC3 board and the bootloader works just fine with a serial cable on COM1. If I try to use a USB-Serial cable - it asks for a reset, but nothing happens. Same hardware set up on the PIC side, just replaced the direct serial cable with the USB-SERIAL device.

Does the bootloader work with a USB to Serial convertor plugged into the PC?

I will need this to work as I will be reloading the PIC in the field from a notebook - which doesn't have a comm port.

Any help much appreciated

Bruce
- 9th January 2006, 20:05
Hi Mike,

Which boot-loader are you using, and are you resetting the board once this message pops up during the loader process?

Some USB/Serial adapters don't provide anything but TX/RX signals. If you're using a loader that requires handshaking or loop-back signals, then it's probably not going to work with your particular USB/Serial adapter.

mike101video
- 9th January 2006, 20:29
Thx Bruce,
I using the one that comes with MicroCode Studio Plus.( mecanique) Version 3.2.0.1.

The only hardware requirments shown in the documentation are at the PIC end, RX, TX and line providing a reset to the PIC. (This is the same hardware in my case for both direct serial cable and USB cable.) The bootloader requests a reset for the PIC, and again this works for the direct serial cable, but nothing happens for the USB cable.)

Thx again,
Mike

Bruce
- 9th January 2006, 21:19
Hi Mike,

Since you've already verified this on the same board with the standard serial connection/cable, it could be that the board you're plugging the USB/Serial adapter into is routing some handshaking signals back to the standard DB-9 type serial adapter on the board.

This may or may not be a good thing depending on the USB/Serial adapter, how it's wired, and what signals it makes available at the DB-9 end.

I would check this one out first. If you have another PIC dev board with a DB-9 connector that's not wired for looping back signals/handshaking that would tell you.

This message just means the loader software running on your PC can't communicate with the target PIC. If the boards DB-9 wiring is OK for the adapter, and you're selecting the adapters "virtual" serial port, it should work.

It could also be sloppy timing or drivers on the converter. I have never had any problems with USB/Serial adapters using the FTDI chipsets, but I have with several other el-cheapo brands. Especially on XP systems.

forgie
- 10th January 2006, 02:26
Just a thought: see if it's the reset that's causing you grief - AFAIK you can do a hard reset for a few seconds after you click "Program" with the MELabs Loader and it'll all work. So try that, click Program, then straight away do a hard reset (assuming your board has a reset switch). If this works then you know theres a problem with the reset line. If it doesn't work, then I'm fresh out of ideas!

Bruce sounds like he knows more about the handshaking, but I'll second the fact that FTDI chips work like a charm with all bootloaders (I even use one on my Mac :) )

mike101video
- 10th January 2006, 15:51
Thxs all,
If I press the reset button for about three seconds - it all works. (With two different USB cables.)

Mike

forgie
- 10th January 2006, 16:48
Good to hear you got it working. Your USB-Serial adapter must have issues with whatever line is used for the reset signal.