This container handles the windvane (wind direction) of the weather station. The wiring is described here. It is the most complex sensor in terms of wiring this it makes use of the MCP3008 analog to digital converter.
This container is using Python and the gpiozero library.
The wind direction is determined using a voltage divider. From the data sheet of the weather station:
The wind vane is the most complicated of the three sensors. It has eight switches, each connected to a different resistor. The vane’s magnet may close two switches at once, allowing up to 16 different positions to be indicated. An external resistor can be used to form a voltage divider, producing a voltage output that can be measured with an analog to digital converter.
The MCP3008 uses the SPI protocol. To enable the SPI overlay for the PI using Balena, "spi=on" must be specified as device tree (DT) parameter.