Toggle navigation
首页
问答
文章
积分商城
专家
专区
更多专区...
文档中心
返回主站
搜索
提问
会员
中心
登录
注册
RT-Thread
STM32H743
最小系统
【Nucleo】STM32H743ZI - RT-Thread 最小系统
发布于 2021-01-24 23:34:38 浏览:1187
订阅该版
[tocm] [RT-Thread 入门学习笔记 - 目录](https://club.rt-thread.org/ask/article/3420.html) [【Nucleo】STM32H743ZI - 入手篇](https://club.rt-thread.org/ask/article/2508.html) [【Nucleo】STM32H743ZI - RT-Thread 最小系统](https://club.rt-thread.org/ask/article/2514.html) [【ART-PI】STM32H750XBH6 系列 ](https://club.rt-thread.org/ask/article/2462.html) ## 背景 * 目标为进一步研究RT-Thread,掌握系统移植的基本方法 * RT-Thread 最新代码BSP里,已经有STM32H743的BSP了。 ## 操作方法 * 为了工程的简练,重构RT-Thread 工程     * 解决重构路径引起的问题:   * 编译   ## 运行 * 这里LED等的引脚,需要跟实际原理图对应上 | LED | 引脚 | RT-Thread Pin 编号 | | ---------- | ---- | ------------------ | | LED_R 红色 | PB14 | GET_PIN(B, 14) | | LED_G 绿色 | PB0 | GET_PIN(B, 0) | | LED_Y 黄色 | PE1 | GET_PIN(E, 1) | ```c #include
#include
#include
/* defined the LEDR LEDG LEDY pins */ #define LEDR_PIN GET_PIN(B, 14) #define LEDG_PIN GET_PIN(B, 0) #define LEDY_PIN GET_PIN(E, 1) int main(void) { int count = 1; /* set LEDS pin mode to output */ rt_pin_mode(LEDR_PIN, PIN_MODE_OUTPUT); rt_pin_mode(LEDG_PIN, PIN_MODE_OUTPUT); rt_pin_mode(LEDY_PIN, PIN_MODE_OUTPUT); rt_kprintf("hello, STM32H743 RT-Thread!\r\n"); while (count++) { rt_pin_write(LEDR_PIN, PIN_HIGH); rt_pin_write(LEDG_PIN, PIN_HIGH); rt_pin_write(LEDY_PIN, PIN_HIGH); rt_thread_mdelay(500); rt_pin_write(LEDR_PIN, PIN_LOW); rt_pin_write(LEDG_PIN, PIN_LOW); rt_pin_write(LEDY_PIN, PIN_LOW); rt_thread_mdelay(500); } return RT_EOK; } ```  * 验证通过,LED正常闪烁,串口MSH 正常。 ## 总结 * STM32H743 资源比较丰富,有2MB Flash,SRAM也比较大(1MB),可以做点更复杂的工作。 * 继续研究RT-Thread 移植与使用,总结与积累,学以致用。
3
条评论
默认排序
按发布时间排序
登录
注册新账号
关于作者
张世争
学以致用
文章
131
回答
813
被采纳
177
关注TA
发私信
相关文章
1
RT-THREAD在STM32H747平台上移植lwip
2
正点原子miniSTM32开发板读写sdcard
3
反馈rtt串口驱动对低功耗串口lpuart1不兼容的问题
4
Keil MDK 移植 RT-Thread Nano
5
RT1061/1052 带 RTT + LWIP和LPSPI,有什么坑要注意吗?
6
RT thread HID 如何收发数据
7
求一份基于RTT系统封装好的STM32F1系列的FLASH操作程序
8
RT-Thread修改项目名称之后不能下载
9
rt-studio编译c++
10
有木有移植rt-thread(nano)到riscv 32位MCU上
推荐文章
1
RT-Thread应用项目汇总
2
玩转RT-Thread系列教程
3
国产MCU移植系列教程汇总,欢迎查看!
4
机器人操作系统 (ROS2) 和 RT-Thread 通信
5
五分钟玩转RT-Thread新社区
6
【技术三千问】之《玩转ART-Pi》,看这篇就够了!干货汇总
7
关于STM32H7开发板上使用SDIO接口驱动SD卡挂载文件系统的问题总结
8
STM32的“GPU”——DMA2D实例详解
9
RT-Thread隐藏的宝藏之completion
10
【ART-PI】RT-Thread 开启RTC 与 Alarm组件
热门标签
RT-Thread Studio
串口
Env
LWIP
SPI
AT
Bootloader
Hardfault
CAN总线
FinSH
ART-Pi
DMA
USB
文件系统
RT-Thread
SCons
RT-Thread Nano
线程
MQTT
STM32
RTC
rt-smart
FAL
I2C_IIC
UART
ESP8266
cubemx
WIZnet_W5500
ota在线升级
PWM
BSP
flash
freemodbus
packages_软件包
潘多拉开发板_Pandora
定时器
ADC
GD32
flashDB
socket
编译报错
中断
Debug
rt_mq_消息队列_msg_queue
keil_MDK
ulog
SFUD
msh
C++_cpp
MicroPython
本月问答贡献
RTT_逍遥
8
个答案
2
次被采纳
KunYi
8
个答案
1
次被采纳
三世执戟
7
个答案
1
次被采纳
winfeng
2
个答案
1
次被采纳
chenyaxing
2
个答案
1
次被采纳
本月文章贡献
catcatbing
2
篇文章
5
次点赞
swet123
1
篇文章
4
次点赞
Days
1
篇文章
3
次点赞
YZRD
1
篇文章
2
次点赞
阳光的掌控者
1
篇文章
1
次点赞
回到
顶部
发布
问题
投诉
建议
回到
底部