Polling USB or Serial port, which is easier ?

Discussion in 'Embedded Systems and Microcontrollers' started by Sulaiman, Aug 16, 2010.

  1. Sulaiman

    Thread Starter New Member

    Aug 13, 2010
    6
    0
    Hi All,

    I just wanted to know which would be simpler to implement through hardware (software is not a problem for me)

    I will be sending 16 bits from a 16 bit shifter, and it seems like I can just shift them serially into the USB port, and then store the bits on the PC and then do my own software analysis. Is that possible ? I have read some articles that imply USB is not that simple to use...

    If not, is it possible to do that with the serial port?

    Basically my question is: what is simplest way of transferring 16 bits to a PC at any moment in time ?

    Thanks in advance.
     
  2. beenthere

    Retired Moderator

    Apr 20, 2004
    15,815
    282
    Sulaiman likes this.
  3. BMorse

    Senior Member

    Sep 26, 2009
    2,675
    234
    Or you can use a Serial to USB dongle if you do not have a serial port, the PC will "see" the USB adapter as a Serial Port....

    B. Morse
     
    Sulaiman likes this.
  4. Sulaiman

    Thread Starter New Member

    Aug 13, 2010
    6
    0
    Thanks guys :)

    lol "bit banging" sounds so funny :D Aptly named...

    Yeah I was planning on using the USB to serial adapter, but now I just have this question: How do I bit-bang the serial port? Google has been unhelpful... Could you just point me in the right direction?

    Thanks :)
     
  5. BMorse

    Senior Member

    Sep 26, 2009
    2,675
    234
    What programming language do you use for writing the PC side application?? (VB, C#, etc.)

    In VB6 you can use the MSComm control ocx, then just set the commInputMode to Binary....

    B. Morse
     
    Sulaiman likes this.
  6. Sulaiman

    Thread Starter New Member

    Aug 13, 2010
    6
    0
    I'm comfortable with any language. Just want it to be able to edit xlsx files, which I think shouldn't be a problem for VB, C# or Java...

    So I'll be using the MsComm control ocx to listen to the serial port infinitely. I hope that won't slow down the computer...

    Thanks again :)
     
Loading...