当前位置:网站首页>Using tcp/udp tools to debug the yeelight ribbon
Using tcp/udp tools to debug the yeelight ribbon
2022-06-25 00:26:00 【a10615】
Use TCP/UDP Tool debugging Yeelight Lamp with
This article describes how to Windows Next , Use TCP/UDP Tool debugging Yeelight Lamp with
preparation
TCP/UDP Debugging tools
Yeelight WiFi Light Inter-Operation Specification
One 、 Search device
Search device , By sending multicast search commands to the LAN , The device will respond after receiving , Return the current status information of the device
1、 establish UDP Multicast connection
According to the document search command
M-SEARCH * HTTP/1.1
HOST: 239.255.255.250:1982
MAN: “ssdp:discover”
ST: wifi_bulb
- type : choose UDP Multicast
- The goal is IP: Keep multicast identity IP Group 239.255.255.250
- port :1982
- Local port :1982( The device response is this port , Can't change )

2、 Send multicast search command
After creating the connection , Copy the search command to the sending area ( Line break , use Ctrl+Enter)
then “ send out ”, Wait for device response
3、 Device response
After sending , If a device is online , Generally, the response can be received immediately . The receiving area is the response of the device 
Two 、 Equipment online notification
If the equipment is equipped with network , When accessing the network, the online notification will be sent through multicast . It's the same as searching , Create the same connection , Wait for the device to go online .
In receiving area , Can receive the notification after the equipment goes online ( When the same device goes online , Maybe several times , I have received 3 Time . Different from the search response , See documentation )
3、 ... and 、 Control equipment
1、 establish TCP Connect
Based on search or online notification ip、port Information , establish tcp Connect 
2、 dispatch orders
Input command in the sending area ( The command ends with a new line <Ctrl + Enter>)
Such as : Switch the switch state of the equipment
{
"id":1,"method":"toggle","params":[]}

3、 Device response
After the device receives the command , Will respond to the operation results of the command , If the operation is successful , Notification messages are also sent
# Operating results
{
"id":1, "result":["ok"]}
# Notice information
{
"method":"props","params":{
"power":"off"}}

If the Yeelight Interested in , You can contact us :[email protected]
边栏推荐
- Technology sharing | wvp+zlmediakit realizes streaming playback of camera gb28181
- Zed acquisition
- In the process of enterprise development, I found that a colleague used the select * from where condition for update
- 软件测试与游戏测试文章合集录
- JDBC - database connection
- How to reduce the font size of custom controls (optimize the round dot progress bar)
- ros(25):rqt_ image_ View reports an error unable to load plugin for transport 'compressed', error string
- Usage of ViewModel and livedata in jetpack
- Color gradient gradient color collection
- On the difficulty of developing large im instant messaging system
猜你喜欢

Registration method of native method in JNI

Interesting checkbox counters
Paper review: U2 net, u-net composed of u-net

C WinForm maximizes occlusion of the taskbar and full screen display

Use coordinatorlayout+appbarlayout+collapsingtoolbarlayout to create a collapsed status bar

JMeter socket connection sends data

UE4 WebBrowser chart cannot display problems

无需显示屏的VNC Viewer远程连接树莓派

Design scheme of authority management of fusion model

Meta&伯克利基于池化自注意力机制提出通用多尺度视觉Transformer,在ImageNet分类准确率达88.8%!开源...
随机推荐
傳輸層 以字節為單比特的滑動窗口技術
Network request -volley
What is the difference between one way and two way ANOVA analysis, and how to use SPSS or prism for statistical analysis
【面试题】instancof和getClass()的区别
C程序设计专题 15-16年期末考试习题解答(上)
redis + lua实现分布式接口限流实现方案
On the difficulty of developing large im instant messaging system
Creative SVG ring clock JS effect
Time unified system
Virtual machine - network configuration
JDBC - database connection
Im instant messaging development application keeping alive process anti kill
wx小程序跳转页面
C WinForm maximizes occlusion of the taskbar and full screen display
Several ways for wechat applet to jump to the page are worth collecting
Signal integrity (SI) power integrity (PI) learning notes (I) introduction to signal integrity analysis
Investment analysis and prospect forecast report of global and Chinese triglycine sulfate industry from 2022 to 2028
Binder mechanism and Aidl communication example
Paint rounded rectangle
Analysis report on development mode and investment direction of sodium lauriminodipropionate in the world and China 2022 ~ 2028