Mac68k Forums

Home


Welcome, Guest
Guest Settings
Help

Mac68k Forums » Development » Hardware Hacking

Thread: PhoneNET: the workings


Reply to this Thread Reply to this Thread Search Forum Search Forum Back to Thread List Back to Thread List

Permlink Replies: 8 - Pages: 1 - Last Post: Jul 15, 2014 3:26 PM Last Post By: Mk.558
Mk.558

Posts: 20
Registered: 5/31/14
PhoneNET: the workings
Posted: Jun 3, 2014 8:07 PM
Click to report abuse...   Click to reply to this thread Reply
This first post will be a repeat of what I wrote earlier, along with some of the replies, to help get it started.

Mk.558 wrote:
While you lot are working on your fantastic developments, would it be possible to find out a diagram of a PhoneNET connector box?

I know it uses an isolation transformer, but the wiring itself is up in the air. In fact, I don't even know which wire leads to TX and which one leads to RX.

The reason is that I have a 512Ke I'm working on and I can't figure out the proper wiring arrangement for the DE9 connector to hook up to phonenet.

I looked at: 1) the patent filing, 2) this page on CapNet, 3) and finally this page in German which at least tells me that TXD+ and RXD+ are joined together, and the same goes for RXD- and TXD-. But I'm not sure if the PhoneNET box is wired the same inside.

dougg3 replied:
I'm not completely sure about the internals but I agree that TXD and RXD will be joined together since it's only using two wires as a single differential pair. It might be easier to find a Din-8 to DB-9 adapter to hook up instead of working inside the PhoneNET box. Also, I know there are PhoneNET boxes that exist with DB-9 connectors. They should be available on eBay.

This Apple knowledge base article should have the proper pinout for you if you want to make an adapter. Just in case Apple decides to take it down in the future (I wouldn't put it past them), here's a copy of the article content:

techknight replied:
Phonenet just converts the system into an RS485 half-duplex bus network.

Mk.558 said:
I've got the pinouts for LocalTalk ports, but as for the RJ-11 pinouts, which one is TxD and which one is RxD? I may end up getting it backwards because somewhere the pins are crossed somehow so that one is TxD'ing into another's RxD.

dougg3 replies with:
I'd definitely recommend starting another thread about your PhoneNet pinout question so it doesn't get buried in my updates on this project. Here's my understanding: I don't believe PhoneNet has separate wires for RX and TX. It has a single differential pair that is used for both RX and TX -- half duplex like techknight said, so you can either transmit or receive, but not both at the same time. That's why RX+ and TX+ can be wired together, and same with RX- and TX-. The question on the RJ11 side is not which pin is RX and which pin is TX, but rather it's which pin is + and which pin is -. I know this is how Apple's LocalTalk boxes worked, and I'm pretty sure it's how PhoneNet works too. PhoneNet is just a little bit more special because it doesn't have shielding/ground and it doesn't automatically terminate the unconnected ends.

/end quotation section

So, how do I figure out which one is + and which one is -? Are they variable? A half-duplex network is not something I'm familiar with. In the radio field duplex means that you tx on one freq and rx on another, usually when you use repeaters, although trunking systems like LTR kind of flirt with the concept. A simplex system is where you tx and rx on the same freq.

I'd like to make a little picture thing in the Guide for posterity on how to make a PhoneNET homebrew edition. Really easy to get RJ-11 wire, RJ-11 6P4C jacks, some jumpers, and work the thing out. I'm not sure at this point if I should use a R-C network (resistors and some caps like CapNet) or track down some isolation transformer which will fit in .1" holes for prefabbed board materials.

P.S. Still figuring out the weird board rich text features. heh

Edit: I replied originally in dougg3's thread because he has an o-scope, which I don't and sounds like he knows what he's talking about :-)
techknight

Posts: 110
Registered: 10/13/12
Re: PhoneNET: the workings
Posted: Jun 3, 2014 9:06 PM   in response to: Mk.558 in response to: Mk.558
Click to report abuse...   Click to reply to this thread Reply
PhoneNET schematics are out there, I remember looking them up once.

Edit: Here it is
http://www.nic.funet.fi/index/mac/doc/phone-net-connectors.txt

Message was edited by: techknight
dougg3

Posts: 190
Registered: 8/13/12
Re: PhoneNET: the workings
Posted: Jun 3, 2014 9:24 PM   in response to: Mk.558 in response to: Mk.558
Click to report abuse...   Click to reply to this thread Reply
Howdy! Thanks for giving this its own thread :-)

