Digital inputs are available on the SensorData and SensorNode. These can be used to monitor the state of external devices or switches, or to count pulses - from a rain gauge, for example. The inputs have a maximum input of 48V, and anything about 2.5V or above is considered 'on'.
SensorData LoRaWAN: 2 x DI available. On the initial PCB revision, only input 1 can be used as a pulse counter or alarm source. This will be changed in future revisions.
SensorData Sigfox: 3 x DI available, 2 can be used for low-power pulse counting
SensorNode LoRaWAN: 2 x DI available. On the initial PCB revision, only input 1 can be used as a pulse counter or alarm source. This will be changed in future revisions.
Input changes are always being counted on the inputs, and the count can be added to a schedule to be transmitted. Care must be taken with using the count values, as they are transmitted as 16 bit integers, which, depending on use case, may overflow. Readings should be compared to previous ones to detect when an overflow has occurred. Counts are stored through device resets (periodic LoRaWAN rejoins or when programming parameters with the configuration app), but the values will reset when power is removed. This should also be considered when writing software to use the count values; the reset payload can be used to detect when this has occurred.
An alarm message can be sent, if set up, when an input changes to a certain value. Care must be taken with the parameters to ensure that alarms can't be generated too frequently for the LoRaWAN network in use.
Applies to all inputs
Alarm Rate Limit (s)
The minimum time between alarm transmissions. If an alarm occurs before this time has passed (from a previous alarm), it will be ignored. Default is 600s (10 minutes).
Per Input Parameters
Each input can be configured separately.
See explanation here. By default this is set to pull down. Note: Using a pull up on inputs slightly increases the sleep current of the device, which will affect the battery life.
Alarm On High/Low:
Enabling either of these will send an alarm message when the condition is met, ie, Alarm on high enabled = sending message when the input turns on. Default is disabled for both.
Sets if the input count is incremented when the input turns on, or off. Default is high (count when input turns on).
Debounce Period (ms):
The input has to change for this amount of time for the change to be detected. Default value is 1000 ms (1 second).
The debounce period determines the rate at which the pulse changes are recognized. The minimum practical debounce period is about 50ms.