[Emanuele] is using Google Docs to log his temperature sensor data automatically (translated). We can see a few benefits gained by using this system. One is that you don’t have to visit the site of the logging hardware to harvest the data, another is that Google will automatically graph the data for you. Of course this means you need some way to connect your logger to the Internet, but we’ve seen buckets of different techniques for doing so. In this case, [Emanuele] is using PIC hardware that has a NIC on the board. But the technique could be used from a computer just as easily as from a microcontroller.
The meat and potatoes of the hack is sniffing out the HTTP header and syntax for writing to cells on a Google Docs (soon to be Google Drive) spreadsheet. After making a new spreadsheet and copying the URL and key from the address bar, he loads up the page using a header-viewer web service. With all the pertinent info in hand he crafts about a dozen lines of code to assemble the HTTP packet, and rolls the timestamp and temperature reading into it dynamically. See the system in action after the break.
15 thoughts on “Data Logging Directly To Google Docs (Google Drive)”
Why did he have to “sniff out the HTTP header”? When I worked with google spreadsheet (back when it was docs), I just used the published docs and called curl. https://developers.google.com/google-apps/spreadsheets/
what is the fun in reading the manual? :-) it feels more hacky to sniff the info yourself
Or you go to:
How to pre-populate forms via URL parameters
Who knows a method to fill a cell via URL with
a formula? The URL method above is text based so =B1+B2 will be send as text, not as a formula?
Change the spreadsheet with formula’s won’t work either google append the parameters to the worksheet.
I know of a teacher doing a similar thing with monitoring a greenhouse using Arduinos and Vernier sensors. https://sites.google.com/a/caldwellschools.com/the-hibriten-greenhouse-project/home/real-time-data-monitoring-test
There’s a teacher doing a similar thing for monitoring a greenhouse using Arduinos and Vernier sensors:
“Of course this means you need some way to connect your logger to the Internet, but we’ve seen buckets of different techniques for doing so.”
What are some of those ways? I think I’m googling wrong. :)
I’m looking for a straightforward way to collect thermocouple data to an online space like googledocs.
first of all technically,
this is interesting and a great accomplishment.
but personally, i feel this would be usless if logging anything that might/will coincide with internet being lost… like earthquakes(sisemic detection) poweroutages(voltage spike monitor) ect.
but PERFECT for a greenhouse or other non critical…
PS: i never have, and never will use googledocs,
or anyother cloud service whenever possible.
PPS: i feel bad for all those people ABOUT to be forced to use googledocs in order to participate in highschool (errors, hacking, loss/internet, ect)
PPPS: spyware is watching you(everyone),
and if its in/on a cloud…
some disgruntled student _might_ get you expelled
by modifying your project 5 mins b4 presentation…
EDIT: i know hotmail is cloud based, im talking about things that can and always have been done locally.
EDIT: … or they might just publish/sell your stuff 5 mins b4 presentation and when teacher checks if its copy&pasted from the internet… automatic expulsion and you’ll NEVER EVER get into a university.
Fear is our greatest weapon… and Surprise… Fear and Surprise are our two greatest weapons…
and Ruthless Efficiency… Fear, Surprise and Ruthless Efficiency are our three greatest wepaons !!..
another way of interfacing with Google docs would be Google app script ( https://developers.google.com/apps-script/) . you could also react to certain values (e.g. temperature Spikes) by sending out emails.
but sniffing http requests certainly raises the hack Level;-)
My experience, and others, have been that the google app script api’s are horrifically buggy and not at all reliable.
I’m trying to get a similar setup working for my beer fermentor. Right now I’m leaning towards Cosm (formerly Pachube). Does anyone have some experience with this site?
Currently I have a $25 Pogoplug running arch linux with an arduino attached that’s reading several dallas digital temp sensors.
Google has certainly changed the manner in which spreadsheets are update since this article was written. I’ve been trying to sniff this out for a week. I’m not a programmer, and I’m not well versed in any language except AutoLISP (learnt many years ago).
Has anyone played with this topic since Docs converted to Drive?
how it is using arduino and ethernetsheild..
Google needs TLS (HTTPS) based access now. Use this project for direct access: http://bit.ly/1SopEug
Please be kind and respectful to help make the comments section excellent. (Comment Policy)