Raspberry Pi Weather Station Board

This weather station board contains three sensors that measure temperature, relative humidity, and barometric pressure. It connects directly to the Raspberry Pi 26-pin expansion header and communicates via the I2C bus.

Device name: Weather Station Board Device type: sensor Connectors: 26-pin expansion header Measures: temperature, humidity, barometric pressure Connection class: I2C Vendor: web4robot

Device Discovery

  • To use this device, you will need to enable I2C support on your Raspberry Pi as described in the Weather Station Board manual. The I2C board address for this device is 0x4e. You can verify that the device is present by running the following command from a terminal:
  •  $ sudo i2cdetect -y 1
    0 1 2 3 4 5 6 7 8 9 a b c d e f
    00: -- -- -- -- -- -- -- -- -- -- -- -- --
    10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
    20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
    30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
    40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- 4e --
    50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
    60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
    70: -- -- -- -- -- -- -- --

Opening the Device

  • DeviceOpen["weatherstation"] opens the device for reading data.

Reading Data

  • DeviceRead[obj,"Temperature"] reads the current temperature from the device.
  • DeviceRead[obj,"Pressure"] reads the current barometric pressure from the device.
  • DeviceRead[obj,"Humidity"] reads the current relative humidity from the device.

Closing and Releasing Resources

Examples

Basic Examples  (1)

This opens the device:

In[1]:=
Click for copyable input

This reads the current temperature:

In[2]:=
Click for copyable input

This reads the current barometric pressure:

In[3]:=
Click for copyable input

This reads the current relative humidity:

In[4]:=
Click for copyable input

This closes the device:

In[5]:=
Click for copyable input