+ Reply to Thread
Results 1 to 4 of 4

Thread: talking to the serial port

  1. #1
    Newbie aloishis89 is an unknown quantity at this point
    Join Date
    Aug 2008
    Posts
    12

    talking to the serial port

    I am trying to use php to talk to a microcontroller via the serial port. As far as I know, there are 3 ways of doing it: using fopen(), using the serial class, and using the serial extension. I know my microcontroller code works because I can manually send stuff over the serial port and it responds as expected. I want to send a single ascii character at a time. I just want to make sure that each of the methods work the way I think and was wondering if there are any more ways. Can you talk to the serial port just using fopen()? And can I just send over ascii characters with the serial class and serial extension? I have noticed that using the serial class takes much longer than the other 2 options.

  2. #2
    Co-Administrator John is a glorious beacon of light John is a glorious beacon of light John is a glorious beacon of light John is a glorious beacon of light John is a glorious beacon of light John's Avatar
    Join Date
    Jul 2006
    Age
    21
    Posts
    5,885
    Blog Entries
    25

    Re: talking to the serial port

    In Linux you can do just about anything using fopen. I can't say the same for Windows. However, I can't begin to understand why you would want to do this using a programming language designed to implement websites.

  3. #3
    Newbie aloishis89 is an unknown quantity at this point
    Join Date
    Aug 2008
    Posts
    12

    Re: talking to the serial port

    I am actually trying to control the serial port over the web, so I can remotely control my microcontroller. I am not limited to php, if there is a better way to do that, then I am certainly open to it.

  4. #4
    Co-Administrator John is a glorious beacon of light John is a glorious beacon of light John is a glorious beacon of light John is a glorious beacon of light John is a glorious beacon of light John's Avatar
    Join Date
    Jul 2006
    Age
    21
    Posts
    5,885
    Blog Entries
    25

    Re: talking to the serial port

    I would probably use a NetBurner Embedded Ethernet Board that directly supports TCP/IP. However, if you must use a PC as a middle man, C++ (CGI) would be your best bet, but Python is also fully capable of communicating with a serial port.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

     

Similar Threads

  1. VB 6.0: Tutorial, Making a Port Scanner
    By TcM in forum VB Tutorials
    Replies: 119
    Last Post: 08-24-2009, 02:59 PM
  2. serial port problem
    By mld in forum Pascal/Delphi
    Replies: 1
    Last Post: 08-27-2008, 10:44 AM
  3. Bluetooth Serial Port
    By TcM in forum Technology Ramble
    Replies: 2
    Last Post: 02-27-2008, 11:22 AM
  4. Serial Port Close Problem in Pocket PC
    By HosseinSadeghi in forum C# Programming
    Replies: 0
    Last Post: 07-14-2007, 01:40 AM

Bookmarks

Bookmarks

     
        Algorithms and Data Structures

        Java tutorials

        Algorithms Forum

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts