On Tue, Apr 16, 2002 at 03:39:27PM +0200, Wolfgang Fritz wrote:
> Hello,
> 
> I have a Prolific PL-2303 serial converter connected to my laptop. It 
> basically works, but I have 3 problems which I am not able to solve:
> 
> 1. After open()-ing the device /dev/ttyUSB0, the first character received on 
> the serial does not come through.

What do you have the line settings set to?  You should use a serial
program, not just 'cat' and 'cp' to test these things out.

> 2. I can not change the baud rate of the converter. It stays on 9600 Baud.

How are you trying to change the baud rate?  It seems to work fine for
me :)

> 3. cp or cat to /dev/ttyUSB0 does not work (hangs forever)

Again, see the above comment about not using these programs for testing.
I recommend using minicom or any other serial terminal program.  See the
Linux Serial Programming HOWTO for more info on how to write code to
talk to serial ports.

> I found this with an application program which bootloads a program to a 
> 68LC302 microcontroller which has a special serial bootload mode which works 
> as follows:

Is the 68LC302 connected up to the pl2303 device?

> 1. Enable serial bootload mode. This switches the serial port on the 68LC302 
> to 9600 baud.
> 
> 2. Send exactly 576 bytes bootloader binary code to the 68LC302. These bytes 
> are stored in an internal RAM and after rececption of the last byte, it is 
> started. The 68LC302 echoes the received bytes for error checking. Here I 
> found the "missing first byte" bug.
> 
> 3. The bootloader expects the application program in S-record format with 
> 115200 Baud. The host switches to 115200 and sends the S-record file with a 
> cp <file> /dev/ttyUSB0. Here I found the bugs 2 and 3.
> 
> This procedure works without problems with a standard serial port.

Try loading the pl2303 driver with "debug=1" so you can see the data and
line changes happening on the device.  That might help you out to see
what is wrong with either your user program, or the driver.

> I did some strace-ing and debugging which gave me error messages about 
> unsupported ioctls in the pl2303 module. If useful, I will post it here.
> I also looked at the pl2303 source code and found that it has not changed 
> significantly up to 2.5.

There are loads of serial ioctls that are not supported by some of the
usb-serial drivers, but these can usually be ignored just fine.

thanks,

greg k-h

_______________________________________________
[EMAIL PROTECTED]
To unsubscribe, use the last form field at:
https://lists.sourceforge.net/lists/listinfo/linux-usb-users

Reply via email to