5 PORT EXPANDER BOARD
You can debug the 5-port expander directly with the code in the O5Expander directory.

J1 and J8 are equivalent, parallel connectors.  You can use one to send +12V power to the board.
Use the other for talking to the board via ModBus.

J2,3,4,6,7 are the instrument ports.  You can configure the board via J2, using the menu.

To debug from a PC, you'll need a RS-485 to 232 converter.  It doesn't work well above 38400 baud,
due to the converter's line turnaround time.

Test with either ModBusView (to look at individual registers) or lib/test/oeTest.exe


6 PORT DAUGHTER BOARD - STANDALONE MODE
Debugging this board in standalone mode is a little trickier, as it's intended to use ModBus
over the SPI port from the O5 Motherboard.  But it's possible to debug it by using the
6th instrument port as an RS-232 ModBus port.  To do this, you'll need the  O5DaughterDbg project.

Also, be careful with power.  Power it with 3.3VDC on the 3.3V pin of the SPI connector.
You may also need the ground pin, but leave the other pins empty.  If you want to switch
relays or use the LED, you'll also need to insert +12VDC onto the power connector.

As mentioned, use port 6 (J12) as the ModBus input.  When compiled with -DO5_DB and -DO5_DB_DBG
(these are turned on in the O5DaughterDbg project), it will expect ModBus on that port, and
will then have just 5 instrument ports.  Connect to a PC RS-232 port, and debug with either
ModBusView or lib/test/oeTest.exe, as above.

Make sure to "Set Power at Reset" to 0x21 (config port and modbus port on)
Set "Modbus baudrate" and "Slave Address" to be consistent with your Modbus client


6 PORT DAUGHTER BOARD attached to MotherBoard
Connect both the SPI EXP 0 connector and the POWER connector on the MB to their mates on the DB.
Note that on the Proto, the INT3 and INT1 lines need to be crossed over in the cable.

On the MB, build and run the code found in ../test/modBusSerToSpi.  This echoes traffic from/to
the debug serial port on the MB to its SPI bus.

Connect the debug serial port on the MB to a PC serial port.  You can now run ModBusView
or lib/test/oeTest.exe.  The serial baud rate should be 115200 (e.g. "oeTest -b 115200")
Note that oeTest needs to be run under Cygwin.
