I’m looking to set up a basic garden / horticultural system, with a standalone instance of home assistant on a pi3. it will feature multiple sensors - temp/humidity/moisture/pH - and the automation logic will fire relays/servos/motors, aswell as notifications.
It seems like an arduino mega will cover all my pin io, but I’m struggling to find the ‘ideal’ one-stop method of getting data in and out of HA. Arduino over usb direct into HA doesnt support PWM. Mysensors/firmata is predominantly for wireless.
Will arduino spitting data out to HA over serial to the gpio of the pi be the best solution (in terms of keeping all the coding in one place)?
Can i use this method to activate the servos & motors aswell?
@lolouk44 thanks for the input
I’d thought about mqtt, but i’m hoping to keep the pi offline. How would you make up the sensors? on an arduino with a LANshield or Wifishield or something similar?
Well provided you can connect to the PI (set it up as an hidden access point), then you can connect to the mosquitto broker or even HA’s built in broker, so no need to connect to the grid.
Stupid question though, do you really need an arduino type of board to connect your sensors to? What not connecting your sensors to the PI’s GPIO ports?
A BME280 would give barometric pressure, humidity, and temperature to get your started, a Xiaomi Mi Flora would give you soil readings over BT (temp, humidity, lux, conductivity) and I’m sure you could find a PH sensor that can be wired to the Pi. It would greatly simplify your setup…
All food for thought. You’re quite right in that I don’t need the arduino. My main HA setup uses lots of different brands/protocols/components, and there’s a lot to keep track of… I guess I’m hoping that a single platform will consolidate things somewhat. And allow for expansion if required. Plus the pi can only do one pwm device iirc.
I’ll definately put ‘direct-to-pi’ back on the drawing board.