All Projects โ†’ hobbyquaker โ†’ rpi2mqtt

hobbyquaker / rpi2mqtt

Licence: MIT license
Connect RaspberryPi GPIOs and 1-Wire temperature sensors to MQTT ๐Ÿฐ๐Ÿ”˜๐Ÿ“ก

Programming Languages

javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to rpi2mqtt

Ct Smart Home
A ready-to-use Node-RED setup for home automation
Stars: โœญ 132 (+560%)
Mutual labels:  mqtt, smarthome, raspberrypi
Awesome Mqtt
A curated list of MQTT related stuff. โœจ
Stars: โœญ 1,667 (+8235%)
Mutual labels:  mqtt, smarthome
Smarthome
Device integration platform for your smart home
Stars: โœญ 92 (+360%)
Mutual labels:  mqtt, smarthome
ccu-addon-mosquitto
Mosquitto packaged as Addon for the Homematic CCU3 and RaspberryMatic
Stars: โœญ 23 (+15%)
Mutual labels:  mqtt, smarthome
Hodd
Homie Device Discovery
Stars: โœญ 21 (+5%)
Mutual labels:  mqtt, smarthome
Luamqtt
luamqtt - Pure-lua MQTT v3.1.1 and v5.0 client
Stars: โœญ 58 (+190%)
Mutual labels:  mqtt, smarthome
Gbridge
gBridge.io allows you to control (almost) anything with Google Assistant, by translating voice commands to MQTT messages.
Stars: โœญ 152 (+660%)
Mutual labels:  mqtt, smarthome
Zigbee2mqttassistant
GUI for Zigbee2Mqtt running in docker and HASS.IO
Stars: โœญ 371 (+1755%)
Mutual labels:  mqtt, smarthome
Basecamp
An Arduino library to ease the use of the ESP32 in IoT projects
Stars: โœญ 251 (+1155%)
Mutual labels:  mqtt, smarthome
pihut-xmas-asyncio
Demonstration driving The Pi Hut Raspberry Pi 3D Xmas tree using Python Asyncio
Stars: โœญ 15 (-25%)
Mutual labels:  gpio, raspberrypi
SmartMirror
Raspberrry Pi powered smart mirror inspired by HackerHouseYT Smart Mirror project
Stars: โœญ 16 (-20%)
Mutual labels:  smarthome, raspberrypi
Haswitchplate
LCD touchscreen for Home Automation
Stars: โœญ 666 (+3230%)
Mutual labels:  mqtt, smarthome
Redmatic
Node-RED packaged as Addon for the Homematic CCU3 and RaspberryMatic ๐Ÿคนโ€โ™‚๏ธ
Stars: โœญ 407 (+1935%)
Mutual labels:  mqtt, smarthome
Pysmartnode
Micropython Smarthome framework
Stars: โœญ 58 (+190%)
Mutual labels:  mqtt, smarthome
Homepoint
Espressif ESP32 Based Smarthome screen for MQTT
Stars: โœญ 391 (+1855%)
Mutual labels:  mqtt, smarthome
gpio
A RaspberryPi GPIO library written in PHP.
Stars: โœญ 16 (-20%)
Mutual labels:  gpio, raspberrypi
Freedomotic
Open IoT Framework
Stars: โœญ 354 (+1670%)
Mutual labels:  mqtt, raspberrypi
Mqtt Smarthome
Smart home automation with MQTT as the central message bus - Architectural proposal
Stars: โœญ 356 (+1680%)
Mutual labels:  mqtt, smarthome
Mqtt Io
Expose GPIO modules (Raspberry Pi, Beaglebone, PCF8754, PiFace2 etc.) and digital sensors (LM75 etc.) to an MQTT server for remote control and monitoring.
Stars: โœญ 234 (+1070%)
Mutual labels:  mqtt, gpio
52-Weeks-of-Pi
Inspired by Shekhar Gulati's "52 technologies in 2016", I've decided to set a goal of 52 Pi ideas over the next year.
Stars: โœญ 54 (+170%)
Mutual labels:  gpio, raspberrypi

rpi2mqtt

mqtt-smarthome NPM version Dependency Status Build Status XO code style License

Connect RaspberryPi GPIOs and 1-Wire temperature sensors to MQTT ๐Ÿฐ๐Ÿ”˜๐Ÿ“ก

Install

Prerequisite: Node.js version 6.0 or above. I suggest to use https://github.com/tj/n to install a recent version of Node.js.

Install rpi2mqtt: $ sudo npm install -g rpi2mqtt

To run rpi2mqtt in background and start on system boot I suggest to use PM2.

Usage

Usage: rpi2mqtt [options]

Options:
  -c, --config         use config file                                                          [default: "~/.pi2mqtt/config.json"]
  -l, --log            log to file                                                              [default: "~/.pi2mqtt/daemon.log"]
  -v, --verbosity      possible values: "error", "info", "debug"                                [default: "error"]
  -a, --alias          alias topics. can be used multiple times. See examples                 
  -i, --in, --input    use gpio as input. can be used multiple times. See examples            
  -o, --out, --output  use gpio as output. can be used multiple times. See examples           
  -p, --payload        type of the mqtt payload. possible values are "plain" and "json"         [default: "plain"]
  -r, --retain         publish with retain flag                                               
  -t, --status-topic   topic prefix for status messages                                         [default: "hostname/status/"]
  -z, --set-topic      topic prefix for set messages                                            [default: "hostname/set/"]
  -x, --testament      topic for connect and last will message                                  [default: "connected"]
  -u, --url            broker url. See https://github.com/mqttjs/MQTT.js#connect-using-a-url    [default: "mqtt://127.0.0.1"]
  -s, --w1-wait        seconds to wait before reading /sys/bus/w1/devices/                      [default: 30]
  -n, --w1-interval    polling interval for 1-wire temperature sensors in seconds               [default: 30]
  -w, --w1-disable     disable 1-wire                                                         
  -h, --help           show help                                                              
  --version            Show version number     
  
  Examples:
    index.js -w -i 17 -i 18 -o 23             Disable 1-Wire, use GPIO17/18 as
                                              inputs and GPIO23 as output
    index.js -t -o 17 -a                      Use 1-wire and GPIO17 as output. Set
    w1/28-0000002981762:Temperature/Garden    mqtt topic aliases and remove topic
    -a gpio/17:Light/Garden                   prefix
                        

MQTT Topics

Default prefix is the hostname. You can disable the topic prefix with empty option --topic

1-Wire Temperature Sensors (DS1820)

<prefix>/status/w1/<1-wire-serial>

By default status topic is <hostname>/status, this can be changed through the command-line option --status-topic.

Example: raspberry/status/w1/28-000005908b0e

GPIO Input

<status-topic>/gpio/<gpio-number>

Example: raspberry/status/gpio/17

GPIO Output

<set-topic>/gpio/<gpio-number>

By default the set topic is <hostname>/set, this can be changed through the command-line option --set-topic.

Example: raspberry/set/gpio/23

The payload can be a plain number (0, 1) or the strings false and true.

Aliases

You can set individual topics with the --alias option.
Example: rpi2mqtt -a w1/28-000005908b0e:Temperature/Garden

If you want to use spaces in the topic use quotes around the whole -a option, like e.g. -a "w1/28-0000012345:Temperature Garden".

Mind that aliases don't affect the configured prefix. So rpi2mqtt -o 17 -a gpio/17:Light/Garden -t Raspberry5 would result in topic Raspberry5/Light/Garden for GPIO 17.

Ideas/Todo

License

MIT Copyright (c) Sebastian Raff

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].