Wind Board v3.0 – Peet Bros Wind Vane to NMEA 0183

for Wind V3.0  –  Updated 12-August-2018.  Previous manual: Wind V2.0

Please Note: This board has been retired and is no longer available for purchase. However the schematic, source code and everything you should need to build your own is below. (Moderate Arduino experience required).

Version 3.0 Changes:

  • RS422 driver integrated onto board as standard. No extra module required.
  • DIP switch bank added for configuration.
  • Blue!

Version 3.2 Changes:

  • Same as v3.0, but adds 4 outputs to drive a B&G Network Wind Display. See Section 9 for details.

1. Introduction

The wind board is designed to read signals from a Peet Bros Wind Vane Pro and output a NMEA 0183 data stream. Designed as a cheap wind interface for weather stations and boats. The board has the following choices for data output:

  • Plugging an USB FTDI cable on to the board. This is the best choice for computers and will also power the board by USB.
  • Plugged directly to a Raspberry Pi, with the board powered by the Raspberry Pi.
  • Connecting to the RS422 terminals (A and B). This allows the wind board to be a NMEA0183 v2+ talker for marine equipment. The board will require external power such as a 12V battery.
  • Version 3.2 only: outputs to drive B&G Network Wind Display. See Section 9 for details.

The board has been retired, but was previously available from tindie.com

The schematic is here.

The core Arduino code is here. Note: this is not the exact code used on the v3 board which has the extra config switches.

There are a few adjustments and tests required before use, see Section 6.

In normal operation the red light on the wind board will flash every second. If the board is started in test mode (Config 4 ON), the light will be off.

The board will only work with the Peet Bros Pro Wind Vane.

2. USB Connection

To use the board via USB and get data into systems like OpenPlotter or OpenCPN, I suggest you use a 5V FTDI cable. The wind board has a header that matches the pinout for most FTDI cables. See picture for connection example. The FTDI USB cable will even power the board, so you don’t need to supply power separately. Steps:

  • Plug in a Peet Bros Anemometer to the black RJ11 jack.
  • Connect the 5V FTDI cable to the header in the correction orientation (see picture).
  • Plug in the USB end of the cable to a computer or Raspberry Pi. The board should power up and start streaming wind data. You may need to install drivers for the FTDI cable.
  • Run through the procedure in Section 6.

3. RS422 Output (NMEA0183 v2+ Talker)

To use the board as a marine NMEA talker, simply connect a listening device to the A and B terminals. If a shielded cable is used, only connect the shield to ground at one end. Both the wind board and the listening device should have a common ground connection (on negative terminal).

  • Plug in a Peet Bros Anemometer to the black RJ11 jack.
  • Connect the A and B terminals to the listener.
  • Connect the + and – terminals to a 7 to 15 V power supply.
  • Run through the procedure in Section 6.

4. Raspberry Pi

3The board can also be plugged directly onto all models of Raspberry Pi. In this configuration the data is received by the Raspberry Pi’s built-in serial port. To do so you will need to:Raspberry_Pi_3_Model_B

  • Solder on the 10 pin header to the non-component side of the wind board.
  • Plug in a Peet Bros Anemometer to the black RJ11 jack.
  • Setup the Raspberry Pi to read the serial data.
  • Connect the board to the Raspberry Pi on the first 5×2 pins of the GPIO header as shown.
  • Run through the procedure in Section 6.

5. Jumpers & Switches

The board has four configuration switches and a RESET button. See the picture of board layout for positions.

Config 1 – Firmware after 10-March-2017: Set this switch ON to output VWR sentence. Set switch OFF to output MWV sentence (default). Please see here for sentence types.

Firmware before 10-March-17: MWV sentence only. Setting this switch ON will change the wind speed output to km/h. In the OFF position the output is in knots.

Config 2 – Setting this switch ON will change the serial baud rate to 57600. In the OFF position the baud rate is 4800 to match NMEA 0183 standard.

Config 3 – Reserved for future use, please set OFF.

Config 4 – If this switch is ON during a reset, the board will continuously output the direction filter and offset settings. This allows adjustment of these trimpot values (see 6. Initial Test and Adjustments). If this switch is set ON after the board has started, the board will output simulated data for testing. For normal operation the switch should be OFF.

6. Initial Test and Adjustments

