in reply to Serial Port win32 module

This code looks similar to what you posted here, what is it supposed to do differently other than write something to the serial port?

In particular, I don't see anywhere in this code where you actually read from the port. Instead, you immediately close it after writing. Try keeping the port open and reading from it.

What does your hardware setup look like? Specifically, do you have any of the RTS, CTS, DTR, etc. lines connected between the two terminals? If so, incorrect settings of those lines could be stopping the other side from transmitting. There seem to be several methods in Win32::SerialPort for controlling those lines if you need to.

If this happens to be related to the driver issues you mentioned previously, it'll probably be hard to debug without knowing more details of your hardware, system and drivers.

Replies are listed 'Best First'.
Re^2: Serial Port win32 module
by jismake (Initiate) on Apr 22, 2014 at 09:48 UTC

    Yes, the previous post was my struggle to start. Now i am on my next stage. I am using Strawberry 32 bit on a 64 bit windows 7. The usb to serial converted is connected to PC , then connect the device which talks on serial. Only tx,Rx and gnd are connected. The following the spec of the device. VCR Get Version number of hardware and software This command is only active always. Example: VCR Get Version numbers Now i use the perl script and try to monitor the response thru serial monitor.We have tried delay the close port till 10 secs.but i have not seen the response on the serial monitor window. I use a serial tool called teraterm and terminal to repeat the issue i found. but it always works fine with it on same settings done on script. thanks, jis

      Again, try actually reading data from the port in Perl.

      Note that you may need to change the read_interval, read_char_time, and/or read_const_time settings in case you experience timeout problems.

      Is your serial monitor a hardware device or a software on the PC? If it's the former, then your problem is indeed strange and I'd suspect incorrect settings or flow control issues somewhere. If it's the latter, then there might still be some driver issues going on preventing you from seeing things in your serial port monitor.

      Lastly, see if you can get your PC and your Perl script talking to a different piece of hardware, such as a second PC running HyperTerminal or TeraTerm or similar.