< 192016-11-20⋎21 >

farmOS (farmos.org) is a free open source, web-based farm management system, built on Drupal.Set by mstenta on 2016-07-29 at 15:37
05:38*farmBOT has joined
11:12*JustTB has joined
11:48*JustTB has quit (Quit: Leaving.)
13:10*falcon has joined
13:13*falcon has quit (Remote host closed the connection)
19:23*dahfors has joined
20:04*dahfors has quit (Ping timeout: 260 seconds)
20:51*dahfors has joined
21:19*dahfors has quit (Quit: Page closed)
21:32*dahfors has joined
21:54mstentadahfors: let's move the conversation over here ok?
21:56mstentaso yea... i wrote a python web app that installs on a raspberry pi for monitoring temperature and humidity with Adafruit sensors
21:56mstentagithub.com/mstenta/atmospi
21:56mstentait stores the data locally in a sqlite database
21:56mstentait doesn't push to farmOS yet, but I plan to do that in the future
21:57mstentain the meantime, i wrote a simple farmOS Sensor module for it that just shows the Atmospi dashboard as an iframe within farmOS
21:57mstentagithub.com/mstenta/farm_sensor_atmospi
21:57mstentabut ultimately, I think I will probably migrate all my sensors to use Open Pipe Kit instead, and just let them be passive observers that send the data to the farmOS Sensor module directly
21:58mstentarather than having separate web apps on each Pi
21:58mstentacollect it all in one place (farmOS) associated with the actual area it is in...
21:58mstentaand handle the graphing and other UI within farmOS itself
22:10dahforsthat makes a lot of sense
22:11dahforsI've been using MQTT with my sensors... run super simple code on cheap ESP8266 chips and send to a mosquito mqtt server running on the raspberry pi
22:12dahforsbeen playing with homeassistant home automation software for the user interface to that sensor info and for creating automations... I was thinking that forking homeassistant and creating "farm assistant" for farm sensors and automation might be a fun project
22:13dahforsdon't know if something like that could be tied into farmos... or replicated within it...
22:19mstentacool! i've never heard of mqtt - what is it?
22:19mstentayea, that could be a farmOS module!
22:21mstentawe did some proof-of-concepting at Dorn's farm this past summer for using farmOS to "trigger" things to happen when a sensor value crosses a threshold
22:21mstentai forget exactly where that left off... but the basic concept was:
22:22mstentaa simple sensor would push data to farmOS
22:22dahforsmqtt is a very lightweight open source messaging protocol
22:22mstentafarmOS would have some logic to flip a switch - in the form of an artificial sensor reading - and then there would be a raspberry pi that would be reading that switch periodically, and if it changed it would do something
22:23dahforscool
22:24dahforscheck out homeassistant as they may have code that could be repurposed for that functionality in farmos
22:24dahfors"MQTT provides a lightweight method of carrying out messaging using a publish/subscribe model."
22:24mstentaultimately i'd love to put together some kind of framework in farmOS for that - but for now it's easy enough to write a simple custom module that does specifically what you want
22:24mstentacool - i will
22:24dahforsI like it because it's SUPER easy (so easy I can do it) and super lightweight... takes almost no resources to run the server on a rasp pi 1 and the client can run on tiny microcontrollers
22:24mstentaok interesting...
22:25mstentaso it has a central server that other sensors communicate with?
22:25dahforscorrect
22:26mstentadoes the central server trigger events in the other devices too?
22:26dahforsbut that "central" server can be very decentralized
22:26mstentaoh?
22:26dahforsapparently a raspberry pi is capable of many 1,000s of MQTT client connections...
22:27dahforsHomeassistant (home automation software written, I believe, in Python) "listens" to the MQTT server.... it subscribes to certain "channels" and when it receives a message, it triggers state changes and Home Assistant takes care of all that
22:27mstentaoh ok awesome
22:28dahforshome assistant python scrips handle the if then statements... MQTT is just a VERY lightweight method of moving messages from pt a to pt b
22:28mstentaok
22:28mstentai'm going to have to look into MQTT and see if farmOS could use it somehow
22:29dahforsyeah. let me know if there's anything I can do to help with that.
22:29mstentahmm so i wonder... is MQTT similar in goal to Open Pipe Kit?
22:29dahforsthat's what I was wondering...
22:29dahforsjust opened up opk to check it out
22:29mstentaOPK is essentially a framework for setting up Pis that "pipe" data from one place to another
22:29dahforsI suspect it is similar... the thing I like about mqtt is that it seems to be becoming a standard in the IoT world...
22:29mstentaso basically you can tell it to "pull" from a sensor and "push" to a database
22:30dahforsand the fewer reinventions of the wheel... the better...
22:30mstentaie: "pull from a yoctopuce USB temperature sensor and push to farmOS"
22:30mstentainteresting
22:30mstentamaybe we could write a farmOS module that could accept data from an MQTT server
22:30mstentathat would allow MQTT to "push" to farmOS, right?
22:31mstentadoes it use it's own protocol, do you know? or is it HTTP or another standard?
22:32mstenta(i'm reading en.wikipedia.org/wiki/MQTT now... sounds like it has it's own)
22:32dahforswith opk... does the sensor have to be on the same piece of hardware as opk is running on? Can it run on tiny microcontrollers? As I see those as key to keeping sensor costs super low and making battery power usable... for instance, you can run an esp8266 for months on a few aa batteries with the right low energy states and waking periodically (once an hour to get sensor dddata and transmit to mqtt)
22:32dahforsmqtt uses its own protocol
22:32dahforsthe MQTT 3.1 protocol
22:33mstentaOPK essentially acts as a gateway between sensors and databases
22:33dahforsmqtt.org/
22:33mstentait is all based on simple bash scripts
22:33mstentaso if you can write a bash script that can "pull" data from a collection of tiny microcontrollers, then OPK can push them to a database
22:34dahforsWhat kinds of sensors? oh ok. that's what it looked like. So does that mean the smallest/cheapest sensor node is a raspberry pi? or can it run on arduinos?
22:34mstentano, you can have the raspberry pi with OPK separate from the sensor nodes themselves
22:34mstentathey just need some way of communicating with one another
22:34dahforsoh yeah.. forgot about another key feature of mqtt... it's extremely bandwidth efficient... the messages themselves are tiny
22:35mstenta(i'm not speaking from a lot of experience here... i haven't worked with it a lot... but i've been around others who were hacking on it so i picked up some of the concepts)
22:35dahforsgot it
22:35mstentaat Dorn's farm we were testing with Motinos
22:36mstentathe Motinos had the sensor attached to them
22:36mstentaand they were communiating with the Pi via Lorawan
22:36dahforswhat's a motino? didn't get anything in my google search just now
22:36mstentaoops i might have spelled it wrong... let me see...
22:37mstentamoteino*
22:37mstentai've never worked with arduino myself, so i can't really speak to any of those details or how they compare to other options
22:38mstentai guess moteino's are a low-power arduino clone
22:38dahforsoh cool. they look promising
22:38dahforsyeah.. exactly
22:38mstentathe guys i was hacking with were experimenting with soil sensors that could be deployed with small solar panels
22:38dahforsthe esp8266 chips do much the same thing
22:38mstentaok cool
22:38dahforscan be programmed with arduino, or several other things like python... and are wireless
22:38mstentai've heard of esp8266 (moslty on hackaday) - is that arduino also?
22:39dahforsand half the cost of the moteinos
22:39mstentaoh cool
22:39mstentavery cool
22:39dahforsyeah.. they are really revolutionary
22:39mstentaso i think the main reason they were using moteinos was because they wanted to use lorawan
22:39dahforsyou can buy the chip for $2 and embed it into any device to have a microcontroller with wireless and now they have one that also includes bluetooth for like $6
22:39mstentawhich from what i gather is a very low power, extremelly long distance wireless radio frequency protocol
22:40dahforsit is. lorawan is awesome. moteinos may be ideal for some use cases. I'm definitely going to check them otu
22:41mstentayea! pretty exciting for deployments that are too big for wifi
22:41mstentawe did a test where we walked around and i think we got 1km range on it
22:42dahforsnice. slap on a directional antenna and I bet you could get 10x that... based on some things I've heard about lorawan
22:42mstentaawesome :-)
22:43mstentaexciting stuff... i hope to see some more cool sensor stuff start making its way into farmOS in the near future
22:43mstentamy aim is to just keep it as general as possible, so it can support whatever needs to be built
22:44dahforsperfect
23:01dahforsHey, am I missing something? I can't find the actual open pipe kit code...
23:02mstentaso... i believe it is essentially just a collection of various "pull" and "push" "drivers"
23:02mstenta"drivers" == bash scripts
23:03mstentaand then you use the unix pipe to run them in a command line
23:03mstentaRJ made a tutorial video for pushing to farmOS... lemme find it
23:03mstentawww.youtube.com/watch?v=fCflGeOpTqk
23:04dahforsok thanks. That'll help
23:08mstentagotta run - time to fix some dinner
23:08mstentagreat talking to you!
23:08mstentamore soon i hope
23:09dahforsyou too!
23:09dahforsthanks
23:09dahforsttyl

< 192016-11-20⋏21 >