DMP1 Enabling a Serial Port

From Omnifi Wiki

Jump to: navigation, search
Quick Links
Linux-Inside.jpg
Related topics
  • Find Something
    • To Put Here

edit

Contents

This Started It All

Excerpt from Dan Zenchelsky's email to openfi_dev group on November 1, 2005.

...

So I started thinking that maybe we could use the LCD as an output device, instead of using a serial port.

Chad and Andy and I starting poking around the interface between the front panel and the main unit, and what we discovered was that it is an RS-485 interface, which is very similar to an RS-232 interface.

Actually, RS-485 is a bus, and there are multiple devices on this bus, including the CPU, the system PIC, and the front panel PIC. And they are all talking to each other, constantly.

But, in order for the bus to work, there needs to be a way to arbitrate who is allowed to write to it at any given time. For a long time we struggled trying to understand how that worked.

What we ultimately discovered was that the mechanism to take "ownership" of the bus is a particular GPIO bit. When you set that bit, it informs all of the devices that the CPU is going to write to the bus. And when you do that, a beautiful thing happens -- everyone else on the bus stops talking.

Suddenly, we have a nice clear serial connection, which is basically compatible with RS-232. And the beauty of it is that connections are exposed on the outside of the unit -- they are two of the pins on the front panel connector.

So, now we have a way to get debugging output from the DMP1. Simply unplug the front panel, wire two of the pins on the back of the DMP1 to a DB-9 serial connector, hook it up to your PC, and with a little bit of help from some magic software, voila!

And with that, and a few days of effort... Drumroll please...

I've brought up a fresh kernel!  :-)


Next Message

Ownership of the bus is acquired by using one of the GPIO bits on the EP7312 CPU itself. Take a look at kexec (in the boot_kernel.S file) for more information.

As far as kernel versions, I would love to get a 2.6 kernel going eventually, but I am starting with 2.4.27 because it will be easier to get all of the custom drivers running under a kernel that is closer to the existing one.

Pinout Description

Here's the pinout:

The DMP1 has a 4-pin Mini-DIN connector.

I took a MALE 4-pin Mini-DIN connector and a FEMALE DB-9 and connected them together.

I've numbered the 4-pin Mini-DIN connector according to the following diagram. I assumed that the diagram was looking into the male Mini-DIN connector on the end of the cable:

DMP1 Faceplate connector pinout diagram

For this purpose, only two pins are used:

Pin 2 of the 4-pin connector is connected to Pin 5 (GND) of the DB-9 Pin 3 of the 4-pin connector is connected to Pin 2 (RX) of the DB-9

WARNING: This information is provided with no warranty. If you use it, you do so at your own risk. Be aware that mis-connecting (or even correctly connecting) these wires could destroy your PC, your Omnifi, or both.

I would recommend that you use an external USB serial adapter on your PC, that way you won't risk burning up your internal serial adapter if something goes wrong, and you should definitely double check the voltages with a volt-meter before connecting anything together.

Good Luck!

-Dan


See Also


External Links

Lumkichi 13:23, 9 Nov 2005 (CST)

Personal tools