While Christ Church Morningside’s hall is being refurbished, their Centre has a very different use pattern from usual, and we want to make sure everyone is well served. It’s a modern building with a nice big sunny window, but autumn is coming! Here’s the graph for it. This is actually the first time we’ve fielded a pi with the version of the webserver that restarts automatically when the power is cut – the documentation and process all works well, but if you update elsewhere in the field, be sure to leave enough time to make the required updates to the existing software (largely, npm packages).
Let’s see, what all did we do? Cleared up the mystery wiring diagram for the LCD display and agreed how to deal with it, taught me how to spec a current-limiting resistor, got further on thinking about how do we make the cheapest, low-skill data logger design we can, and thought about how we proceed in the longer term. That’s a lot!
So, the other piece of equipment I’ve been exploring is the cheap 4 digit LCD display – I think the one we have is the same as the Sparkfun one, but we got it from Proto-Pic. We’ll know what colour it is when we turn it on but I think it’s green! It has a common anode and 7 separate digital pins for the segments needed to show a single digit, plus a pin to select which digit to use – and then separate digital pins for apostrophe and colon, where the apostrophe kind of doubles as a degree symbol for some people. Multiplexing, pins numbered clockwise from the bottom right. Sounds simple enough!
- Proto-pic information with data sheet and sample code
- Sparkfun source
I’ve been looking at the basics on the Trinket – I can’t say I’ve mastered it, but here are some quick notes for absolute beginners like me! There are better technical sources of information, but this addresses some of our questions about how to make the lowest cost data logger possible on my kind of skill level.
Yup, we’re on again tomorrow (7:30, Tuesday 23 August, City of Edinburgh Methodist) – still looking at the real time clock, Trinket, and LCD displays. I’m a little less far than I thought – somehow I got my libraries in a twist when I updated my Arduino IDE. This one bugs me about updating libraries, but it turns out the most up-to-date versions of the OneWire library are incompatible with our code, and we have to (at least for now) use the one in our own github. So that’s a hint we need to store somewhere, I think.
And I did tweet it, but don’t miss David Dorman’s highly entertaining video of our second go at the balloons in St Columba’s –
Real environments don’t always cooperate! We’re calling this one “Playful Spirits”.
Just a quick note to say that we’re on tonight as usual for second and fourth Tuesdays of the month – at 7:30, in the Methodist church basement, 25 Nicolson Square.
The last blog post will give you some idea of what’s going on. We’re still looking at the brilliances and limitations of microcontrollers, add-ons, and what we can do with them. Tonight assuming all goes well with buses, Festival-goers, and the like, it will be the Adafruit Trinket, a real-time clock, and time permitting, I’m tempted to introduce a “five minute technology of the week” slot.
As promised, I’m looking at cannibalizing the HeatHack code for the devices that radio sensor readings to a Pi so that we can build a stand-alone data logger, using an SPI-compatible SD card socket. That’s easy enough and going just fine, but when we were totting up prices and skills, we forgot the clock!
Yes, the clock – a real time clock that isn’t temperature dependent and is more accurate than the classic one based on a crystal, but you pay for it. It would be possible to have a data logger without one by asking the current time during configuration and leaving it free-running, but it will drift. I’d expect the drift to be similar to the internetless Pi base station we used in Selkirk, but that lost 20 minutes over a run of a few weeks, possibly because it was very cold in there at times. There are apparently some tricks to calibrate a free-running Arduino, at least to some degree, floating around on the internet – but I haven’t tried them. I see a test for drift coming on.
I thought I had a clock in the cupboard, but we don’t – that’s an order than went wrong in the end and had to be refunded. Maybe we want to test a clock, for the learning if nothing else, using a Jeenode. The basic choice seems to be a DS1302 or DS1307 for cheap – £2ish off ebay, £5ish for a reputable vendor to guarantee the accuracy is as good as the datasheet – or a DS1338 that’s more accurate and not temperature dependent, but costs more like a £5-7. The DS1307 and DS1338 use the I2C protocol whereas the DS1302 uses something a bit like SPI that isn’t. I’m thinking. If it’s for Tuesday, I’d better think fast. I’m not sure the cheap ones are better than the Arduino itself, apart from the clock is only doing the one thing, and will keep track of the time and date (which is useful – date processing can be a right pain). If any of them can be daisy chained with the SD card socket to get around the lack of pins on the Trinket, it’ll be the 1302 – but I think we might be short even for that.
Last night, we figured out how we could best build a stand-alone temperature and relative humidity logger, starting with a Jeenode and a very cheap SD card socket off the internet – and then what’s the easiest, cheapest starting project for new people coming to the project with a monitoring need. Continue reading last night’s learning
As a reminder, to brush up our skills we’re building a
stand-alone data logger using an Arduino, a sensor, and an SD card socket – and then the goal is to think about what’s the cheapest way of doing this within fairly easy skills – maybe the Adafruit Trinket, or are there other options?
Continue reading more details for tonight
… and continuing our look at the Arduino SD card writer, so we can build a stand-alone temperature and RH logger and then think about how cheap we can make the build. I’ve been very busy trying to paint decking while the weather been’s OK for it, but I will try the “Hello World” equivalent at home this afternoon so that I know whether we’re stuck on the wiring diagram for it or not, just to make sure we’re working with the right protocol, since the actual device we have is a bit underdocumented! As before, if you have a standard Arduino, bring it – saves us disconnecting the bike wheel. I’ll also see if I can source the right size socket so that we can attach it to a Jeenode, where the right pins aren’t in one of the four main ports.
19:30, CEMC Methodist, in the basement…