GIDForums  

Go Back   GIDForums > Computer Programming Forums > C Programming Language
User Name
Password
Register FAQ Members List Calendar Search Today's Posts Mark Forums Read

 
 
Thread Tools Search this Thread Rate Thread
  #1  
Old 17-Jun-2009, 01:27
nishu1988 nishu1988 is offline
New Member
 
Join Date: Jul 2007
Posts: 10
nishu1988 is on a distinguished road

Waveforms through an rs232 port in the computer


I am working on a project in which an ECG sends out waveforms through an rs232 port in the computer and the waveform gets printed dynamically on a grid.I am new to c programming and need some tutorials regarding hardware interfacing and port programming(both parallel and serial)...can anybody advise me on this matter...???


Eagerly waiting for a reply...




nishant
  #2  
Old 17-Jun-2009, 01:29
nishu1988 nishu1988 is offline
New Member
 
Join Date: Jul 2007
Posts: 10
nishu1988 is on a distinguished road

port help...!!!


Do i need to learn file handling for this...???

and buffer memory mapping for scrolling this waveform on the screen...??
  #3  
Old 17-Jun-2009, 05:13
Mexican Bob's Avatar
Mexican Bob Mexican Bob is offline
Regular Member
 
Join Date: Mar 2008
Location: Chicxulub, Yucatán
Posts: 342
Mexican Bob is a jewel in the roughMexican Bob is a jewel in the roughMexican Bob is a jewel in the roughMexican Bob is a jewel in the rough

Re: Waveforms through an rs232 port in the computer


Quote:
Originally Posted by nishu1988
I am working on a project in which an ECG sends out waveforms through an rs232 port in the computer and the waveform gets printed dynamically on a grid.I am new to c programming and need some tutorials regarding hardware interfacing and port programming(both parallel and serial)...can anybody advise me on this matter...???


Eagerly waiting for a reply...




nishant

There is no such thing as an RS232 port in C.

Computer is an incredibly ambiguous term. There are several billion computers in the world, of which only a few hundred million are PCs. Did you have some kind of system in mind and does that system run some kind of operating system? Perhaps if you would take a moment to give us some information about your hardware platform, operating system (if any) and the details of what C programming tools/software you're using or are planning to use?


MxB
  #4  
Old 17-Jun-2009, 05:27
Mexican Bob's Avatar
Mexican Bob Mexican Bob is offline
Regular Member
 
Join Date: Mar 2008
Location: Chicxulub, Yucatán
Posts: 342
Mexican Bob is a jewel in the roughMexican Bob is a jewel in the roughMexican Bob is a jewel in the roughMexican Bob is a jewel in the rough

Re: port help...!!!


Quote:
Originally Posted by nishu1988
Do i need to learn file handling for this...???

and buffer memory mapping for scrolling this waveform on the screen...??

There is no such thing as a screen in C. Some software tools make output devices, such as a video graphics chipset, available to C programmers through custom API, such as OpenGL, which directly interacts with the video hardware in supported devices on supported platforms with related drivers.

Still other custom API make terminal or console "graphics" available to C programmers.

There are numerous API for a variety of platforms from very robust and extensible to very low-level, but C, the programming language, knows of none of these directly.

If you are already in an environment such as a typical desktop or workstation Linux distribution or Mac OS-X or Windows, then you probably have a lot of API available to you once you install the tools that you wish to use for your C programming efforts. In such cases, you will also have some restrictions that you'll need to consider with regard to accessing serial port hardware directly from your application-level code.

Without more information about your particular world, there isn't much more that I can say without going on a multi-page lecture about all things serial "port" related. You probably don't want that and I know that I don't want to type it all out right now, either.


MxB
  #5  
Old 19-Jun-2009, 01:13
nishu1988 nishu1988 is offline
New Member
 
Join Date: Jul 2007
Posts: 10
nishu1988 is on a distinguished road

Re: Waveforms through an rs232 port in the computer


Thanx a lot for your advice....and info, i just need some tutorials of serial port programming in c/c++.....
  #6  
Old 19-Jun-2009, 02:56
Mexican Bob's Avatar
Mexican Bob Mexican Bob is offline
Regular Member
 
Join Date: Mar 2008
Location: Chicxulub, Yucatán
Posts: 342
Mexican Bob is a jewel in the roughMexican Bob is a jewel in the roughMexican Bob is a jewel in the roughMexican Bob is a jewel in the rough

Re: Waveforms through an rs232 port in the computer


Quote:
Originally Posted by nishu1988
Thanx a lot for your advice....and info, i just need some tutorials of serial port programming in c/c++.....

So, you really didn't understand a single thing previously posted, right?

There is no such thing as serial port programming in C/C++. There are only IMPLEMENTATION SPECIFIC accesses to the "serial port" that are DIFFERENT based on the SYSTEM (hardware and operating system combined).

Because nearly every imaginable microcontroller and numerous variants of microprocessors have "serial" data communication ports, you can not FIND a "tutorial(s) of serial port programming" in C/C++ WITHOUT FIRST identifying your platform.

Are you using a PC? Are you running Windows, Linux, something else?

The way to access a serial port on a PC platform is significantly different DEPENDING on the operating system used. The closest thing to a "tutorial" that covers a wide variety of platforms and operating systems is a book entitled Serial Port Complete and another called Serial Communications Programming in C and C++.

If you are running Windows-specifically, The Windows Serial Port Programming Handbook is a very good book, but the MSDN has a complete example of serial port programming in CODE through the mttty example.

http://msdn.microsoft.com/en-us/library/ms810467.aspx

If you are running Linux, http://tldp.org/HOWTO/Serial-Programming-HOWTO/ and http://www.comptechdoc.org/os/linux/...pgcserial.html has CODE.

If you are running a DOS variant, http://www-cdr.stanford.edu/biomimet...al/serial.html may be helpful.

However, if you're running any one of several dozens of other, non-PC hardware platforms OR are using a different operating system on PC hardware, these won't help very much.


MxB
 
 

Recent GIDBlogInstall Adobe Flash - Without Administrator Rights by LocalTech

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Hard drive/CPU Diagnoses Issues binarybug Computer Hardware Forum 1 22-Jan-2007 19:23
Serial Port Communication a3.charles C Programming Language 0 03-Aug-2006 23:42
Code for receiving data from parallel port in VB.net harry.net .NET Forum 1 10-Mar-2006 15:41
Problem to read on a serial port collinm C Programming Language 2 30-Mar-2005 01:42
Problem with string and serial port collinm C Programming Language 13 25-Mar-2005 07:39

Network Sites: GIDNetwork · GIDWebHosts · GIDSearch · Learning Journal by J de Silva, The

All times are GMT -6. The time now is 10:35.


vBulletin, Copyright © 2000 - 2010, Jelsoft Enterprises Ltd.