Thread: a question

  1. #1
    Registered User
    Join Date
    Jun 2003

    Question a question

    I want to conect two computer by their serial port,
    enter data in one and see them in another.
    I should use C or C++ programing.
    can you tell me how should I do?
    I don't know C & C++ enough ...
    thank you for your help.

  2. #2
    Banned master5001's Avatar
    Join Date
    Aug 2001
    Visalia, CA, USA
    You should be able to do this using fopen(). The first param should be something like "COM1" or whatever port you decide to use, and of course the second param should be the type of access you want (i.e. read, write). If you can't get this to work it will depend on your os.
    Last edited by master5001; 06-30-2003 at 04:53 AM.

  3. #3
    Registered User
    Join Date
    Nov 2001
    Here is a link to MSDN that shows a good design sample from Microsoft.


  4. #4
    Registered User
    Join Date
    Jun 2003
    Ya.....fopen() is right way to open port as file and then read and write through that handle.

    One more important thing : you will have to use NULL MODEM CABLE to connect your two computers through COM port.
    Chintan R Naik

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Alice....
    By Lurker in forum A Brief History of
    Replies: 16
    Last Post: 06-20-2005, 02:51 PM
  2. Debugging question
    By o_0 in forum C Programming
    Replies: 9
    Last Post: 10-10-2004, 05:51 PM
  3. Question about pointers #2
    By maxhavoc in forum C++ Programming
    Replies: 28
    Last Post: 06-21-2004, 12:52 PM
  4. Question...
    By TechWins in forum A Brief History of
    Replies: 16
    Last Post: 07-28-2003, 09:47 PM
  5. Question, question!
    By oskilian in forum A Brief History of
    Replies: 5
    Last Post: 12-24-2001, 12:47 AM
Website Security Test