Templates vs generic note.add request

So i’m setting up my hardware prototypes and i have a few questions on best practices.

My host MCU wakes up every 2 hours, measures a value, sends that value to notecard, and then goes back to sleep. Once a day i want that notecard to send all the values measured in the last 24 hours.

I’m getting my sensor values in notehub and it appears that its automatically bundling it since they all share the same “uploaded” time with different “capture” times.

Questions…

  1. Am i missing out on anything by not using templates and just using the generic note.add to data file request?

  2. For routes does it send 1 route for each capture or 1 route on each upload?

  3. If it sends 1 route per each CAPTURE is there a way to bundle it to be more economical on my route usage?

Thank you.

Hi @abari,

  1. Am i missing out on anything by not using templates and just using the generic note.add to data file request?

In this scenario, not likely, but it may be worth testing. When using templated Notefiles, you’ll likely consume less cellular data (though depending on the payload that may or may not be significant). I’d recommend reading Working with Note Templates to see if they may be right for your project.

  1. For routes does it send 1 route for each capture or 1 route on each upload?

Each event is routed separately (per each capture).

  1. If it sends 1 route per each CAPTURE is there a way to bundle it to be more economical on my route usage?

Yes, I suppose you could create a list/array of events and save those in the body as a single Note when you’re ready to save to the Notecard and sync with Notehub. You’d then have to unpack the list on the backend.

Great thanks again Rob.

My data usage is pretty minimal (other than day 1 when i updated the firmware), so i’m not too concerned with running out. That makes sense thank you for the explanation.