serial-port

Serial port mapping doesn't work in WM emulator

I set COM2 for my USB serial port device and it appears as "COM2 serial port" in device management. Then I map the COM2 to serial port 2 in WM emulator configuration. But when I try to open COM2, it says COM2 doesnt exist. Then I use string[] allComs = System.IO.Ports.SerialPort.GetPortNames(); to check all the ports, find out COM2 is m...

Modbus stack for Microchip PIC

Can someone suggest an open source implementation of a Modbus RTU Slave for a Microchip PIC18 processor? I'm looking for an implementation of Modbus RTU for RS-232/RS-485, but a Modbus TCP/IP implementation would be welcome as well. ...

java serial I/O: handling USB serial connection/disconnection in a robust manner

I'm using rxtx for serial I/O handling in Java with an FTDI2232H that provides a USB comm port. It works great, with one exception: if I unplug the USB cable, so that the COM port disappears at runtime, it spews exceptions left and right: java.io.IOException: No error in nativeavailable at gnu.io.RXTXPort.nativeavailable(Native Method) ...

Transmitting data with RS422 in .NET

Hello, I'm trying to make a simple application to test the RS422 communications with another computer. Using the RS232 interfaces this program is working smoothly, but with the RS422 is not working, as there is one computer that can't send. To complex the scenario a little bit more, I can communicate through RS422 using a HyperTerminal....

Crystal Reports talking to a Com Port

We're using Crystal to create receipts using a USB port connector to our printer. We'd now like Crystal to 'ping' the serial port to open a cash draw. Is there any way of getting Crystal to do that? ...

Advice on logic circuits and serial communications

As far as I understand the serial port so far, transferring data is done over pin 3. As shown here: There are two things that make me uncomfortable about this. The first is that it seems to imply that the two connected devices agree on a signal speed and the second is that even if they are configured to run at the same speed you run in...

question about PORT

I have written a program in C# that sends text to COMx. I wish to test it using HyperTerminal, meaning I want to read the text that I send with my program. When I set the WAIT FOR CALL in HyperTerminal, my program is refused access to the given port. How can I test my program? Is it possible? ...

Camera RS232 Protocols

I am looking for information on camera RS232/RS485 protocols. The camera I have lists its supported protocols as: Pelco D Pelco P Fastrax Command I don't think that Pelco has the features I need but I can't find any information on the last two. Pelco only appears to allow differential changing of zoom and focus (commands to move in/o...

how to use /dev/ptmx for create a virtual serial port?

I have a program, using pyserial, and I want to test it without using a real serial port device. In windows, I use com0com, and in linux, I know there is a method to create virtual serial port pair without using additional program. so I look up the manual, and found pts, /dev/ptmx, but I don't know how to create a pair by following the...

Are there some program like COM2COM in linux?

I use com0com for program testing in windows, are there any program like com2com in linux? I know there is pts/ptmx, but what I want is a stand alone program to provide 2 virtual serial ports... Then I can open 2 program, each attench one... ...

Software serial port loopback on linux

Hello, all. Currently I need to develop some program that will communicate with cisco devices over serial line. I want to build testing environment on my development linux machine. So, I found dynamips cisco emulator. This emulator can provide interface via serial line with '-U /dev/ttyS0' option. Well, this causes dynamips to open hard...

RS-232 confusion under C++

What's the problem in given code? Why it is not showing the output for rs232 when we connect it by the d-9 connector with the short of pin number 2 & 3 in that? #include <bios.h> #include <conio.h> #define COM1 0 #define DATA_READY 0x100 #define SETTINGS ( 0x80 | 0x02 | 0x00 | 0x00) int main(void) { int in, out, status; bios...

C# serial rs232 parity error

I'm trying to get a simple serial reader going in C# to read info from an rs232. I'm using VS2008. I can receive data fine with hyperterminal and python but I keep getting parity errors every time I try to transmit a character to C#. Number's work fine, it's just the characters. It's configured exactly the same as hyperterminal: 9600baud...

bug in serial port communication

Hi! I might just have the weirdest bug you've heard today. I have this one (very long) method inside a thread, which sends formatted data to a RS232 Led Display. It should display something like this TITLE SUBTITLE 1 ELEMENT 1 ELEMENT 2 SUBTITLE 2 ELEMENT 1 ELEMENT 2 ELEMENT 3 well, each one on it's own message. I'm calling Thread...

Multiple devices connected on serial ports - How to know which connected to which port

Hi guys, i have a few devices that communicate through serial port. Since, they are not always connected to the same serial port, so i need to know exactly which device i'm communicating with when i send data. How can I check which device is connected to which com port. ...

Recommendation for serial communications in Access 2007

I need to communicate with a bar code scanner connected over a serial port in Microsoft Access. In older versions of Access I was able to use a wrapper around MSCOMM32.ocx that no longer seems to work. I can't use wedge communication because I need to use ACK/NACK which is only supported through the RS232 interface and I need to send m...

Finding USB serial ports from a .NET application under Windows 7

I have an application that looks for a specific FTDI serial port with customised USB descriptors. My current code uses the example from Code Project, which searches the MSSerial_PortName WMI table under root\WMI, and pulls out extra USB information from root\CIMV2\WIN32_PnPEntity. This worked well under XP, but the application must also...

.NET SerialPort DataReceived event not firing

I have a WPF test app for evaluating event-based serial port communication (vs. polling the serial port). The problem is that the DataReceived event doesn't seem to be firing at all. I have a very basic WPF form with a TextBox for user input, a TextBlock for output, and a button to write the input to the serial port. Here's the code: ...

How to manage write and read in serialport when write depends on read data.

I am trying to write data to serialport and then wait for the acknowledgement. After ack is received, I write the next set of data. Please suggest a way of doing this. I tried the below code but before receiving the ack, the writing fires and completes execution. When I run it in debug mode, it works fine, but when run without breakpoint...

Strange Serial MisComunication

Ok, so I have 3 devices. an AVR Butterfly microcontroller, set up with USART A Bifferboard, running Debian, using a custom made program for serial. A Desktop machine running Br@y's. So I'm trying to make the Bifferboard send serial to the AVR, But the AVR never recieves the signal, (We've checked the wires) But if i connect the AVR to ...