I made a UDP sender able to send text messages and hex data to the local network from automations. Includes some tweaks for specific use cases like string interpolation to insert attributes from other devices. It is not a server or receiver.
While it is generic, it is made to facilitate local control of certain WiZ features not available through SmartThings integrations that require using their UDP protocol like dynamic colours, dim to warm mode or independent control of dual-zone lights. For instance, this routine activates the Deep dive dynamic colour in a couple lights ![]()
![]()
Installation and use 
- Install the driver from mocelet-shared channel at https://bestow-regional.api.smartthings.com/invite/Kr2zNDg0Wr2A
- In SmartThings app go to add new devices and Scan nearby so the UDP Sender device appears.
- To send UDP messages create automations with the device. Write the input in the Advanced input action or, from the advanced website, in the
runCommandsaction. SmartThings app has an arbitrary character limit for the input, for some long commands you may need to use the Rules API or AWA instead. - There is a generic
ip:port messageinput format and syntactic sugar to craft WiZ setPilot commands as well as other types of payloads you can find in the cheat sheet at the end.
Sending WiZ control commands 
Make sure your lights have static IPs! You can achieve that by setting static reservations in the DHCP configuration of your router.
You may be familiar with the WiZ UDP code generator that tells you the JSON text message to send. Well, you can use those codes from automations now.
For instance, to activate the Deep dive dynamic scene at 100% brightness in a WiZ bulb, this generic syntax will work:
192.168.1.44:38899 {"id":1,"method":"setPilot","params":{"sceneId":23,"speed":145,"dimming":100}}
Syntactic sugar for the setPilot command avoids boilerplate. This is equivalent, you only have to write the magic keyword, the IP and the value of the params attribute:
pilot 192.168.1.44 {"sceneId":23,"speed":145,"dimming":100}
Supports multiple addresses, comma separated, no spaces. They are sent as close in time as possible to avoid popcorn effect:
pilot 192.168.1.44,192.168.1.45,192.168.1.46 {"sceneId":23,"speed":145,"dimming":100}
There are two variations of the pilot keyword with automatic retransmission for added reliability, you can read more about them here.
Some more examples
Turn on: pilot 192.168.1.44 {"state":true}
Turn off: pilot 192.168.1.44 {"state":false}
Set 3000K 75% at once: pilot 192.168.1.44 {"temp":3000,"dimming":75}
Extra-low brightness orange-ish: pilot 192.168.1.44 {"r":1,"g":0,"b":0,"w":1,"c":0,"dimming": 1}
Activate the new Dim to Warm mode: pilot 192.168.1.44 {"sceneId":40}
Turn on zone 2 of dual-zone light: pilot 192.168.1.44 {"devices":2,"state":true}
WiZ protocol documentation
WiZ has no official documentation (well, partially) but you can find information by inspecting the source code of pywizlight, here is the list of dynamic scene ids and some info of dual-zone lamps. Comments at https://www.reddit.com/r/wiz/ are also useful, especially from user wiz-dude like the insights on the TV sync modes.
Syntax cheat sheet 
The UDP Sender is generic even if most examples in the thread are WiZ focused. Here is a concise feature list that should be more or less up to date, check the comments for more insights.
- Send a text to single address:
ip:port message - Send a text to multiple addresses:
ip:port,ip:port,ip:port message - Send a text to broadcast address:
bcast ip:port message - Send a WiZ setPilot command:
pilot ip params_attribute - Send a WiZ setPilot with automatic retransmission: see here.
- Insert in the input integer attributes from devices like dimming levels and on/off switches as true/false: see string interpolation.
- Send hex data:
hex ip:port hex_data - Send hex data to broadcast address:
bhex ip:port hex_data - Send a Wake On LAN packet:
wol broadcast_ip mac_address