I'm pretty sure you'd want an isolation transformer involved for protection so you don't blow anything on the Mac side. I found a post on Google Groups where someone drew some ASCII art of the PhoneNET circuit (see near the bottom of the message).

Unfortunately the message doesn't really explain what the wire colors represent, so I can't be much help. Maybe we can figure it out by tracing out an existing PhoneNET adapter.

Edit: techknight found a document, but that's for that "CapNet" thing which as far as I know is probably really similar to PhoneNET except it doesn't use a transformer.

Let me try to explain the + and - thing (and full/half duplex) a little bit:

The RS-422 serial ports on the Mac have a pair of wires for each direction. There's an RX+ and RX- pin, and a TX+ and TX- pin. Both RX wires carry the same signal, but in reverse directions. The same goes for the TX wires. The idea is that you can subtract the signal on the two wires, so if electromagnetic interference messes with both wires, the interference will cancel out when the signals are subtracted. This is why it's called differential. The Wikipedia page for differential signaling explains it pretty well, especially the diagram with the subtractors. Tons of communication schemes use this principle: USB, Ethernet, PCI Express, and CAN (controller area network) are some of the most common.

So basically: for all intents and purposes, you can think of + and - as really being a single wire that is resistant to interference.

Let's move on to full duplex and half duplex. With full duplex, you can transmit and receive at the same time. The Mac's serial port (or any PC serial port) would be a good example of full duplex. Since TX and RX are on different wires, you can simultaneously be sending and receiving. With half duplex, only one thing can transmit at a time because the entire communication medium is in use by the one thing that's transmitting. One example Wikipedia makes for half duplex is walkie-talkies.

LocalTalk is just a single differential pair of wires. There aren't separate wires on the LocalTalk bus for send and receive, so only one device can transmit at a time. This makes it half duplex. But like I said earlier, the Mac's serial port is full duplex. So to make it half duplex, you hook both the RX and the TX lines to the same single bus. When you transmit, what you transmit goes to everyone else, and it also goes right back into your own RX line, so you will receive what you transmitted out. When other people are transmitting, I believe you do something to disconnect your own TX line from the bus, or at least leave it in a state where it's not affecting other people's transmissions. What other people send will still arrive at your RX line.

With all that in mind, as far as I know, the PhoneNET adapter basically exists to combine your Mac's RX and TX signals into half duplex communication, decouple your Mac directly from the network (using the transformer), and also do some cleanup on the signals because there's no shielding or ground--only the single differential pair of the two outer wires in the RJ11 jack.

And then of course you have to terminate both ends of the bus. This is true on pretty much all buses like this. Apple's LocalTalk connectors do it automatically by using switches set up to turn termination ON unless something is plugged into both ports. PhoneNET requires the special little terminators, one on each end. Things like Ethernet already have termination on every jack, so every individual port-to-port "bus" is terminated properly.

OK, I'm rambling now. Anyway that's what I know! I think we might have to tear apart an existing PhoneNET box if we want to know for sure. That picture in one of your earlier links made it look like a pretty simple circuit.
Mk.558

Posts: 20
Registered: 5/31/14
Re: PhoneNET: the workings
Posted: Jun 4, 2014 7:49 PM   in response to: Mk.558 in response to: Mk.558
Click to report abuse...   Click to reply to this thread Reply
Copy that on the differential signaling principle. I want to get back into electronics, I got in part way but am currently distracted by the need to finish the Guide and other things.

I haven't looked into one-wire serial protocols but I've heard of them. I believe they have some pretty hefty limitations, like 9600bps max. Two wires gets you much farther.

I have a DIN-8 PhoneNET adapter I can offer up for examination. It's been knackered a bit because they're difficult to open (this was last year when I tried to open it). I also have a Focus TurboNET ST, which has activity LEDs and a termination on/off switch.

We'll also need to get a handle on a repectable 1:1 isolation transformer. Should be something you can pick up a Mouser or Jameco.
dougg3

