News for hackers. Stuff that matters.
Re:Ask HN: Share Your Raspberry Pi Project by tsyd on Wednesday July 26, 2017 @11:06AM (#14856770)
Although not strictly a Raspberry Pi project, I have a couple C.H.I.P. boards[1] scattered throughout my apartment collecting temperature and humidity readings (using a HIH8120 sensor[2]) and feeding it to my Raspberry Pi which runs InfluxDB and Chronograf[3] to store and display a simple dashboard. The end result looks like this: http://i.imgur.com/cIrhSUq.png

[1]: https://getchip.com/

[2]: https://sensing.honeywell.com/HIH8120-021-001S-humidity-sens...

[3]: https://www.influxdata.com/time-series-platform/chronograf/

Re:Ask HN: Share Your Raspberry Pi Project by kzisme on Wednesday July 26, 2017 @01:05PM (#14858031)
What language did you end up using to access the sensors?

I've been ~hoping~ to use Go to access the GPIO pins, but haven't had much success - any suggestions?

Re:Ask HN: Share Your Raspberry Pi Project by abright on Wednesday July 26, 2017 @03:50PM (#14859593)
I've used https://github.com/stianeikeland/go-rpio to control my garage doors and this library https://github.com/kidoman/embd has some more advanced features which I've used for a thermostat solution.
Re:Ask HN: Share Your Raspberry Pi Project by kzisme on Wednesday July 26, 2017 @10:37PM (#14862262)
Thanks! I'll take a look! I have an AstroHat on my Pi and I think it should be straight forward-ish using one of these.
Re:Ask HN: Share Your Raspberry Pi Project by danesparza on Monday July 31, 2017 @08:22AM (#14891240)
+1 for embd. I've used it with great success.
Re:Ask HN: Share Your Raspberry Pi Project by secure on Wednesday July 26, 2017 @03:43PM (#14859512)
Check out https://periph.io/, which makes GPIO access easy :)
Re:Ask HN: Share Your Raspberry Pi Project by kzisme on Wednesday July 26, 2017 @04:15PM (#14859842)
Thanks for the suggestion! Any affiliation :) ?
Re:Ask HN: Share Your Raspberry Pi Project by stadeschuldt on Wednesday July 26, 2017 @05:58PM (#14860747)
Re:Ask HN: Share Your Raspberry Pi Project by Griever on Wednesday July 26, 2017 @11:10AM (#14856825)
This is really cool! I've been thinking about a similar idea lately and this seems like a great way of doing it. Do you by chance have any material on how you got the honeywell sensor working with the C.H.I.P. board? (This would be my first electronics project)
Re:Ask HN: Share Your Raspberry Pi Project by tsyd on Wednesday July 26, 2017 @11:28AM (#14857025)
This was my first electronics project as well and I chose the Honeywell sensor because it has decent humidity accuracy (which is what I was mostly interested in) and a bonus temperature sensor built in. It uses the I2C protocol for communication which I found pleasant to work with although it would probably be simpler to just use am analog voltage sensor.

Here's the program I wrote to read the sensor over I2C: https://gist.github.com/tsyd/f48e933a21fb40b9f9eea28118f54e0...

Re:Ask HN: Share Your Raspberry Pi Project by Griever on Wednesday July 26, 2017 @11:51AM (#14857251)
I'll most certainly be checking this out in the near future. Thanks!
Re:Ask HN: Share Your Raspberry Pi Project by The_Sponge on Wednesday July 26, 2017 @04:27PM (#14859973)
I'm currently prototyping an alternate approach - using an nrf52 to send readings beacons, and then gathering those beacons with a raspberry pi

This has the added benefits of being able to be powered with a solar panel.

Re:Ask HN: Share Your Raspberry Pi Project by arcaster on Wednesday July 26, 2017 @09:18PM (#14861892)
I love the C.H.I.P board, seems like they'd have better market penetration if their name wasn't "CHIP" though. I feel like the Particle IOT line has suffered a similarly hindrence?
Re:Ask HN: Share Your Raspberry Pi Project by yeswecatan on Wednesday July 26, 2017 @03:57PM (#14859671)
I'm planning on doing pretty much the same thing. A couple of questions:

1. Why not just run InfluxDB and Chronograf on one of the CHIPs?

2. How are you sending data to the Pi?

Re:Ask HN: Share Your Raspberry Pi Project by tsyd on Thursday July 27, 2017 @08:20AM (#14864559)
> Why not just run InfluxDB and Chronograf on one of the CHIPs?

I started off with a single C.H.I.P. and ran everything on it but then when I added a second C.H.I.P. I wanted to have all the data in a central location. I also found Chronograf lag a lot when trying to browse more than a couple day's worth of data. The Raspberry Pi has much faster storage and CPU.

> How are you sending data to the Pi?

The C.H.I.P. has a Python script that runs on a cron that calls a C program to read the sensor and then sends it to the Pi using InfluxDB's HTTP API.

Re:Ask HN: Share Your Raspberry Pi Project by karangoeluw on Wednesday July 26, 2017 @11:09AM (#14856808)
Interesting... But what do you do with this data?
Re:Ask HN: Share Your Raspberry Pi Project by stevekemp on Friday July 28, 2017 @03:50AM (#14872690)
I'm the same, I use some cheap ESP8266 devices which have a temperature/humidity sensor attached. They submit their measurements every minute to a central MQ installation:

https://steve.fi/Hardware/d1-temperature-humidity/

While I don't have any particular reason for collecting the data it can be fun to look at. For example you can easily spot when somebody has a shower because the humidity spikes in the bathroom:

https://twitter.com/Stolen_Souls/status/848444075296641025

Naively I expected to track the weather, because I figure on a hot day the temperature of my living-room/etc would spike. Turns out this house is pretty well insulated so the internal temperature has essentially no relationship to the external one. I guess that makes sense in a country where you might have -25'C in the winters.

Re:Ask HN: Share Your Raspberry Pi Project by tsyd on Wednesday July 26, 2017 @11:40AM (#14857155)
Nothing in particular. I just wanted a way to view the temperature and humidity in my apartment when I'm out. Also I wanted to know what affects the humidity in my apartment and by how much (for example, you can see when I take my morning shower). In the future I may use the data to control a humidifier to turn it on whenever the humidity drops below a certain level.
Re:Ask HN: Share Your Raspberry Pi Project by stevekemp on Friday July 28, 2017 @03:51AM (#14872694)
Funny you mention humidity & showers. This is what I see when I take one:

https://twitter.com/Stolen_Souls/status/848444075296641025