WiFi 智能插座
来自Jack's Lab
目录 |
1 Quick Start
1.1 准备一片通用模块
https://item.taobao.com/item.htm?id=522098524264
1.2 准备 SDK
# clone the whole sdk $ git clone --recursive git://github.com/icamgo/noduino-sdk.git noduino-sdk $ cd noduino-sdk/toolchain $ ./gen.py # generate the toolchain (you need Python 2.7)
更多参考:
- Getting Started with Noduino SDK on Linux
- Getting Started with Noduino SDK on Mac OS X
- Getting Started with Noduino SDK on Windows
1.3 刷写固件
进入插座参考设计,编译固件:
$ cd ../sketch/plug $ make
准备一个 USB 转串口板,此处我们使用一个 FT232RL USB 转串口板
用杜邦线把模块引脚按如下规则连上 USB 串口模块和通用插座模块:
- USB_VCCIO ---> VCC
- USB_RXD ---> TX
- USB_TXD ---> RX
- USB_GND ---> GND
长按住背面的小按钮开关、通电即进入刷机模式,然后确认一下你的USB转串口的串口设备号,如 Windows 下为 COM6,则:
$ make flash ESPPORT=COM6
1.4 控制演示
上传完之后,打开微信,扫一扫如下二维码,关注公众号:
进入公众号后,点下方菜单: 探索 ---> 添加设备:
点 ”开始配置“ 后:
然后,进入公众号菜单的“探索”--》我的设备 --》插座 即可控制
2 小K mini 微信控制
2015 年新的小 K 插座,全部使用 ESP8266 方案,由于芯片需求量大,小 K 要求 ESP8266 的厂家乐鑫打成了小 K 的 LOGO
默认串口波特率 74880,上电输出:
� ets Jan 8 2013,rst cause:1, boot mode:(3,0) load 0x40100000, len 612, room 16 tail 4 chksum 0x12 load 0x3ffe8000, len 788, room 4 tail 0 chksum 0x50 load 0x3ffe8314, len 264, room 8 tail 0 chksum 0x4a csum 0x4a 2nd boot version : 1.1 SPI Speed : 40MHz SPI Mode : SPI Flash Size : 8Mbit jump to run user2 pp_task_hdl : 3fff59b8, prio:14, stack:512 pm_task_hdl : 3fff63b0, prio:1, stack:176 ApiMsgMutex created idle_task_hdl : 3fff80a8 tim_task_hdl : 3fff83c0 xPortStartScheduler frc2_timer_task_hdl:3fff9018, prio:12, stack:200 OS SDK ver: 0.0.8 compiled @ Apr 16 2015 19:50:09 phy ver: 273, pp ver: 8.3 mode : sta(18:fe:34:f6:44:d1) add if0 scandone del if0 usl sul 0 0 add if0 scandone scandone add 0 aid 5 connected with Noduino-AP, channel 7 dhcp client start... cnt ip:192.168.1.50,mask:255.255.255.0,gw:192.168.1.1
3 Reference
- miniK: http://bbs.mydigit.cn/read.php?tid=1327613
- 云合:http://bbs.mydigit.cn/read.php?tid=1449956
- ORVIBO: http://bbs.mydigit.cn/read.php?tid=1320858
- 海尔: http://bbs.mydigit.cn/read.php?tid=1098323
- D-Link: http://bbs.mydigit.cn/read.php?tid=865037
- 插排:http://bbs.mydigit.cn/read.php?tid=1291309