Once the wind board is setup, you should follow this procedure to check there are no missing pulses from the wind vane. This section also describes how to adjust the direction offset and filter time.

  1. Connect the wind vane, turn the Config 4 switch ON, connect a serial terminal and power up the board.
  2. With the Config 4 switch on as the board powers up, the serial output will show the current filter time, direction offset and a count of missing direction signal pulses from the wind vane.
  3. Get a hair dyer to turn the wind vane cups, and vary the wind speed and angle over a minute.
  4. The number of missing pulses should be less than 10 over 60 seconds. If you have more, check that the direction part of the wind vane is pushed down properly so it’s just above the spinning cups. If you still have problems read the Direction Mod section below. Note: you will usually get one missing pulse detected when the zero degrees mark is crossed.
  5. The two blue trimpots can now be adjusted with a small screwdriver. These change the direction output’s offset (from -180 to +180 degrees) and the filter time (from 0.0 to 5.0 seconds).

The direction offset is straightforward and simply adds the offset value in degrees to the direction output. The board should come with the direction offset set to 0 (± 1 degrees).

The filtering on the direction output is a time based exponential smoothing function. A value of 5.0 s means it takes five seconds to show a change from the input signals to output (slow but smooth response). A value of 0.0 s means no filtering is performed, and the input equals the output (fast response). The board ships with the filter rate set to 1.0 (± 0.1).

7. Example Output

Wind v3-0 12-Jan-2017
Direction Filter | Direction Offset | Missing Pulses
      1.2 s               5                 0
$WIMWV,125.0,R,8.65,N,A*1E
$WIMWV,152.0,R,7.33,N,A*12
$WIMWV,157.0,R,6.24,N,A*10
$WIMWV,160.0,R,5.38,N,A*1A
$WIMWV,161.0,R,4.62,N,A*15
$WIMWV,162.0,R,4.22,N,A*12
$WIMWV,163.0,R,3.84,N,A*18
$WIMWV,161.0,R,3.55,N,A*16
$WIMWV,163.0,R,3.21,N,A*17
$WIMWV,162.0,R,2.92,N,A*1F
$WIMWV,163.0,R,2.63,N,A*10
$WIMWV,162.0,R,2.36,N,A*11
$WIMWV,161.0,R,2.10,N,A*16
$WIMWV,160.0,R,1.84,N,A*19
$WIMWV,158.0,R,1.62,N,A*1A
$WIMWV,158.0,R,0.00,N,A*1F
$WIMWV,157.0,R,0.00,N,A*10

8. Direction Mod

If you find there are missing pulses or the direction output from the board is jumping around a bit you can try this mod. First, remember the direction is passed through an exponential filter, which will smooth the direction output. Second, the direction output is not as accurate at very low speeds. As an benchmark I recorded my direction output with two different filter rates as shown in the graph. For each recording I held the direction vane steady at a fixed angle, and used a hairdryer to turn the cups at a steady 10 knots. Note the held angle was different for the two results, but the idea is to show how much the output varies.

direction2

If your direction is jumping around more than this,  there may be a problem with the pulses coming from the wind vane. I discovered when I first started this project that the direction reed switch required more shielding, as there were many direction pulses missing. If you have an oscilloscope this is easy to verify. The correct pulses going to the Arduino should look like the top traces in the picture below, the missing pulses can be seen in the bottom traces.

pulses

If some of the direction pulses are missing you can try the mod outlined below:

  1. Pull the direction vane part of the anemometer directly up and off the body. My Peet Bros unit came disassembled so this was easy to do.1
  2. Pull off the cup part of the anemometer and look for the piece of shielding metal. You will need to cut a similar piece of thin steel from a tin can. The dimensions are roughly 13 x 20 mm, and the piece needs have a matching curve. 2a
  3. Slide the new piece into place. You may want to glue it later if after testing.34
  4. Reassemble the wind vane and test. I strongly suggest that you use a glue or silicone to secure the top direction part of the vane to the body, otherwise it can blow off in very strong winds. Do not put glue near the bearings!

9. B&G Network Wind Display Output

Version 3.2 of the wind board is slightly larger and capable of driving a B&G Network Wind Display.

There are four outputs:

  • Pulse (Violet): Digital speed pulse output. 0 or 5V.
  • Red: Analog direction phase output. 0 to 5V
  • Green: Analog direction phase output. 0 to 5V
  • Blue: Analog direction phase output. 0 to 5V

Both the Wind Board and the B&G Display should have a common ground connection.

These four signals effectively simulate a B&G wind sensor and can be wired into the masthead plug on the back of a B&G Network Wind display. Please see this document for pinout.

Please see this blog post regarding my experiments with driving the display. I have been quite successful in getting this to work, but I can provide no guarantees it will work for you!

Advertisement