multiplexer_usb by nuhman10


									                                     SD NMEA multiplexer


      The idea for the multiplexer with SD logger was for me to produce
      Underwater maps, and did not like having the laptop on all the time,
      Because of power drain 50W!! And also water damage.

      So I added a SD card to the multiplexer so now no PC is required,
      And logging could be done on a small boat using a small battery.

      The digital multiplex switcher can take its digital signals and multiplex
      Them to one output, the signal must be digital and up to a data rate of 38400

      The unit does not buffer the input signals , they are switched in turn
      to the output channel, after a gap detected.

      Channel 1 has a alarm feature where if no signal is seen for 3 seconds
      a alarm will sound ,this should be used for the GPS.

      The unit will only switch to channels with data so time is not spent
      Waiting on a channel with no data.

Boat electronic projects          page 1 of 10                           24/04/2011
Com port installation

   1) Plug In the USB device and when asked point to driver directory
      D:\driver or where drivers are and click next.

Boat electronic projects          page 2 of 10                          24/04/2011
   2) Check USB Serial port by selecting.
      Start->settings->control panel->system->hardware->device manager.
      Or use auto-detect if using the windows software can-tester.
      See picture above.

              Driver supports windows XP, Vista,2000

   Your PC application can not use this com port above it was installed as
   COM19 USB serial port.

Boat electronic projects          page 3 of 10                          24/04/2011
NMEA Background

NMEA-0183 is a standard for interfacing marine electronic devices. This standard
defines the electrical signal requirements, data transmission protocol, data
transmission timing, and specific message formats for a 4800 baud serial data

NMEA 0183 devices employ an asynchronous serial interface with the following

Baud Rate     4800
Data Bits     8(d7=0)
Parity        None
Stop Bits     One (or more)

Devices are designated as either talkers or listeners with some devices being both. A
talker is any device which sends data to other NMEA 0183 devices. A listener is any
device which receives data from other NMEA 0183 devices. Instruments which are
both talker and listener will have separate connections for each function. All data
either transmitted or received is interpreted as 8 bit ASCII (d7=0).

                              Electrical Requirements


Under the latest version of the standard, NMEA 0183 talkers are supposed to be
differential drive compatible with EIA RS-422. Differential drive signals have no
reference to Ground and are more immune to noise. Earlier versions of the NMEA
0183 standard allowed single-ended drive circuitry for talker(s) (i.e., 0 to +15VDC).
Therefore, there are still instruments around which are not differential drive output. A
single talker can drive multiple listeners within drive current limitations.


NMEA 0183 listeners are supposed to have input isolation from the ships Ground.
Opto-isolation, which is generally used to meet this requirement, limits the input
impedance. The standard specifies a minimum input resistance for listeners of 500
ohms and most devices will probably be close to this value.

Boat electronic projects          page 4 of 10                            24/04/2011
         USB interface
         SD card logging max 1Gb (approx 38 days at 300 bytes/s)
         4 opto-isolated inputs 680 ohm input impendence
         Differential drive output (RS422 levels only) drive 2 opto inputs
         4 Leds for active channel
         SD logging LED
         Supply voltage 7-24 Volts.
         Power 15ma @ 12V 200mW.
         No data alarm feature on channel 1, need to connect speaker
         Auto detect which channels have data


         NMEA Multiplexer with PC
             The unit will switch between the channels and combine
             the data to a single channel.

                                                    When logging to the SD              Lights will show which
               Battery                              Card this LED will flash.           Channel is being used.
               Don’t connect USB and

               GPS         +
               Depth        A+
               Differential A-
               Wind          +


   GPS repeater                                                                 SD card on bottom,
                  0V                                                            if there
                  +                                                             Unit will also log to
                                                      Speaker                   it.
                                                      If no data on
   Autopilot                                          channel 1 this
   Differential input                                 will output a
                  A+                                  2khz tone.

Boat electronic projects          page 5 of 10                                    24/04/2011
Example of operation as multiplexer.

      The unit has NMEA 0183 V2 data at 4800 baud on all four inputs

      1. Channel 1 checked for a quite period
      2. Now wait for data
      3. If no data for 5 seconds mark channel as inactive and switch to next
         channel, next time round this inactive channel will be missed unless
         there was data was seen
      4. Data on channel, route data to output channel.
      5. Wait for a quite period of no data (Channel finished transmitting)
      6. Switch to next active channel

      If the data rate is to high there will be no gaps in the data so the unit will stay
      locked to this channel.

      Example 1 .

      Channel 1 GPS update every 2 seconds
      Channel 2 Depth update every 2 seconds
      Channel 3 Wind update every 2 seconds
      Channel 4 compass update every 2 seconds

      Time 0 GPS update
      Time 2 Depth update
      Time 4 Wind update
      Time 6 compass update
      Time 8 GPS update

      In the case above where all channels have a slow update rate
      And all happen at the same time, you would only get a GPS update every
      8 seconds and this may be undesirable.

      A boat travelling at 10 knots with a GPS update of every 2 seconds would
      Have travelled 10.288 metres.

      But with a update of 8 seconds the boat would have travelled 41.152 metres

      Because of this the multiplex mode would not suit high speed craft as the
      GPS update would be to slow, at 50 knots between updates the distance
      Travelled would be 205 metres!.

