描述
<div class="document">
<h3 class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;"> 1、项目功能介绍</h3>
<hr class="horizontal-splitline normal-bold-2">
<p class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;">目标其实很简单,就是想做一款自己制作的智能手表平时戴着玩,是自己设计并制作的哦!</p>
<p class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;">瑞萨DA14706 Bluetooth SOC,在智能穿戴应用方面较成熟,有大厂采用,所以主控MCU就选了它。手表兼容BLUETOOTH<sup>®</sup> 5.2,支持320x390 LCD电容触摸屏幕,9D运动传感,支持运动计步睡眠等,预留健康采集接口,后续可扩展心率血氧等健康功能。手表支持标准Type C USB接口,支持在线Jlink调试;为方便支持各种DIY需求,通过此接口也可以扩展其它硬件配件。</p>
<p class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;">完善的结构设计,日常可当正常手表使用。既实用,还能随便改;咱就这么任性!</p>
<p class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;"> </p>
<h3 class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;">2、项目属性</h3>
<hr class="horizontal-splitline normal-bold-2">
<p class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;"><span style="color: #000000; background-color: #ffffff;"><span style="font-size: 14px; background-color: #ffffff;"><span style="font-size: 16px; background-color: #ffffff;">原创,首次公开</span> </span></span></p>
<p class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;"> </p>
<h3 class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;">3、开源协议</h3>
<hr class="horizontal-splitline normal-bold-2">
<p class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;">TAPR Open Hardware License</p>
<h3 class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;">4、硬件部分</h3>
<h4> A.主板内容,如下图所示:</h4>
<hr class="horizontal-splitline normal-bold-2">
<p class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;"><img src="//image.lceda.cn/pullimage/fWlE142Gmej6uvdfosX25y5Rib5qxKJw9AMyCsR1.png" alt="" width="595" height="722"></p>
<p class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;"> </p>
<h4 class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;"> B. LCD电容触摸屏:</h4>
<p> 显示驱动IC为GC9B71,QSPI接口,分辨率320x390;触摸驱动IC为CST816D。<img src="//image.lceda.cn/pullimage/BrgzJ1J5VSRxCYTzFn0jsZ1isJLiJ9fLPnI2Crpc.png" alt="" width="219" height="371"></p>
<p><img src="//image.lceda.cn/pullimage/J8VjuIuY6C3hiZuTK1ZZZG2bBAVqS7WjCnrSnBXp.png"> </p>
<h4 class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;"> C. 运动健康传感部分:</h4>
<p>6D运动传感器LSM6DS3TR,3D磁力计QMC6308,气压传感LPS22HB,汇接于同一个I2C总线;同时,预留一个支持SPI接口的健康传感器连接位。</p>
<p class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;"><img src="//image.lceda.cn/pullimage/cbLTjsFHeVmktt7asQW4DAO4vvaFFcYn2wPhwwk6.png"></p>
<h4 class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;"> D. 开关多功能按键:</h4>
<p>手表机身侧按键,支持长按7秒复位,便于软件调试用。</p>
<p><img src="//image.lceda.cn/pullimage/4iDbUxH9TcPzHfoFmQPuWBYHzXu2HTF048dDBH15.png"></p>
<p> </p>
<h4 class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;"> E. TypeC USB调试与扩展:</h4>
<p>Jlink SWD调试接口通过TypeC USB引出,外接带电平转换器TXB0104的接口板,接入Jlink调试仿真器。</p>
<p class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;"><span style="color: #95a5a6; font-size: 14px;"><img src="//image.lceda.cn/pullimage/ke20Pv6jXpBWcipzEFSPXtKnSLyz9fSANw98R5f4.png" alt="" width="3470" height="613"><br></span></p>
<p class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;"><img src="//image.lceda.cn/pullimage/beEOgj0QDIXDIy1jus7IWGZ59fyP6x59yfXXDbld.png"></p>
<p class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;"> </p>
<h4 class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;">F. 蓝牙BLE连接测试:</h4>
<p>编译运行范例BLE_SDK10_DA1470x_examples-main\connectivity\ble_custom_service,手机端运行蓝牙测试助手APP,扫描如下结果说明蓝牙连接正常;</p>
<p><img src="//image.lceda.cn/pullimage/GXj6TCQnOAb1gLOYD8EBGK3lUOfiUAcFq7qgDVGW.jpeg"></p>
<p> </p>
<h3 class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;">5、软件部分</h3>
<hr class="horizontal-splitline normal-bold-2">
<h4 class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;"> A. 源码设计与开发环境:</h4>
<p class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;"><span style="color: #000000; font-size: 14px;">软件开发基于瑞萨提供的SmartSnippets™ Software Development Kit (SDK)和SmartSnippets™ Studio开发平台。SmartSnippets™ Studio提供一个完整的蓝牙BLE应用开发环境, 包括GNU Compiler Collection (GCC)/ Debugger (GDB)工具, Eclipse CDT IDE集成开发环境和一系列辅助工具。SDK包括蓝牙协议栈,BSP,FreeRTOS和LVGL图形框架。</span></p>
<p class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;"><span style="color: #000000; font-size: 14px;">一般的,开发我们自己的手表应用,最快捷的方式是找一个瑞萨提供的官方范例来移植和修改。依据范例的代码架构和手表主板硬件资源的规划,一般应修改这些硬件相关文件:项目配置文件custom_config_oqspi.h,外围硬件资源分配文件peripheral_setup.h、platform_devices.h和platform_devices.c,同时根据应用的具体需求编写硬件驱动代码和应用流程控制代码。针对我们这个手表项目,可以选BLE_SDK10_DA1470x_examples-main\features\factory_firmware这个范例来移植修改,具体分析如下:</span></p>
<h4 class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;"> B. 平台和外围硬件资源配置:</h4>
<p> a. 根据主控板硬件资源和项目功能,修改<span style="color: #000000; font-size: 14px;">项目配置文件custom_config_oqspi.h,具体如下图,</span></p>
<p><span style="color: #000000; font-size: 14px;"><img src="//image.lceda.cn/pullimage/Gm0e5qjmV2lsJSNlqdrPQeaLB8daVQfga5wlurLo.png"></span></p>
<p><span style="color: #000000; font-size: 14px;"><img src="//image.lceda.cn/pullimage/960KuK5rnt12rFtAUHSDhBG6CFCYQpkCrDDvaUxt.png"></span></p>
<p> </p>
<p><span style="color: #000000; font-size: 14px;"> b. 定义分配外围设备硬件IO等资源peripheral_setup.h,具体如下图,</span></p>
<p><span style="color: #000000; font-size: 14px;"><img src="//image.lceda.cn/pullimage/LEaCd28XgRgkAu3tQml35PPdLHtm5n9VJzwGgqcw.png"></span></p>
<p> </p>
<h4 class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;">C. 如何驱动LCD电容触摸屏?</h4>
<p class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;"><span style="color: #95a5a6; font-size: 14px;"> <span style="color: #000000;"> a. 项目中LCD屏用的控制IC是GC9B71,QSPI接口方式;因此,我们要自己添加驱动代码:gc9b71_qspi.h,其内容如下;根据LVGL和GDI移植的要求,这个文件主要包括GC9B71相关的硬件接口规程和初始化指令。</span></span></p>
<p class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;"><span style="color: #95a5a6; font-size: 14px;"><img src="//image.lceda.cn/pullimage/G0AURmRPYSot5vzvV8Ra3zBkUDjD4dRj3D45PEql.png"></span></p>
<p class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;"><span style="color: #95a5a6; font-size: 14px;"><span style="color: #000000;"> b. 项目中触摸屏用的控制IC是CST816D,I2C接口,因此,我们要自己添加驱动代码:CST816D.h,应包含如下内容;</span></span></p>
<p class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;"><span style="color: #95a5a6; font-size: 14px;"><span style="color: #000000;"><img src="//image.lceda.cn/pullimage/hLstjKBQ65YyOsXuBAu40c2wlO3GUXwerM7Tns1P.png"></span></span></p>
<p class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;"><span style="color: #95a5a6; font-size: 14px;"><span style="color: #000000;"> c. 在platform_devices.c文件中添加如何IO配置信息;</span></span></p>
<p class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;"><span style="color: #95a5a6; font-size: 14px;"><span style="color: #000000;"><img src="//image.lceda.cn/pullimage/O2Qt4ilrNYQXWHKnm6Ynpj6Gxy7RO2soSG6X7tke.png"></span></span></p>
<p class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;"> </p>
<p class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;"><span style="color: #95a5a6; font-size: 14px;"><span style="color: #000000;">并在platform_devices.h文件中作"extern"宣布:</span></span></p>
<p class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;"> </p>
<p class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;"><span style="color: #95a5a6; font-size: 14px;"><span style="color: #000000;"><img src="//image.lceda.cn/pullimage/an8bATy7lyF9vAzgdBgOJAdRQaJSNKprI95OxBXu.png"></span></span></p>
<p class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;"> </p>
<p class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;"><span style="color: #95a5a6; font-size: 14px;"><span style="color: #000000;"> d. 根据背光驱动IO设计,在gdi.c文件中修改背光驱动代码,保证能点亮LCD背光;下图针对我们项目调整的背光驱动代码:</span></span></p>
<p class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;"><span style="color: #95a5a6; font-size: 14px;"><span style="color: #000000;"><img src="//image.lceda.cn/pullimage/pBGSOIQBqznvMNQVZxAqvzWJgDsQGglT9nLzdCpA.png"></span></span></p>
<p class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;"><span style="color: #95a5a6; font-size: 14px;"><span style="color: #000000;">e. 最后记得在<span style="color: #000000; font-size: 14px;">项目配置文件custom_config_oqspi.h中,宏定义dg_configUSE_GC9B71_QSPI 和</span>,dg_configUSE_CST816D,具体参考上述的项目平台配置内容。</span></span></p>
<h4 class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;">D. 如何写自己的应用,比如定制GUI?</h4>
<p>定制自己喜欢的UI,这个跟所有产品设计方法都一样,可以自己手动编写LVGL代码,也可以借助GUI工具,比如SquareLine studio或者GUI guider等。</p>
<p> </p>
<h3 class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;">6、BOM清单</h3>
<hr class="horizontal-splitline normal-bold-2">
<p class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;"><img src="//image.lceda.cn/pullimage/gZJ83CAZiwYs4SSdpzwzT3GnDd5MtCJM5lixHrcs.png" alt="" width="776" height="669"></p>
<p class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;"> </p>
<p class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;"> </p>
<h3 class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;">7、大赛LOGO验证</h3>
<hr class="horizontal-splitline normal-bold-2">
<p style="line-height: 1.8;"> </p>
<p class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;"><img src="//image.lceda.cn/pullimage/TkwPvpbuMVVKiAJWpG3rkKfFSW2jeAyN7wt6rju3.jpeg" alt="" width="608" height="754"></p>
<p class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;"> </p>
<p class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;"> </p>
<p class="paragraph text-align-type-left pap-line-1.3 pap-line-rule-auto pap-spacing-before-3pt pap-spacing-after-3pt" style="line-height: 1.8;"> </p>
</div>
评论(28)