Serial modem

Question about which tools to use, bugs, the best way to implement a function, etc should go here. Don't forget to see if your question is answered in the wiki first! When in doubt post here.
Post Reply
User avatar
salil_bhagurkar
Member
Member
Posts: 261
Joined: Mon Feb 19, 2007 10:40 am
Location: India

Serial modem

Post by salil_bhagurkar »

Hello guys... I have a dialup modem connected on my serial port.. I wanted to do some network programming on my os.. So could you please guide me on how to program the modem...
User avatar
Brynet-Inc
Member
Member
Posts: 2426
Joined: Tue Oct 17, 2006 9:29 pm
Libera.chat IRC: brynet
Location: Canada
Contact:

Post by Brynet-Inc »

Most Serial or ISA modems respond to AT commands..

So just Google: "AT modem commands"

You may also want to read up the protocols used for dial-up networking, PPP is common.

Have fun... 8)
Last edited by Brynet-Inc on Mon Aug 20, 2007 12:29 pm, edited 1 time in total.
Image
Twitter: @canadianbryan. Award by smcerm, I stole it. Original was larger.
User avatar
salil_bhagurkar
Member
Member
Posts: 261
Joined: Mon Feb 19, 2007 10:40 am
Location: India

Post by salil_bhagurkar »

So do i send these commands directly to the serial port or do i have some other protocols to use? (apart from modem ack and all..)

Also please tell me about how to go about networking after i am able to program the modem (the basics please..)
User avatar
Brynet-Inc
Member
Member
Posts: 2426
Joined: Tue Oct 17, 2006 9:29 pm
Libera.chat IRC: brynet
Location: Canada
Contact:

Post by Brynet-Inc »

I think the following Wikipedia article will clear a few more things up...

Hope it helps, apologies for not being able to explain it myself in more detail..

http://en.wikipedia.org/wiki/Hayes_command_set
http://www.modem.com/general/extendat.html

Most of the "Standard" commands should be accepted by most modems, Your modem may have extensions.. and I think there is a way of "asking" your modem to display them.
Image
Twitter: @canadianbryan. Award by smcerm, I stole it. Original was larger.
User avatar
salil_bhagurkar
Member
Member
Posts: 261
Joined: Mon Feb 19, 2007 10:40 am
Location: India

Post by salil_bhagurkar »

Sorry if i am bothering u too much.. But i have understood the modem... I need some basics on networking at core level... (IP implementation)...
User avatar
Brynet-Inc
Member
Member
Posts: 2426
Joined: Tue Oct 17, 2006 9:29 pm
Libera.chat IRC: brynet
Location: Canada
Contact:

Post by Brynet-Inc »

Well, Wikipedia is an excellent resource.. 8)
http://en.wikipedia.org/wiki/Internet_protocol_suite

For the individual protocols see:
http://en.wikipedia.org/wiki/Internet_Protocol
http://en.wikipedia.org/wiki/Address_Re ... n_Protocol
http://en.wikipedia.org/wiki/Transmissi ... l_Protocol
http://en.wikipedia.org/wiki/User_Datagram_Protocol
http://en.wikipedia.org/wiki/Internet_C ... e_Protocol (Some implement this before TCP or UDP.. A subset anyway.)

Most people then implement the BSD sockets API after implementing the above protocols.

Hope it helps...
Image
Twitter: @canadianbryan. Award by smcerm, I stole it. Original was larger.
pcmattman
Member
Member
Posts: 2566
Joined: Sun Jan 14, 2007 9:15 pm
Libera.chat IRC: miselin
Location: Sydney, Australia (I come from a land down under!)
Contact:

Post by pcmattman »

salil_bhagurkar wrote:Sorry if i am bothering u too much.. But i have understood the modem... I need some basics on networking at core level... (IP implementation)...
I'd implement an ethernet card driver first, then you can build the layers of functionality over the top of that (just work within your LAN for the time being, it's much easier to debug).

The network layers should be written in such a way that they send/recv packets via an interface, so that they work for any device that sends or receives packets (that way you could have eth0, eth1, mod0 all using the same higher-level code).
Post Reply