+ Reply to Thread
Results 1 to 9 of 9

Thread: virtual modem question

  1. #1

    Default virtual modem question

    HI everyone,

    I've bee playing with SX microcontrollers for a couple of weeks and I have a question I haven't been able to find a answer to. Is it possible to virtualize a 9600, or higher, baud modem? If so, how? Thanks for any help.
    Last edited by ForumTools; 09-30-2010 at 01:27 PM. Reason: Forum Migration

  2. #2

    Default

    Why roll your own modem when you can get them complete for $15 on Ebay? The following is a link to an article about mating an embedded processor to an inexpensive modem:

    http://www.downtowninternet.com/elpr...demappnote.pdf

    This article talks about using a PIC, but its a simple matter to connect the serial port (USART or bitbanger) of most any embedded processor to a serial modem. You can realize port speeds of 115k, easy. Use a virtual serial port (USART) to send AT commands (ASCII characters) and data to the modem. You can evenuse handshake and control lines to monitor conditions of phone calls and carrier presence. This article even has a limited discussion on sending out prerecorded messages or music.

    kenjj
    Last edited by ForumTools; 09-30-2010 at 01:27 PM. Reason: Forum Migration

  3. #3

    Default

    > Why roll your own modem when you can get them complete for $15 on Ebay?

    If you can virtualize it in software it makes the hardware less complex. Also part of the fun of experimenting with microcontrollers is doing everything yourself.
    Last edited by ForumTools; 09-30-2010 at 01:27 PM. Reason: Forum Migration

  4. #4

    Default

    I am certain that it possible. I'm pretty sure modems useFrequency Shift Keying (FSK)to transmit data over phone lines. http://www.parallax.com/sx/downloads.asphas some example code for FSK. And to dial a number DTMF is used, there is some sample code (at least to receive DTMF) on the page as well. You'll have to isolate the phone plug connector, because the line can have 50V on it at times. You'll also need to search around for the exact format for modem communications. But the SX has more than enough horsepower to do 9600 baud modem communications.

    Paul
    Last edited by ForumTools; 09-30-2010 at 01:27 PM. Reason: Forum Migration

  5. #5

    Default

    http://www.sxlist.com/techref/ubicom/lib/io/dev/modem/index.htm has all the known code for doing that. In fact, sxlist.com has all the known code for doing ANYTHING with an SX.

    Doesn't it?

    Prove me wrong! <GRIN>

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    ---
    James Newton, Host of SXList.com
    james@sxlist.com 1-619-652-0593 fax:1-208-279-8767
    SX FAQ / Code / Tutorials / Documentation:
    http://www.sxlist.com Pick faster!



    Last edited by ForumTools; 09-30-2010 at 01:27 PM. Reason: Forum Migration

  6. #6

    Default

    Nothing stops you from EXPERIMENTING with using an SX as a modem. Hooking two PCs together with two SXs running as virtual modems as an educational exercise is great.
    However, if you plan to use this in a real world situation as a daily application, then things get VERY differnt. If you read the article I mentioned you'll see that you have to connect your project to the phone lines through an FCC approved interface. Failure to do so can lead to fines of $10,000 a day and/or jail time. The article also points you to a company that sells a product that is an approved interface for $40, as of the article's original writing.

    Even a cheap modem give you the DTMF tone genrator, a carrier detect signal (and others), and an established control system to take advantage of.
    Hey, I just don't want to see anyone get slammed by big brother.

    Have fun.

    kenjj
    Last edited by ForumTools; 09-30-2010 at 01:27 PM. Reason: Forum Migration

  7. #7

    Default

    James Newton said...
    http://www.sxlist.com/techref/ubicom/lib/io/dev/modem/index.htm has all the known code for doing that. In fact, sxlist.com has all the known code for doing ANYTHING with an SX.

    Doesn't it?

    Prove me wrong! <GRIN>

    uhhh, couldn't find code for a 1+ mbps IR data link... ...had to write that on my own.

    -Dan
    Last edited by ForumTools; 09-30-2010 at 01:27 PM. Reason: Forum Migration

  8. #8

    Default

    dkemppai said...
    uhhh, couldn't find code for a 1+ mbps IR data link... ...had to write that on my own.
    Pant, pant...

    I don't suppose that code could be open source? Willing to share?


    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    ---
    James Newton, Host of SXList.com
    james@sxlist.com 1-619-652-0593 fax:1-208-279-8767
    SX FAQ / Code / Tutorials / Documentation:
    http://www.sxlist.com Pick faster!



    Last edited by ForumTools; 09-30-2010 at 01:27 PM. Reason: Forum Migration

  9. #9

    Default

    FSK stuff is not too hard, but anything above 2400 is not FSK, but PSK. It's much harder to decode, as the algorithms are best suited to a DSP. Another problem is that modems generally need to support fallbacks, so support for any higher speed would mean also including support for the lower fallback speeds as well. There's simply not enough code to do it...
    Last edited by ForumTools; 09-30-2010 at 01:27 PM. Reason: Forum Migration

+ Reply to Thread

Bookmarks

Posting Permissions

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