This is an example project tutorial how to use Pi-Cubes Universal Input Modules to monitor temperatures using the Raspberry Pi and Pi-Cubes products.
Using modular concept of the Pi-Cubes it is possible to monitor up to 24 Temperature Sensors.
Next Pi-Cubes components are used:
- Pi-Cubes Main Board
- Pi-Cubes UI4 Modules ( from one up to six modules)
Pi-Cubes Universal Input Modules supports 10K Type 2 NTC Sensors. They are simple resistive sensors that are connected directly to the Pi-Cubes Universal Input in the Resistive Mode.
Different type of temperature sensors supported by Pi-Cubes:
- Duct Sensors,
- Pipe Strap On Sensors,
- Pipe Immersion Sensors,
- Outdoor Sensors,
- Space Temperature Sensors.
There are some of temperature sensors suppliers:
Resistive type of sensors compatible with Pi-Cubes are "10K Type 2".
Sensors are supported by Pi-Cubes Node-RED SDK, please follow instruction to install our SDK on the Raspbian or download complete image from our web page.
1. Enable I2C on your Raspberry Pi following our blog instructions :
https://www.cube-controls.com/blog/how-to-enable-i2c-on-raspberry-pi
2. Install Node.js :
curl -sL https://deb.nodesource.com/setup_0.12 | sudo bash –sudo apt-get install -y build-essential python-dev python-rpi.gpio nodejs
Check Node.js version :
node -v
It should be at least v.0.12.7
3. Install Node-RED:
sudo npm install -g –unsafe-perm node-red
Start Node-RED to test it:
node-red-pi –max-old-space-size=128
Press Ctrl+C to cancel Node-RED.
Check Node-RED web documentations for more detailed instructions:
http://nodered.org/docs/hardware/raspberrypi.html
4. Install Pi-Cubes Node-RED SDK
Go to node-red local folder, under /home/pi folder:
cd ~/.node-red
Use npm to install Pi-Cubes SDK.
npm install node-red-picubes
5. Follow up instructions how to enable Node-RED to start automatically on the boot up:
http://nodered.org/docs/getting-started/running.html#starting-node-red-on-boot
Reboot Raspberry Pi
sudo reboot
6. Access Node-RED and setup ReadUI Nodes
Node-RED should be running and accessible on http://{the-raspberry-ip-address}:1880/
To read temperature there is readUI Node in the Node-RED Pi-Cubes folder.
Use configuration screen to configure parameters.
Comments