当前位置:网站首页>About the difference between ch32 library function and STM32 library function
About the difference between ch32 library function and STM32 library function
2022-07-07 23:44:00 【Guard_ Byte】
I want to use MPU6050 Six axis sensor to control the car 90° Turn accurately and keep straight , But there is nothing left STM32F1 The board of , There are exactly two CH32F103 Minimum system board for , So I think it's OK to simply transplant the program , I didn't expect to encounter difficulties in this process .
Because I use CH32 Official library functions , The most commonly used driver code is almost based on STM32 Development , So be careful in the process of transplantation .
1、 The following is a CH32F10X_ Library functions about GPIO The relevant registers of are related to STM32 Different places :
On the left CH32 Official library functions , On the right is ST32 Official library functions , File "ch/stm32f10x_gpio.c "
In use IIC perhaps DHT11 Wait for one IO When considering both input and output capabilities , Pay special attention to I/O Direction configuration , The names of the configuration registers in the figure are different , Pay attention to modification when using .
2、 besides , I also found in USART When the configuration , Individual register names are also different , If used printf Function printout redirection function :

thus it can be seen , In order to make a distinction , In the details, I moved my little mind . however Don't forget that they use the same ARM framework Cortex - M3 kernel , alike 32 position MCU, So I checked their firmware library functions , Find out Except for different names, the address and length of common registers are exactly the same , Everyone understands it here , Pay a little attention to some places , Then use it directly STM32 The firmware library function is over .
3、 We may talk about it later domestic ARM framework 32 position MCU And STM32 Use difference of , If you have time ha-ha ~
边栏推荐
- Enumeration, simulation, and sorting
- Anxin can internally test offline voice module vb-01 to communicate with esp-c3-12f
- StringUtils工具类
- 正畸注意事项(持续更新中)
- Display the server hard disk image to the browser through Servlet
- @Configuration注解的详细介绍
- archery安装测试
- The file format and extension of XLS do not match
- 神奇快速幂
- Uic564-2 Appendix 4 - flame retardant fire test: flame diffusion
猜你喜欢
postgis学习
![Arbre binaire équilibré [Arbre AVL] - Insérer et supprimer](/img/1f/cd38b7c6f00f2b3e85d4560181a9d2.png)
Arbre binaire équilibré [Arbre AVL] - Insérer et supprimer
![[stm32+esp8266 connects to Tencent cloud IOT development platform 3] stm32+esp8266-01s dynamically registers devices on Tencent cloud (at instruction mode) -- with source code](/img/55/ab50ead2564498cb214d98ac5b9c3d.jpg)
[stm32+esp8266 connects to Tencent cloud IOT development platform 3] stm32+esp8266-01s dynamically registers devices on Tencent cloud (at instruction mode) -- with source code

Take you hand in hand to build feign with idea

Lm12 rolling heikin Ashi double K-line filter

一份假Offer如何盗走了「Axie infinity」5.4亿美元?

Class C design questions

Pycharm essential plug-in, change the background (self use, continuous update) | CSDN creation punch in
![Balanced binary tree [AVL tree] - insert, delete](/img/1f/cd38b7c6f00f2b3e85d4560181a9d2.png)
Balanced binary tree [AVL tree] - insert, delete

List. How to achieve ascending and descending sort() 2020.8.6
随机推荐
【LeetCode】20、有效的括号
Fibonacci number of dynamic programming
Pycharm essential plug-in, change the background (self use, continuous update) | CSDN creation punch in
HDU - 1260 Tickets(线性DP)
Chisel tutorial - 01 Introduction to Scala
SAP HR奖罚信息导出
@Configuration注解的详细介绍
【实验分享】通过Console口登录到Cisco设备
redis缓存工具类,值得拥有~
C - minute number V3
ping报错:未知的名称或服务
Aitm3.0005 smoke toxicity test
Installing gradle
Slam interview summary
How to change the formula picture in the paper directly into the formula in word
One of the anti climbing methods
Chisel tutorial - 00 Ex.scala metals plug-in (vs Code), SBT and coursier exchange endogenous
How did a fake offer steal $540million from "axie infinity"?
数据库面试题+解析
Possible SQL for Oracle table lookup information