Boat electronic projects          page 6 of 10                               24/04/2011
SD card logging

      When a SD card is inserted the unit will also log to the card as well as the
      USB port, this can be used as a backup device or just power the multiplexer
      of +12V and then no PC needed.


      1) Power on the logger from +12V or USB The Yellow Led will come on,
         After approx 10 seconds the Green Led will light and the yellow will stay
         On , this means the SD card

      2) Turn on NMEA devices and the green Led should switch between the
         Active channels and the yellow led will flash.

      3) When finished turn off NMEA devices and wait for yellow Led to
         To stop flashing, now remove power and unplug SD card.

      4) Plug SD card into reader and copy to file on the PC, don’t delete or modify
         The file on the SD or it will need to be re-formatted using the file maker
         Software on the CD supplied.

      5) Also the data can be uploaded by connecting the multiplexer to the USB
         Port and using the software NMEA upload this can be done.


          Don’t remove the SD card while power on this can cause file corruption!!
          Only power off the device when yellow Led is not flashing!!
          Don’t connect USB and Battery at the same time.

Boat electronic projects          page 7 of 10                         24/04/2011
Format SD card

      The SD card is pre-formatted with a log file and this should not be changed
      Only copied to the PC.

      To re-format a new card do the following steps

      1) Format to FAT16 using windows
      2) Run the File maker software , can take a while for 1Gb approx 20 mins.

      Also if you find the Yellow Led is going off when SD card is plugged in,
      Try to re-format the card this fix’s most problems.

Uploading logged data

      When the data is to be viewed on a PC there are two options

       1) Power down the device and un-plug the SD card which can be viewed
          With a SD reader, Don’t modify the logged file just copy to the PC.

       2) Connect multiplexer to the PC and use the upload software supplied
          On the CD to upload the data.

Boat electronic projects          page 8 of 10                         24/04/2011

      From top-to bottom of the unit

      1) +Battery 7-20V (Don’t connect USB & battery same time!!!)
      2) 0V
      3) CH1 A+(+Input for opto for channel 1)
      4) CH1 A- (-Input for opto for channel 2)
      5) CH2 A+
      6) CH2 A-
      7) CH3 A+
      8) CH3 A-
      9) CH4 A+
      10) CH4 A-
      11) Ground
      12) A+ Out(TTL out put max current 25ma) connect to autohelm ect
      13) A+ Out(TTL out put max current 25ma) connect to autohelm ect
      14) Ground
      15) A- Out (invert of A+ Max 25ma) for RS422 level can also connect to a PC
      16) Speaker connection(3khz 22ma)

       Note the maximum current for pins 12,13,16 is 25ma combined.


      1) Always turn off NMEA instruments then the SD logger, as removing power
         while writing to the SD card can cause file corruption.

      2) When using as multiplexer with the PCyou have to remove the SD card, as
         data Needs to go to the USB port and not the SD card.

      3) Never edit the file on the SD card, only copy the data.
          If file is changed the unit will not log to the SD card, and the card will
         Need to be formatted with some special software which can be


Parameter            Conditions             Min                     Max
Supply               7V – 20V               I=16ma/0.2W             I=30ma 0.36W

NMEA opto input      Logic 1                1.5v                    24v
                     Logic 0                0v                      0.5v
A+,A- output         Drive opto input       0                       2 devices
Alarm output         No GPS data            3khz tone               Max 25ma
USB connection       Upload and recieve     5V
SD card              SD card connector      ??                      1Gb

Boat electronic projects          page 9 of 10                             24/04/2011
Credits / Warning / Disclaimer

Only proceed with the installation if you are competent to do so,
Boat electronics will not accept any responsibility for injury or
Damage caused by , during or as a result of the installation of this
Any piece of the equipment can fail due to a number of causes. Do
Not install this equipment if it is the only source of information and
Its failure could result in injury or death. Instead return the equipment
for a full refund.
Remember this equipment is as aid to navigation and not a substitute
for proper seamanship. This instrument is used at your own risk,
Use it prudently and check its operation from time to time against
other data.
Inspect the installation from time to time and seek advice if any part
Thereof is not fully seaworthy.

Boat electronic projects          page 10 of 10                             24/04/2011

To top