当前位置:网站首页>USB (十八)2022-04-17
USB (十八)2022-04-17
2022-07-07 21:50:00 【晓晓暮雨潇潇】
Cyusb3014开发经验总结
1.固件开发
1.1串口打印调试信息
在固件开发时,可以利用串口打印调试信息,获得代码执行情况的指示。固件中,用于打印调试信息的串口配置如下,其中波特率的设置为112500,停止位为1,无校验位。在程序设计过程中,可在适当位置调用CyU3PDebugPrint函数打印信息,固件工程中可查看该函数原型。赛普拉斯官方代码非常规范,很多地方会进行返回值有效性检测并打印相关信息,在数据发送过程中,可以关注串口信息,看是否数据有溢出或丢失,如下图所示。
CyU3PUartConfig_t uartConfig;
CyU3PMemSet ((uint8_t *)&uartConfig, 0, sizeof (uartConfig));
uartConfig.baudRate = CY_U3P_UART_BAUDRATE_115200;
uartConfig.stopBit = CY_U3P_UART_ONE_STOP_BIT;
uartConfig.parity = CY_U3P_UART_NO_PARITY;
uartConfig.txEnable = CyTrue;
uartConfig.rxEnable = CyFalse;
uartConfig.flowCtrl 边栏推荐
- How to operate DTC community?
- Specific method example of V20 frequency converter manual automatic switching (local remote switching)
- OC variable parameter transfer
- iNFTnews | Web5 vs Web3:未来是一个过程,而不是目的地
- Sword finger offer 28 Symmetric binary tree
- ArcGIS:字段赋值_属性表字段计算器(Field Calculator)依据条件为字段赋值
- Why does the market need low code?
- Wechat forum exchange applet system graduation design completion (4) opening report
- Adrnoid开发系列(二十五):使用AlertDialog创建各种类型的对话框
- 位运算(Bit Operation)
猜你喜欢

微信论坛交流小程序系统毕业设计毕设(1)开发概要

Two minutes, talk about some wrong understandings of MySQL index

V20变频器手自动切换(就地远程切换)的具体方法示例

Why is network i/o blocked?

今日创见|企业促进创新的5大关键要素

U盘拷贝东西时,报错卷错误,请运行chkdsk

DTC社群运营怎么做?

Personal statement of testers from Shuangfei large factory: is education important for testers?

There is another problem just online... Warm

Are the microorganisms in the intestines the same as those on the skin?
随机推荐
网格(Grid)
Transparent i/o model from beginning to end
ArcGIS:矢量要素相同字段属性融合的两种方法
Installing vmtools is gray
聊聊 Dart 的空安全 (null safety) 特性
V20变频器手自动切换(就地远程切换)的具体方法示例
Software test classification
网络安全-安装CentOS
Byte hexadecimal binary understanding
PMP项目管理考试过关口诀-1
网络安全-钓鱼
Clean C disk
微信论坛交流小程序系统毕业设计毕设(7)中期检查报告
数据库每日一题---第22天:最后一次登录
Circumvention Technology: Registry
二叉树(Binary Tree)
开发那些事儿:Go加C.free释放内存,编译报错是什么原因?
Guessing game (read data from file)
Wechat forum exchange applet system graduation design completion (6) opening defense ppt
Anta DTC | Anta transformation, building a growth flywheel that is not only FILA