当前位置:网站首页>Stm32f411 SPI2 output error, pb15 has no pulse debugging record [finally, pb15 and pb14 were found to be short circuited]
Stm32f411 SPI2 output error, pb15 has no pulse debugging record [finally, pb15 and pb14 were found to be short circuited]
2022-07-01 15:24:00 【Please call me Chang Sicong】
Debugging last night TFT when , Due to hardware problems TFT Of SDA and SCL Interface is used in SPI2 Of PB15(SPI_MOSI) And PB13(SPI2_SCK) On .
There should be no problem with the logic in the program , And also in SPI1 The port has been verified , The normal operation , But received SPI2 There is no output on ,
Thought it was hardware SPI Why , Replaced by software SPI,
void LCD_SPIx_WriteByte(u8 data)
{
// HAL_SPI_Transmit(&LCD_SPI_CH,&data,1,0xffff);
unsigned char i=0;
for ( i = 8; i > 0; i --)
{
LCD_SCL_CLR;
if ( data & 0x80)
LCD_SDA_SET; // Output data
else
LCD_SDA_CLR;
LCD_SCL_SET;
data <<= 1;
}
}
however TFT It still doesn't show .
Last one blog:STM32F4-TFT-SPI Commissioning record of sequential logic analyzer
The normal timing has been captured by the logic analyzer , Only change to PB15 and PB13 There is no output on .
The logic analyzer found :
SCL–PB13 The pin sends pulses normally , however SDA–PB15 The hardware is always high , So the problem may be PB15 On ,
And now it's software SPI, Do not rule out PB15 In hardware SPI It is also constant high in mode , Check it out .
Change to hardware SPI:
Output is still problematic , Now we can locate the root cause should be SPI_MOSI That is to say PB15 There is a problem .
Check the hardware , See if there is a short circuit
Find out PB15 And PB14 A short circuit !!!!
Cheating ....
Change into another chip with tears
Then test
The timing is basically wrong , No wonder it can't be displayed ...
Switch to software SPI try , See if there is something wrong with the hardware ;
It's still not right ,TFT It doesn't show
Change SDA Pin to PB2:
This meeting seems to be right , however TFT No display , The inspection found that DC The pin is connected incorrectly , In turn, , According to the normal
Then change SDA To PB15:
According to the normal !!!!
Poor migrant workers in Shenzhen , Line up to do nucleic acid ....
-------------------------------------- Split line --------------------------------------------
Make nucleic acid ,
Change to hardware SPI Well ?
The timing looks wrong , But normal display ... Suddenly I remember
This is awkward ... The sampling rate is only twice as high ... Moreover, it is already the highest sampling rate of the logic analyzer !!!.
But I can only adjust the hardware SPI Baud rate
Finally, it is normal !!!!
Admire myself !!!
However, I think of another one before bug:
【STM32-USB-MSC Ask for help 】STM32F411CEU6 (WeAct)+w25q64+USB-MSC Flash use SPI2 The readout capacity is only 520KB
This is also the same development board ,,,, Should not ?? Cold behind .. Test it tomorrow ..
边栏推荐
- Task. Run(), Task. Factory. Analysis of behavior inconsistency between startnew() and new task()
- Task.Run(), Task.Factory.StartNew() 和 New Task() 的行为不一致分析
- It's settled! 2022 Hainan secondary cost engineer examination time is determined! The registration channel has been opened!
- OpenSSL client programming: SSL session failure caused by an insignificant function
- Logical analysis of automatic decision of SAP CRM organization model
- Tableapi & SQL and MySQL grouping statistics of Flink
- 精益六西格玛项目辅导咨询:集中辅导和点对点辅导两种方式
- Raytheon technology rushes to the Beijing stock exchange and plans to raise 540million yuan
- [cloud trend] new wind direction in June! Cloud store hot list announced
- phpcms后台上传图片按钮无法点击
猜你喜欢
Wechat applet 03 - text is displayed from left to right, and the block elements in the line are centered
MySQL 服务正在启动 MySQL 服务无法启动解决途径
S32K1xx 微控制器的硬件設計指南
Wechat official account subscription message Wx open subscribe implementation and pit closure guide
《性能之巅第2版》阅读笔记(五)--file-system监测
IDEA全局搜索快捷键(ctrl+shift+F)失效修复
Task. Run(), Task. Factory. Analysis of behavior inconsistency between startnew() and new task()
Wechat applet 01 bottom navigation bar settings
微信小程序01-底部导航栏设置
Filter &(登录拦截)
随机推荐
使用 csv 导入的方式在 SAP S/4HANA 里创建 employee 数据
TS报错 Don‘t use `object` as a type. The `object` type is currently hard to use
Can I choose to open an account on Great Wall Securities? Is it safe?
Wechat applet 03 - text is displayed from left to right, and the block elements in the line are centered
Hidden rules of the workplace that must be understood before 30
Wechat applet 02 - Implementation of rotation map and picture click jump
How to realize clock signal frequency division?
DirectX repair tool v4.1 public beta! [easy to understand]
Redis installation and setting up SSDB master-slave environment under Ubuntu 14.04
OpenSSL client programming: SSL session failure caused by an insignificant function
Written on the first day after Doris graduated
《QT+PCL第六章》点云配准icp系列6
S32K1xx 微控制器的硬件設計指南
Flink 系例 之 TableAPI & SQL 与 MYSQL 分组统计
SAP CRM organization Model(组织架构模型)自动决定的逻辑分析
Junda technology indoor air environment monitoring terminal PM2.5, temperature and humidity TVOC and other multi parameter monitoring
MySQL 服务正在启动 MySQL 服务无法启动解决途径
重回榜首的大众,ID依然乏力
Introduction to MySQL audit plug-in
Demand prioritization method based on value quantification