473,775 Members | 2,570 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

how can I use the Serial COM port ???

I have a device that send to my computer information by serial com port.
The comunication parameters are:

PORT: COM 1
Bits per second: 9600
Data bits: 8
Parity: None (0)
Stop bits:1

How can I receive or transfer DATA by COM 1 serial port ???
Nov 16 '05 #1
3 2245
http://msdn.microsoft.com/msdnmag/is...netserialcomm/

"Swatcat" <Sw*****@discus sions.microsoft .com> wrote in message
news:37******** *************** ***********@mic rosoft.com...
I have a device that send to my computer information by serial com port.
The comunication parameters are:

PORT: COM 1
Bits per second: 9600
Data bits: 8
Parity: None (0)
Stop bits:1

How can I receive or transfer DATA by COM 1 serial port ???

Nov 16 '05 #2
Hi Swatcat,

1) By C#, you can find references on serial com port.

3 ways:
a) using the ActiveX MSComm.ocx
b) manually write a library with platform invocation to kernel32.dll - check in gotdotnet workspaces, there is around 3 - 4 good examples.
c) wait for .net framework 2.0, there will be a built in. Probably this is not the best option.

2) If you want to test whether is there any data being transfer on your serial com port. Use this software. Quite amazing. I used it all the time.

HDD Serial Monitor:
http://www.hhdsoftware.com/Download/sermonlt.exe

Hope it helps.
--
Regards,
Chua Wen Ching :)
"Swatcat" wrote:
I have a device that send to my computer information by serial com port.
The comunication parameters are:

PORT: COM 1
Bits per second: 9600
Data bits: 8
Parity: None (0)
Stop bits:1

How can I receive or transfer DATA by COM 1 serial port ???

Nov 16 '05 #3
Hi,
I've had to do quite a lot of serial comms using C# and in my
experience this is the most lightweight/reliable/high
performance/easy-to-use library out there at the moment:

http://www.codeproject.com/dotnet/DotNetComPorts.asp

Its been used with many many different microcontroller s (including
Nokia mobile phones) with no problems (in contrast to some other
libraries out there - including the one on gotdotnet).

HTH
Kieran

"Chua Wen Ching" <ch************ @nospam.hotmail .com> wrote in message news:<2B******* *************** ************@mi crosoft.com>...
Hi Swatcat,

1) By C#, you can find references on serial com port.

3 ways:
a) using the ActiveX MSComm.ocx
b) manually write a library with platform invocation to kernel32.dll - check in gotdotnet workspaces, there is around 3 - 4 good examples.
c) wait for .net framework 2.0, there will be a built in. Probably this is not the best option.

2) If you want to test whether is there any data being transfer on your serial com port. Use this software. Quite amazing. I used it all the time.

HDD Serial Monitor:
http://www.hhdsoftware.com/Download/sermonlt.exe

Hope it helps.
--
Regards,
Chua Wen Ching :)
"Swatcat" wrote:
I have a device that send to my computer information by serial com port.
The comunication parameters are:

PORT: COM 1
Bits per second: 9600
Data bits: 8
Parity: None (0)
Stop bits:1

How can I receive or transfer DATA by COM 1 serial port ???

Nov 16 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
9094
by: ^CeFoS^ | last post by:
Hello to everybody, I've done an application that draws in a frame the trajectory of a robot. The robot position is readed through the serial port, and several commands are wrote through the same port to change the direction of the robot. The trajectory frame is managed by an applet, and the project works good when the applet is called by a html document allocated in the same local machine under W98 where the classes and the serial port...
2
13195
by: willie | last post by:
Hi, I'm writing a program which requires the use of three serial ports and one parallel port. My application has a scanning devices on each port, which I can access fine with pyserial. However, I'm unsure of how exactly I should be designing the program, I thought I could use threading to start class: class scanner(Thread): def __init__(self,port):
3
5055
by: collinm | last post by:
hi i send a command to a led display, the led display is suppose to return me some character i write a string on a serial port void ledDisplayExist() { char msg={'\0', '\0', '\0', '\0', '\0', '\1', 'Z', '0', '0',
13
4833
by: Al the programmer | last post by:
I need to access the serial ports on my webserver from an asp.net page. I have no problem accessing the serial ports from a windows form application, but the code doesn't work in asp.net. I have been told it is not possible to access the serial ports from asp.net. The application is used to control custom hardware. The hardware is connected to a PC through serial ports. Our customer wants to control the hardware from a remote...
4
11207
by: joe bloggs | last post by:
I am writing a mobile application to interface with a legacy system and I am planning to use web services to communicate with this system. The legacy system receives data through a serial port. What I would like to do is make the serial port accessible via a web service. The web service and the legacy application would be running on the same machine. The mobile application would access the web service via a network connection. It...
4
17822
by: Frank | last post by:
Hello, how to get information about all serial ports in the PC? I use the following code, but i got only the data of the FIRST serial port. All other serial port information are not available with this code sample: ManagementObjectSearcher searcher = new ManagementObjectSearcher("Select * from WIN32_SerialPort");
13
6210
by: Rob | last post by:
Hi all, I am fairly new to python, but not programming and embedded. I am having an issue which I believe is related to the hardware, triggered by the software read I am doing in pySerial. I am sending a short message to a group of embedded boxes daisy chained via the serial port. When I send a 'global' message, all the connected units should reply with their Id and Ack in this format '0 Ack' To be certain that I didn't miss a...
4
11798
by: rowan | last post by:
I'm writing a driver in Python for an old fashioned piece of serial equipment. Currently I'm using the USPP serial module. From what I can see all the serial modules seem to set the timeout when you open a serial port. This is not what I want to do. I need to change the timeout each time I do a "read" on the serial port, depending on which part of the protocol I've got to. Sometimes a return character is expected within half a second,...
3
11632
by: naveen.sabapathy | last post by:
Hi, I am trying to use virtual serial ports to develop/test my serial communication program. Running in to trouble... I am using com0com to create the virtual ports. The virtual ports seem to be working fine when I test it with Hyperterminal . I am using the example program that comes with pyserial, as below. --------------- import serial
6
6669
by: terry | last post by:
Hi, I am trying to send a character to '/dev/ttyS0' and expect the same character and upon receipt I want to send another character. I tired with Pyserial but in vain. Test Set up: 1. Send '%' to serial port and make sure it reached the serial port. 2. Once confirmed, send another character.
0
9622
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9454
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10268
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
8939
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7464
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6718
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5360
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
1
4017
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3611
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.