【安信可BW16-Kit】开箱+点灯
<div class='showpostmsg'> 本帖最后由 chrisrh 于 2024-1-26 17:09 编辑<article data-content="[{"type":"block","id":"3060-1621846615933","name":"heading","data":{"level":"h1","style":{}},"nodes":[{"type":"text","id":"p5PQ-1621846617594","leaves":[{"text":"1、概述","marks":[]}]}],"state":{}},{"type":"block","id":"htHo-1706255010701","name":"paragraph","data":{},"nodes":[{"type":"text","id":"OGuA-1706255010700","leaves":[{"text":"","marks":[]}]},{"type":"inline","id":"CP47-1706235959073","name":"link","data":{"href":"https://docs.ai-thinker.com/rtl87xx?s[]=bw16&s[]=%E6%A8%A1%E7%BB%84&s[]=at&s[]=%E6%8C%87%E4%BB%A4"},"nodes":[{"type":"text","id":"6tz3-1706235959074","leaves":[{"text":"瑞昱BW系列模组专题 | 安信可科技 (ai-thinker.com)","marks":[]}]}]},{"type":"text","id":"FCFS-1706235959078","leaves":[{"text":"","marks":[]}]}],"state":{}},{"type":"block","id":"2UO9-1706235960928","name":"paragraph","data":{},"nodes":[{"type":"text","id":"qofD-1706235960927","leaves":[{"text":"BW16是基于 RTL8720DN开发的双频Wi-Fi+蓝牙SoC模组。BW16支持双频(2.4GHz 或 5GHz)WLAN和低功耗蓝牙5.0;","marks":[]}]}],"state":{}},{"type":"block","id":"pIbA-1706237067814","name":"list-item","data":{"listId":"y0xn-1706237090481","listType":"unordered","listLevel":1,"style":{}},"nodes":[{"type":"text","id":"h5eZ-1706237067813","leaves":[{"text":"支持802.11a/b/g/n 1×1,2.4GHz or 5GHz\r","marks":[]}]}],"state":{"index":1}},{"type":"block","id":"ecVL-1706237085454","name":"list-item","data":{"listId":"y0xn-1706237090481","listType":"unordered","listLevel":1,"style":{}},"nodes":[{"type":"text","id":"bPyF-1706237085455","leaves":[{"text":"支持HT20/HT40模式\r","marks":[]}]}],"state":{"index":2}},{"type":"block","id":"yXMq-1706237085456","name":"list-item","data":{"listId":"y0xn-1706237090481","listType":"unordered","listLevel":1,"style":{}},"nodes":[{"type":"text","id":"wraG-1706237085457","leaves":[{"text":"支持低功耗信标监听模式,低功耗接收模式,低功耗挂起模式\r","marks":[]}]}],"state":{"index":3}},{"type":"block","id":"o5qS-1706237085458","name":"list-item","data":{"listId":"y0xn-1706237090481","listType":"unordered","listLevel":1,"style":{}},"nodes":[{"type":"text","id":"Bchm-1706237085459","leaves":[{"text":"内置AES / DES / SHA硬件引擎\r","marks":[]}]}],"state":{"index":4}},{"type":"block","id":"ESvK-1706237085460","name":"list-item","data":{"listId":"y0xn-1706237090481","listType":"unordered","listLevel":1,"style":{}},"nodes":[{"type":"text","id":"AsfF-1706237085461","leaves":[{"text":"支持TrustZone-M,支持安全启动\r","marks":[]}]}],"state":{"index":5}},{"type":"block","id":"XWDA-1706237085462","name":"list-item","data":{"listId":"y0xn-1706237090481","listType":"unordered","listLevel":1,"style":{}},"nodes":[{"type":"text","id":"JVXN-1706237085463","leaves":[{"text":"支持SWD调试端口访问保护和禁止模式\r","marks":[]}]}],"state":{"index":6}},{"type":"block","id":"7luf-1706237085464","name":"list-item","data":{"listId":"y0xn-1706237090481","listType":"unordered","listLevel":1,"style":{}},"nodes":[{"type":"text","id":"RIHS-1706237085465","leaves":[{"text":"支持BLE 5.0\r","marks":[]}]}],"state":{"index":7}},{"type":"block","id":"WQOj-1706237085466","name":"list-item","data":{"listId":"y0xn-1706237090481","listType":"unordered","listLevel":1,"style":{}},"nodes":[{"type":"text","id":"0yoi-1706237085467","leaves":[{"text":"蓝牙支持高功率模式(7dBm,与Wi-Fi共享同一PA)\r","marks":[]}]}],"state":{"index":8}},{"type":"block","id":"bP9L-1706237085468","name":"list-item","data":{"listId":"y0xn-1706237090481","listType":"unordered","listLevel":1,"style":{}},"nodes":[{"type":"text","id":"sRWw-1706237085469","leaves":[{"text":"Wi-Fi和BLE共用同一天线\r","marks":[]}]}],"state":{"index":9}},{"type":"block","id":"GYec-1706237085470","name":"list-item","data":{"listId":"y0xn-1706237090481","listType":"unordered","listLevel":1,"style":{}},"nodes":[{"type":"text","id":"Fr0b-1706237085471","leaves":[{"text":"支持 STA/AP/STA+AP 工作模式\r","marks":[]}]}],"state":{"index":10}},{"type":"block","id":"qKmn-1706237085472","name":"list-item","data":{"listId":"y0xn-1706237090481","listType":"unordered","listLevel":1,"style":{}},"nodes":[{"type":"text","id":"IJ9O-1706237085473","leaves":[{"text":"支持安卓、iOS的 Simple Config(APP) 一键配网\r","marks":[]}]}],"state":{"index":11}},{"type":"block","id":"8wp9-1706237085474","name":"list-item","data":{"listId":"y0xn-1706237090481","listType":"unordered","listLevel":1,"style":{}},"nodes":[{"type":"text","id":"J8Er-1706237085475","leaves":[{"text":"支持串口本地升级和远程固件升级(FOTA)","marks":[]}]}],"state":{}}]">
<p><strong>1、概述</strong></p>
<article data-content="[{"type":"block","id":"3060-1621846615933","name":"heading","data":{"level":"h1","style":{}},"nodes":[{"type":"text","id":"p5PQ-1621846617594","leaves":[{"text":"1、概述","marks":[]}]}],"state":{}},{"type":"block","id":"htHo-1706255010701","name":"paragraph","data":{},"nodes":[{"type":"text","id":"OGuA-1706255010700","leaves":[{"text":"","marks":[]}]},{"type":"inline","id":"CP47-1706235959073","name":"link","data":{"href":"https://docs.ai-thinker.com/rtl87xx?s[]=bw16&s[]=%E6%A8%A1%E7%BB%84&s[]=at&s[]=%E6%8C%87%E4%BB%A4"},"nodes":[{"type":"text","id":"6tz3-1706235959074","leaves":[{"text":"瑞昱BW系列模组专题 | 安信可科技 (ai-thinker.com)","marks":[]}]}]},{"type":"text","id":"FCFS-1706235959078","leaves":[{"text":"","marks":[]}]}],"state":{}},{"type":"block","id":"2UO9-1706235960928","name":"paragraph","data":{},"nodes":[{"type":"text","id":"qofD-1706235960927","leaves":[{"text":"BW16是基于 RTL8720DN开发的双频Wi-Fi+蓝牙SoC模组。BW16支持双频(2.4GHz 或 5GHz)WLAN和低功耗蓝牙5.0;","marks":[]}]}],"state":{}},{"type":"block","id":"pIbA-1706237067814","name":"list-item","data":{"listId":"y0xn-1706237090481","listType":"unordered","listLevel":1,"style":{}},"nodes":[{"type":"text","id":"h5eZ-1706237067813","leaves":[{"text":"支持802.11a/b/g/n 1×1,2.4GHz or 5GHz\r","marks":[]}]}],"state":{"index":1}},{"type":"block","id":"ecVL-1706237085454","name":"list-item","data":{"listId":"y0xn-1706237090481","listType":"unordered","listLevel":1,"style":{}},"nodes":[{"type":"text","id":"bPyF-1706237085455","leaves":[{"text":"支持HT20/HT40模式\r","marks":[]}]}],"state":{"index":2}},{"type":"block","id":"yXMq-1706237085456","name":"list-item","data":{"listId":"y0xn-1706237090481","listType":"unordered","listLevel":1,"style":{}},"nodes":[{"type":"text","id":"wraG-1706237085457","leaves":[{"text":"支持低功耗信标监听模式,低功耗接收模式,低功耗挂起模式\r","marks":[]}]}],"state":{"index":3}},{"type":"block","id":"o5qS-1706237085458","name":"list-item","data":{"listId":"y0xn-1706237090481","listType":"unordered","listLevel":1,"style":{}},"nodes":[{"type":"text","id":"Bchm-1706237085459","leaves":[{"text":"内置AES / DES / SHA硬件引擎\r","marks":[]}]}],"state":{"index":4}},{"type":"block","id":"ESvK-1706237085460","name":"list-item","data":{"listId":"y0xn-1706237090481","listType":"unordered","listLevel":1,"style":{}},"nodes":[{"type":"text","id":"AsfF-1706237085461","leaves":[{"text":"支持TrustZone-M,支持安全启动\r","marks":[]}]}],"state":{"index":5}},{"type":"block","id":"XWDA-1706237085462","name":"list-item","data":{"listId":"y0xn-1706237090481","listType":"unordered","listLevel":1,"style":{}},"nodes":[{"type":"text","id":"JVXN-1706237085463","leaves":[{"text":"支持SWD调试端口访问保护和禁止模式\r","marks":[]}]}],"state":{"index":6}},{"type":"block","id":"7luf-1706237085464","name":"list-item","data":{"listId":"y0xn-1706237090481","listType":"unordered","listLevel":1,"style":{}},"nodes":[{"type":"text","id":"RIHS-1706237085465","leaves":[{"text":"支持BLE 5.0\r","marks":[]}]}],"state":{"index":7}},{"type":"block","id":"WQOj-1706237085466","name":"list-item","data":{"listId":"y0xn-1706237090481","listType":"unordered","listLevel":1,"style":{}},"nodes":[{"type":"text","id":"0yoi-1706237085467","leaves":[{"text":"蓝牙支持高功率模式(7dBm,与Wi-Fi共享同一PA)\r","marks":[]}]}],"state":{"index":8}},{"type":"block","id":"bP9L-1706237085468","name":"list-item","data":{"listId":"y0xn-1706237090481","listType":"unordered","listLevel":1,"style":{}},"nodes":[{"type":"text","id":"sRWw-1706237085469","leaves":[{"text":"Wi-Fi和BLE共用同一天线\r","marks":[]}]}],"state":{"index":9}},{"type":"block","id":"GYec-1706237085470","name":"list-item","data":{"listId":"y0xn-1706237090481","listType":"unordered","listLevel":1,"style":{}},"nodes":[{"type":"text","id":"Fr0b-1706237085471","leaves":[{"text":"支持 STA/AP/STA+AP 工作模式\r","marks":[]}]}],"state":{"index":10}},{"type":"block","id":"qKmn-1706237085472","name":"list-item","data":{"listId":"y0xn-1706237090481","listType":"unordered","listLevel":1,"style":{}},"nodes":[{"type":"text","id":"IJ9O-1706237085473","leaves":[{"text":"支持安卓、iOS的 Simple Config(APP) 一键配网\r","marks":[]}]}],"state":{"index":11}},{"type":"block","id":"8wp9-1706237085474","name":"list-item","data":{"listId":"y0xn-1706237090481","listType":"unordered","listLevel":1,"style":{}},"nodes":[{"type":"text","id":"J8Er-1706237085475","leaves":[{"text":"支持串口本地升级和远程固件升级(FOTA)","marks":[]}]}],"state":{}}]">
<p><a href="https://docs.ai-thinker.com/rtl87xx?s[]=bw16&s[]=%E6%A8%A1%E7%BB%84&s[]=at&s[]=%E6%8C%87%E4%BB%A4">瑞昱BW系列模组专题 | 安信可科技 (ai-thinker.com)</a></p>
<p>BW16是基于 RTL8720DN开发的双频Wi-Fi+蓝牙SoC模组。BW16支持双频(2.4GHz 或 5GHz)WLAN和低功耗蓝牙5.0;</p>
<ul yne-block-type="list">
<li>支持802.11a/b/g/n 1×1,2.4GHz or 5GHz</li>
<li>支持HT20/HT40模式</li>
<li>支持低功耗信标监听模式,低功耗接收模式,低功耗挂起模式</li>
<li>内置AES / DES / SHA硬件引擎</li>
<li>支持TrustZone-M,支持安全启动</li>
<li>支持SWD调试端口访问保护和禁止模式</li>
<li>支持BLE 5.0</li>
<li>蓝牙支持高功率模式(7dBm,与Wi-Fi共享同一PA)</li>
<li>Wi-Fi和BLE共用同一天线</li>
<li>支持 STA/AP/STA+AP 工作模式</li>
<li>支持安卓、iOS的 Simple Config(APP) 一键配网</li>
<li>支持串口本地升级和远程固件升级(FOTA)</li>
</ul>
</article>
<article _blank="" data-content="[{"type":"block","name":"image","data":{"version":1,"url":"<a target=">
<div></div>
<div> </div>
<div><strong>2、初步应用</strong></div>
<div>将板子,接到电脑上,打开串口115200,显示日志</div>
<div></div>
<div>当前固件为:BW16 Combo-AT固件(固件号1879)</div>
<div>准备刷入:BW16最新版Combo-AT固件(固件号2179)</div>
<div>固件更新版本说明:<a href="https://aithinker.readthedocs.io/zh-cn/latest/docs/taobao/BW16/index.html">RTL87XX系列 — 安信可科技 文档 (aithinker.readthedocs.io)</a></div>
<div> </div>
<div><strong>3、电路分析</strong></div>
<div>原理图:</div>
<div>BW16-Kit版本中接口Type-C对应串口0,引脚UART_LOG_RXD(PA8_LOG_RX0)、UART_LOG_TXD(PA7_LOG_TX0),操作AT指令不会发生冲突。</div>
<div>开发板只能选择通过Type-C或者通过UART_LOG_RXD、UART_LOG_TXD引脚接TTL模块的方法烧录新固件,完成固件升级。</div>
<div><span style="color:#3498db;">Flash默认2MB</span></div>
<div><span style="color:#f39c12;">原理图没什么问题,唯一的就是,板子上没有丝印啊,也没有丝印图,想改阻容不知道哪个是哪个~</span></div>
<div> </div>
<div> </div>
<div><strong>4、固件更新</strong></div>
<div>刷入最新固件2179,</div>
<div>刷入教程和工具:BW16_V1.0和V1.2开发板下载更新固件指导手册:</div>
<div><span style="color:#1abc9c;">打开串口工具,选择对应的串口号,配置波特率115200,8,N,1,用16 进制显示:</span></div>
<ol>
<li>将开发板连接电脑</li>
<li>长按右边的按键Burn不松</li>
<li>按一下左边的复位按键</li>
<li>松开右边的按键Burn,此时模块进入烧录模式<br />
如果进入到烧录模式则电脑串口会不断接收0x15,则进入了烧录模式;<br />
</li>
<li>关闭串口助手的端口占用</li>
<li>打开ImageTool.exe 工具,Chip Select选择(8721D)<br />
</li>
<li>COM选择对应的串口号,波特率为1500000,open串口,下方会显示open successfully连接成功;<br />
地址0x8000000,Size:2048KB,刷入固件前点击erase擦除flash内原有的固件<br />
</li>
<li>点击erase擦除<br />
点击Browse选择最新的固件,可以分开刷入,也可以直接选择合并好的(2179)BAT_BW16_自定义_16Mbit_V4.18_P5.6.4_20230530.bin,地址0x08000000<br />
</li>
<li>点击Download进行下载,固件更新,完成后自动关闭串口<br />
<br />
</li>
<li>此时使用串口助手打开端口进行连接,log仍在输出0x15,<span style="color:#3498db;">点击复位,已为最新版本的日志,发送AT+GMR指令查看版本号,固件更新成功</span></li>
</ol>
<div></div>
<div><strong>5、AT指令点灯</strong></div>
<div>DEMO板的RGB5050三色灯分别接在了芯片的PA12/PA13/PA14脚</div>
<div></div>
<div>确认引脚在芯片上的位置,通过RTL8720DN的数据手册如下,发现PA12/PA13/PA14脚对应芯片的20/21/22脚</div>
<div></div>
<div><strong>①、设置IO管脚映射关系</strong></div>
<div><strong>AT+SYSIOMAP 查询或设置 IO 映射表</strong></div>
<div>命令:</div>
<div>AT+SYSIOMAP=<PinNumber>,<pin1>,<pin2>,...,<pinN></div>
<div><pinNumber>:要设置的 IO 总数。</div>
<div><pinxx>:模组 IO 引脚</div>
<div>(从模组左上角逆时针排序,引脚序号从 1 开始)对应的芯片引脚编号(1~254,这个根据芯片手册上的引脚编号来就可以)如果模组没有对应芯片引脚则设置为 NC</div>
<div> </div>
<div>映射三个LED的引脚,那么就用串口助手发送</div>
<div>AT+SYSIOMAP=22,PinMap:NC,NC,NC,NC,NC,NC,NC,NC,NC,NC,NC,NC,NC,NC,NC,NC,NC,NC,NC,20,21,22</div>
<div> </div>
<div>串口助手回复:</div>
<div>flash save ok</div>
<div>AI_HalWriteFlash success</div>
<div> </div>
<div>则证明已经对PA12/PA13/PA14完成了映射</div>
<div>发送AT+SYSIOMAP?则会回复已配置的IO情况</div>
<div> </div>
<div><strong>②、设置 GPIO 输出电平</strong></div>
<div>命令:AT+SYSGPIOWRITE=<pin>,<level></div>
<div>参数:</div>
<div><pin>:模组 IO 引脚号。从模组左上角逆时针排序,引脚序号从 1 开始</div>
<div><level>: 引脚电平。0:低电平,1:高电平</div>
<div> </div>
<div>点亮LED</div>
<div>AT+SYSGPIOWRITE=20,1</div>
<div>AT+SYSGPIOWRITE=21,1</div>
<div>AT+SYSGPIOWRITE=22,1</div>
<div>关闭LED</div>
<div>AT+SYSGPIOWRITE=20,0</div>
<div>AT+SYSGPIOWRITE=21,0</div>
<div>AT+SYSGPIOWRITE=22,0</div>
<div> </div>
<div></div>
<div></div>
<div>点灯成功~</div>
<div> </div>
<div> </div>
<div><strong>附录:AT指令集</strong></div>
<div><a href="https://aithinker-combo-guide.readthedocs.io/en/latest/index.html">Combo-AT-Guide — 安信可科技 documentation (aithinker-combo-guide.readthedocs.io)</a></div>
</article>
<p> </p>
<p> </p>
</article>
</div><script> var loginstr = '<div class="locked">查看本帖全部内容,请<a href="javascript:;" style="color:#e60000" class="loginf">登录</a>或者<a href="https://bbs.eeworld.com.cn/member.php?mod=register_eeworld.php&action=wechat" style="color:#e60000" target="_blank">注册</a></div>';
if(parseInt(discuz_uid)==0){
(function($){
var postHeight = getTextHeight(400);
$(".showpostmsg").html($(".showpostmsg").html());
$(".showpostmsg").after(loginstr);
$(".showpostmsg").css({height:postHeight,overflow:"hidden"});
})(jQuery);
} </script><script type="text/javascript">(function(d,c){var a=d.createElement("script"),m=d.getElementsByTagName("script"),eewurl="//counter.eeworld.com.cn/pv/count/";a.src=eewurl+c;m.parentNode.insertBefore(a,m)})(document,523)</script> <p>和8266有什么区别啊?</p><br/>
页:
[1]