Difference between revisions of "Hardware: Sensor Wiring"

From HiveTool
Jump to: navigation, search
(Rain Gauge)
(Rain Gauge)
Line 213: Line 213:
 
A "Tipping Bucket" type rain gauge is used.  It works by counting the number of times the bucket tips.  The Rainwise bucket available in the US dumps every one hundredth (1/100 or .01) inches of rain.
 
A "Tipping Bucket" type rain gauge is used.  It works by counting the number of times the bucket tips.  The Rainwise bucket available in the US dumps every one hundredth (1/100 or .01) inches of rain.
  
Only the Red (input with pull up resister) and Yellow (ground) wires are used.  Each time the input is momentarily shorted to ground, the pulse is counted.
+
Only the Red (input) and Yellow (ground) wires are used.  Each time the input is momentarily shorted to ground, the pulse is counted.
  
Pin 22 on J8, GPIO 6 (wiringPi) or 25 (PIGPIO), is used as a digital input. To prevent false triggers and help debounce the switch, it is filtered by a 1K series resister and a 0.1 bypass capacitor located on the hive interface board.
+
Pin 22 on J8, GPIO 6 (wiringPi) or 25 (PIGPIO), is programed as a digital input with a pull up resistor. To prevent false triggers and help debounce the switch, it is filtered by a 1K series resister and a 0.1 bypass capacitor located on the hive interface board.
  
 
{| class="wikitable"
 
{| class="wikitable"

Revision as of 01:51, 18 June 2017

The Raspberry Pi Hive Interface Board uses modular telephone RJ14 (6P4C) connectors for the sensors. Pins 2, 3, 4, and 5 are used.

Eventually, the load cells will be supplied with the connector attached. Cables will be provided for the other sensors.

These instructions are for developers that use the Raspberry Pi Hive Interface board versions 0.1 - 0.3.

The Registered Jack (RJ) series connectors install using an inexpensive crimping tool.

RJ Connectors

Crimp on Registered Jack (RJ) plugs are insulation displacement connectors (IDC) that pierce the insulation on the wire, forming a gas tight joint. Some RJ connectors are designed to take round cable, some flat, some both. Some are designed for solid wire, some for stranded, some for both.

The male connectors are called plugs. The female connectors are called jacks. They are designated by the number of positions (P) and the number of contacts (C) that are populated. We are currently using 6P4C (six position, four contact) plugs and jacks.

For a detail description, see Registered Jack on Wikipedia.

Number of Contacts

Contact numbering

Load Cells

Loadcell connector 1.jpg
Loadcell connector 2.jpg
Loadcell connector 3.jpg
Load Cell Wiring
RJ14 Pin Color HX711 Description
2 Red OUT+ Excitation voltage from HX711 voltage regulator
3 White A- A/D channel A negative input
4 Green A+ A/D channel A positive input
5 Black GND Analog ground
  1. Remove any heat shrink from the load cell cable.
  2. Cut off the drain wire.
  3. Spread out the four wires and arrange them in Red, White, Green, Black order.
  4. Gently flatten the cable with a pair of pliers.
  5. Evenly trim the wires so they extend approximately 1/4 inch past the jacket.
  6. Orient the RJ14 connector so the latch tab is up.
  7. Insert the wires all the way into the RJ14 connector, making sure that the wires are in the right order.
  8. Inspect the wires and connector with a magnifier. Make sure the outer jacket is past the strain relief and each wire is all the way to the end of the connector.
  9. If the wires do not extend the full length of the connector, or the jacket does not go past the strain relief, remove the wire and trim a little of the jacket, or shorten the wires.
  10. Crimp the connector.


DHT22/AM2302 Temperature and Humidity Sensor

Bare Sensor

Wiring DHT22 Temp-Humidity Sensor.jpg
Dht22 wiring2.jpg
DHT22 Wiring
RJ14 Pin Color DHT22 Signal Description
2 Black + +3.3VDC supply
3 Red Out Pi GPIO
4 Green No Connect Not used
5 Yellow - Digital ground

Wire type is standard four conductor flat telephone wire.

Jacket color is not important, recommend light color, avoid black.

Telephone wire colors are Black, Red, Green (not used), Yellow.

Crimp the RJ14 connector for normal telephone use.
Consider cutting a 10 or 12' cord in half for two sensors, crimping will be unnecessary


Trouble shooting: Make sure the cable is crimped Black, Red, Green, Yellow and not Yellow, Green, Red, Black.


Wired Sensor

Wired DHT22 WARNING wire color code is different. Red: +5, Black: Ground, Yellow: Signal

The wired sensor is larger and more expensive. It will not fit inside the hive (between the supers) as well as the bare DHT22 sensors.

Wire phone cable Black to DHT22 Red.
Wire phone cable Red to DHT22 Yellow.
Wire phone cable Yellow to DHT22 Black.


Wired DHT22 Wiring
RJ14 Pin Color DHT22 Signal DHT22 Color Description
2 Black + Red +3.3VDC supply
3 Red Out Yellow Pi GPIO
4 Green No Connect Not used
5 Yellow - Black Digital ground


TSL2591 Lux Sensor

Wiring TSL2591 Lux.jpg
Dht22 wiring2.jpg
TSL2591 Lux Sensor Deployed.jpg
TSL2591 Wiring
RJ14 Pin Color TSL2591 Signal Description
2 Black Vin +3.3Volt input
3 Red SDA Pi GPIO 8 I2C SDA
4 Green SCL Pi GPIO 9 I2C SCL
5 Yellow GND Digital ground

TSL 2591: 3Vo - not used, Int - not used.
Wire type is standard four conductor flat telephone wire.
Jacket color is not important, recommend light color, avoid black
Wire colors are Black, Red, Green, Yellow.
Crimp the RJ14 connector for normal telephone use.
Consider cutting a 10 or 12' cord in half for two sensors, crimping will be unnecessary


TIP A ping pong ball cut in half makes a weather shield and lens when attached to a flat base using glue.
A small pouch of desiccant attached inside will reduce moisture condensation.
Attach the sensor on top of the hive cover.



Rain Gauge

A "Tipping Bucket" type rain gauge is used. It works by counting the number of times the bucket tips. The Rainwise bucket available in the US dumps every one hundredth (1/100 or .01) inches of rain.

Only the Red (input) and Yellow (ground) wires are used. Each time the input is momentarily shorted to ground, the pulse is counted.

Pin 22 on J8, GPIO 6 (wiringPi) or 25 (PIGPIO), is programed as a digital input with a pull up resistor. To prevent false triggers and help debounce the switch, it is filtered by a 1K series resister and a 0.1 bypass capacitor located on the hive interface board.

TSL2591 Wiring
RJ14 Pin Color TSL2591 Signal Description
2 Black Not used DNC +3.3Volt
3 Red Rain Gauge Input Pi GPIO 6 (wiringPi) or 25 (PIGPIO) Pin 22 on J8
4 Green Not used DNC Pi GPIO ?
5 Yellow GND Digital ground