0

What am I working on?

  1. I am currently working on a project that will in the future be connected to the cloud.
  2. I have a PLC that will be connected to the cloud. When the “process” starts, the PLC will continuously send data to some database.
  3. The data from the database should be then visible via website.
  4. Ideally after the process ended the data should be put into a PDF or some other printable file.

I have investigated the Googles firebase ecosystem and this is the “perfect” architecture if I understand it correctly:

enter image description here

  1. On the left would be my PLC communicating through MQTT to the Cloud IoT core service.
  2. From there the messages would get into the Cloud Firestore through Cloud Functions (by messages I mean the PLC config options and sensor data).
  3. The user would communicate with the devices via website that would be hosted on Firebase Hosting.
  4. And finally I could then save the PDF files to the Firebase Storage service.

At first, I found this all very exciting! I would have all my services under one roof, all at one place. The billing is not that bad either. But it would be a lot of work to setup everything properly.

My other architecture idea:

So I got to thinking that maybe I could communicate to the Firestore from the PLC directly through REST API calls … but then the Firestore REST API does not yet support listeners (only .GET and .POST methods). And if I were to fire up .GET request every second for a new data from Firestore database (for the user to change some PLC config) it would get pricy really fast. So this is not the way.

  1. Then I found out about Googles SpreadSheets. And it seems that it would solve all my problems.
  2. It can store unlimited amounts of data.
  3. The pricing is not depended on how many REST API calls I make to it. So even tho the Google Spreadsheets REST API doesn’t support listeners I can get around it with just calling the .GET method periodically.
  4. And I can communicate with the SpreadSheets even from my website.

With this solution I would get rid of 4 Googles services for just 1:

  1. I do not need the Google IoT core – PLC can communicate with the spreadsheets directly via REST API.
  2. I do not need FirestoreGoogle Spreadsheets can store data just fine.
  3. I do not need Firebase Functions – no need for pushing any data to database.
  4. I do not need Firebase Storage – I can save the files as Googles Spreadsheets and then print them out.

Question:

So now I am little bit confused. Because the first architecture (without the spreadsheets) was looking perfect. But I do not understand why I can replace all of it with googles spreadsheets for free!

  1. Did I overlooked something?
  2. Is there a hidden catch in using the Google SpreadSheets for IoT solutions?
  3. Is it normal to use Google SpreadSheets like that?
  4. What architecture would you suggest using? The first one with the whole Google Firebase ecosystem or the second one with only the SpreadSheets?

If you think this is the wrong stackexchange site to ask please be so kind and redirect me to the right one, thanks a lot!

1

Interesting approach. There are a few things that concern me here.

  1. you may hit API limits. See https://developers.google.com/sheets/api/limits

  2. I dont know if there's a limit on the number of versions. I wonder if each update makes a version ?

  3. Like you, I wonder if there are hidden costs to this, such as a per version cost.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.