How can i do a condition using two uplink messages?

i want to do a condition with 2 uplink messages to get automatically one downlink msg .

two sensor of level to trigger a led.

what ttn integration could help me? node red?

I doubt there is some (cheap) third-party service that supports this out of the box, so you will need (someone) to write your own application code, on some server outside of TTN. Sure, that could use Node-RED, but anything else can be used too. There are even free services that offer both handling of incoming HTTP data (for the uplinks), SQL database storage, and invoking webhooks (to schedule the downlink), such as pipedream.

To get data into your own server use the MQTT Data API or the HTTP Integration.

However:

If this is about two subsequent sensor readings of a single device then I think you’d better have the device itself implement that logic. If the trigger level might change over time, then you can use downlinks to configure the threshold that the device uses.


Pipedream SQL stores data for 30 days, but may take up to a minute to persist data. Pipedream workflows also have a state that does not need any database at all. All great for proof of concepts, or maybe even production workflows once they offer paid plans with their paid plans.

1 Like

This really should not have been distinct from your siren question since it’s the same problem for which there’s reason to doubt if TTN is suitable

1 Like