UDP Listener For Tasker icon

UDP Listener For Tasker

★★★★★
★★★★★
(0.00/5)

1.2Free3 years ago

Download UDP Listener For Tasker APK latest version Free for Android

Version 1.2
Update
Size 136.65 KB (139,934 bytes)
Developer David P. White
Category Apps, Tools
Package Name com.whitedavidp.udplistenerfortasker
OS 6.0 and up

UDP Listener For Tasker APPLICATION description

Receives UDP datagrams & fires Intent broadcasts so Tasker can respond
PLEASE SEE THE APP'S HELP FILE AS THERE IS INSUFFICIENT SPACE HERE TO DESCRIBE ALL THE DETAILS.

Note: Disable battery saving to remove notification on later Android.

In trying to do some home automation stuff with Tasker, I could not find a good way to get notified of UDP events sent to the device on which Tasker is running. HTTP and TCP events, yes. Sending UDP events, yes. But none listening for UDP. So I decided to build one & this is the result.

Receipt of UDP datagrams on monitored port(s) fires Intents with event data in the Intent's EXTRAs. Tasker & other automation mechanisms that know how to receive Intents can trigger your own actions when this occurs.

Usage

Upon start up, this app displays a list of ports being monitored for UDP activity. To start monitoring all the Active entries on the list you simply press the Start Server button. If all goes well, the monitoring will be underway. About the only thing that might go wrong is that the specified port number is already in use by some other app. You should see a message if this is the case.

Initially, of course, the list of ports being monitored is empty. From the app's menu, choose Add Port to Monitor and supply the necessary information. Note that port numbers MUST be > 1024. Each port can optionally:

* service multi-cast datagrams or not
* be enabled/disabled for monitoring
* have UDP data payloads converted into a string of hexadecimal digits before sending
* suppress duplicate datagrams to a port from the same IP within a timeout period
* append the port number to its Intent action strings

If the server is currently running at the time a new entry is added to the list, you must stop & re-start the server for monitoring of the entire list to begin anew.

Ports may be modified & deleted from the list with a long press of the entry you wish to change. As with additions, you must stop & re-start the server for monitoring of the entire list to begin anew.

For many situations, it is desirable for monitoring to begin when your device boots. This can be accomplished by checking Start Server At Boot on the app's menu. While this works fine on the vast majority of devices, you must be aware that some devices do not support this. You can start & stop the server by sending these Intents:

com.whitedavidp.udplistenerfortasker.START_SERVER
com.whitedavidp.udplistenerfortasker.STOP_SERVER

Datagram Receipt Processing

Once the server is running, it waits for UDP datagrams for be delivered on each of the specified, Active ports. When a datagram is received, it is processed into an Intent that is broadcast to the system so that Tasker or other automation apps can handle the Intent's reception & do whatever you want done. You will need to know the action name on the Intent and that is always at least:

com.whitedavidp.udplistenerfortasker.UdpBroadcast

but optionally, the port number can be appended to the above.

In each Intent, the app places named extra data strings for the following datagram metadata:

* time - the time at which the datagram was processed as expressed in the number of seconds since midnight of 1/1/1970
* port - the monitored port to which the datagram was sent
* sender - the IP address of the datagram's origination
* sender_port - the port of the datagram's origination

Finally, an extra data string is sent named message. This is the datagram's data payload. It you have specified that the receiving port should convert this into a string of hexadecimal digits, this will be completed before the Intent is broadcast. This is highly recommended if the payload is binary data or if you are not sure. This app performs no processing to ensure the data is valid and has not been corrupted in transmission. The data is simply extracted from the datagram using the offset & length specified in the packet.

Support

Please use the email address provided here to let me know how this works for you. I will try to resolve problems when I can.
↓ Read more
UDP Listener For Tasker screen 1 UDP Listener For Tasker screen 2 UDP Listener For Tasker screen 3 UDP Listener For Tasker screen 4 UDP Listener For Tasker screen 5