Discussion:
PPP over RS-485
Linux PPP
2003-03-12 11:16:36 UTC
Permalink
Hi all,
am currently working on PPP over serial interface (RS485) in linux 2.4.2-2. I believe RS485 half duplex system and hence only one can transmit at a time. And for RS485 we basicaly use Master-Slave or Primary-Secondary kind of communication. I don't know how to achieve the same using PPP since i need to have max of 10 nodes connected via serial interface. I tested with two nodes using PPP daemon it works fine. Following are the commands i issued

In PPP server:
$usr/sbin/pppd -detach crtscts 10.10.10.100:10.10.10.101 115200 /dev/ttyS0 &

In PPP client side :
$/usr/sbin/pppd call ppp-start
where ppp-start file is copied into directory /etc/ppp/peers/ that had the following

-detach /dev/ttyS0 115200 crtscts
noauth

This point to point communication worked fine with RS485 interface. If i had to connect one more node what i need to do. Please clarify with the following

i) Whether the existing pppd takes care of the RS485 with multi node , if so how do i manage giving commands
ii) If there is no direct support how do i go ahead.

I will be grateful if anybody of them could help me with my current problem.

Thanx in advance.


Karthik
--
______________________________________________
http://www.indiainfo.com
Now with POP3/SMTP access for only US$14.95/yr

Powered by Outblaze
-
To unsubscribe from this list: send the line "unsubscribe linux-ppp" in
the body of a message to ***@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
James Carlson
2003-03-12 12:03:10 UTC
Permalink
Post by Linux PPP
am currently working on PPP over serial interface (RS485) in linux
2.4.2-2. I believe RS485 half duplex system
Indeed.
Post by Linux PPP
and hence only one can
transmit at a time. And for RS485 we basicaly use Master-Slave or
Primary-Secondary kind of communication.
PPP requires a full-duplex link. It does not have the sorts of
line-turn-around, polling, or collision resolution necessary to handle
half-duplex operation.
Post by Linux PPP
I don't know how to achieve
the same using PPP since i need to have max of 10 nodes connected
via serial interface. I tested with two nodes using PPP daemon it
works fine. Following are the commands i issued
I'm sort of surprised that you're able to get that to work. :-/
Post by Linux PPP
This point to point communication worked fine with RS485 interface. If i had to connect one more node what i need to do. Please clarify with the following
i) Whether the existing pppd takes care of the RS485 with multi node
, if so how do i manage giving commands
Nope ... no support.
Post by Linux PPP
ii) If there is no direct support how do i go ahead.
You're going to have to hack the Linux kernel bits that implement PPP.
Fortunately, you have source available, so have at it.

I'm not quite sure that what you are proposing to do is actually
feasible. You'll need some way of resolving the fact that there's no
"master" node involved here, and that any node can attempt to transmit
at any time. Once you get past that (uh, somehow), you'll need to
make a single physical interface look like multiple logical
interfaces, and run a separate copy of pppd on each. That should be a
fairly simple driver change once the half-duplex operation issues are
worked out.
--
James Carlson <***@workingcode.com>
-
To unsubscribe from this list: send the line "unsubscribe linux-ppp" in
the body of a message to ***@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Andrew Gay
2003-03-12 17:00:23 UTC
Permalink
Interesting project, but I don't think you should be attempting to use
PPP for this. PPP, by definition, is for point-to-point connections.
RS-485 is a multiaccess medium with similar media access control
requirements to an ethernet. Three or more nodes on the wire and you've
clearly moved away from the point-to-point model.
You may get better help if you ask around on the general kernel/device
driver lists to see if anyone has done any work on this type of system.
Good luck...
Andy
Post by Linux PPP
Hi all,
am currently working on PPP over serial interface (RS485) in linux 2.4.2-2. I believe RS485 half duplex system and hence only one can transmit at a time. And for RS485 we basicaly use Master-Slave or Primary-Secondary kind of communication. I don't know how to achieve the same using PPP since i need to have max of 10 nodes connected via serial interface. I tested with two nodes using PPP daemon it works fine. Following are the commands i issued
$usr/sbin/pppd -detach crtscts 10.10.10.100:10.10.10.101 115200 /dev/ttyS0 &
$/usr/sbin/pppd call ppp-start
where ppp-start file is copied into directory /etc/ppp/peers/ that had the following
-detach /dev/ttyS0 115200 crtscts
noauth
This point to point communication worked fine with RS485 interface. If i had to connect one more node what i need to do. Please clarify with the following
i) Whether the existing pppd takes care of the RS485 with multi node , if so how do i manage giving commands
ii) If there is no direct support how do i go ahead.
I will be grateful if anybody of them could help me with my current problem.
Thanx in advance.
Karthik
-
To unsubscribe from this list: send the line "unsubscribe linux-ppp" in
the body of a message to ***@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
James Carlson
2003-03-12 17:10:15 UTC
Permalink
Post by Andrew Gay
Interesting project, but I don't think you should be attempting to use
PPP for this. PPP, by definition, is for point-to-point connections.
RS-485 is a multiaccess medium with similar media access control
requirements to an ethernet.
The multiaccess issues aren't all that bad -- PPP uses HDLC, and HDLC
has a perfectly serviceable L2 addressing mechanism, which is used
when you run PPP over X.25 or Frame Relay. That could be used here
(disabling ACFC, changing the initial 0xFF out of the 0xff 0x03 header
into a real address). The nasty bit is the half-duplex nature. The
original poster is going to have to figure out how to make this
half-duplex medium appear to be full-duplex, with asynchronous
transmission from any node.
Post by Andrew Gay
Three or more nodes on the wire and you've
clearly moved away from the point-to-point model.
You may get better help if you ask around on the general kernel/device
driver lists to see if anyone has done any work on this type of system.
Indeed.
--
James Carlson <***@workingcode.com>
-
To unsubscribe from this list: send the line "unsubscribe linux-ppp" in
the body of a message to ***@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Loading...