Posts: 190
Registered: 8/13/12
Re: PhoneNET: the workings
Posted: Jun 4, 2014 8:21 PM   in response to: Mk.558 in response to: Mk.558
Click to report abuse...   Click to reply to this thread Reply
Yeah, I think one-wire stuff doesn't work too well with long distances. I know coax cable is a little more reliable, but definitely not something like one wire inside of telephone cables.

Awesome! I think I probably have some PhoneNET adapters around here somewhere too. I didn't realize they were difficult to open though. It would be nice to inspect what transformer they used so we can try to identify a similar one to use. I have no idea how to identify what type of transformer to use for anything. I know they have a turns ratio, but other than that I'm pretty clueless.

I can't imagine it'll be tough to figure out the connections. The picture on the page you linked earlier makes me think that it may be a single-sided PCB. There's a trace going to every pad on the bottom side of the board. If that is indeed a PhoneNET PCB in that picture, we may be able to identify every connection except what wires go to what from the Mac's serial port to the PCB. It would help if the transformer and any resistors/capacitors could be identified on the PCB.

It would be sweet to add a termination switch like the TurboNET ST too :-)
Mk.558

Posts: 20
Registered: 5/31/14
Re: PhoneNET: the workings
Posted: Jun 5, 2014 10:51 PM   in response to: dougg3 in response to: dougg3
Click to report abuse...   Click to reply to this thread Reply
Yeah I've opened the TurboNET ST and lost the little plastic piece that helps you turn on the termination. Ahh well the switch is still functional, but I think the activity LEDs (both operate at the same time, weird) help a lot in figuring out dead spots in the network.

I'll get some pictures thrown up. IIRC the TurboNET does have a couple of 1/8W resistors on it, maybe two caps. Probably the disc type, can't remember. The PhoneNET is just a single sided PCB with a isolation transformer. From what the patent description said it's a 100:100 or something like that ratio. I'm partial to CapNET because then people don't have to pull up some weird transformer that is only available in batches of 5000 and has a six-week ordering lead Also Known As Digikey.

Just kidding. Isolation transformers with 1;1 ratio are commonly stocked all over the place. Because of my compulsive "need to know" complex I tried opening my Farallon iPrint LT but I didn't want to break anything -- I really like that bridge and it works without a single issue.

Recently I procurred a Cayman System Gatorbox from a well-known 68kmla member but I/we don't have a 16V AC 1A power adapter. I think it's a 2.1mm or similar size barrel jack kind. I'll see if WeirdStuff has anything in a while. They should, they have entire boxes of specific voltages, whatever you want -- 3v3, 5v, 6v, etc.
techknight

Posts: 110
Registered: 10/13/12
Re: PhoneNET: the workings
Posted: Jun 6, 2014 10:31 PM   in response to: Mk.558 in response to: Mk.558
Click to report abuse...   Click to reply to this thread Reply
1:1 isolation transformers are fine and dandy, but you have to watch out because of the number of turns. Some could have 50 turns to 50 turns, 150 turns to 150 turns, etc.. as the different number of windings represent the overall impedance on each side of the circuit across the transformer. You need a transformer with the correct number of turns that matches the 120 ohm drive impedance of a pair of wire. Twisted or whatnot.

What you could do, is pick up some RJ45 Jacks with on-board matching transformers, or just plain old matching transformers for ethernet standalone. They should be 1:1 and will have a turns ratio compatible with the speeds/impedances your working with. :-)
Mk.558

Posts: 20
Registered: 5/31/14
Re: PhoneNET: the workings
Posted: Jun 7, 2014 4:22 PM   in response to: techknight in response to: techknight
Click to report abuse...   Click to reply to this thread Reply
^ right on.

http://i.imgur.com/73KYr0l.png
http://i.imgur.com/SqBTTW9.png

Message was edited by: Mk.558
Mk.558

Posts: 20
Registered: 5/31/14
Re: PhoneNET: the workings
Posted: Jul 15, 2014 3:26 PM   in response to: Mk.558 in response to: Mk.558
Click to report abuse...   Click to reply to this thread Reply
Just for future reference, I had an RJ-11 cable split open to reveal the two inner wires. I think hooked those up to copper alligator clips to two of the pins of a AppleTalk cable. It works either way, there's no "this wire goes to that and this wire goes to here": it's reversible.

Point your RSS reader here for a feed of the latest messages in all forums