久久久久久久999_99精品久久精品一区二区爱城_成人欧美一区二区三区在线播放_国产精品日本一区二区不卡视频_国产午夜视频_欧美精品在线观看免费
標題:
STM32F4xx官方IAP源碼
[打印本頁]
作者:
rest665
時間:
2019-10-11 20:07
標題:
STM32F4xx官方IAP源碼
STM32F4xx官方IAP源碼
單片機源程序如下:
/* Includes ------------------------------------------------------------------*/
#include "menu.h"
#include "stm324xg_eval.h"
/* Private typedef -----------------------------------------------------------*/
/* Private define ------------------------------------------------------------*/
/* Private macro -------------------------------------------------------------*/
/* Private variables ---------------------------------------------------------*/
extern pFunction Jump_To_Application;
extern uint32_t JumpAddress;
/* Private function prototypes -----------------------------------------------*/
static void IAP_Init(void);
/* Private functions ---------------------------------------------------------*/
/**
* @brief Main program.
* @param None
* @retval None
*/
int main(void)
{
/* Unlock the Flash Program Erase controller */
FLASH_If_Init();
/* Initialize Key Button mounted on STM324xG-EVAL board */
STM_EVAL_PBInit(BUTTON_KEY, BUTTON_MODE_GPIO);
/* Test if Key push-button on STM324xG-EVAL Board is pressed */
if (STM_EVAL_PBGetState(BUTTON_KEY) == 0x00)
{
/* Execute the IAP driver in order to reprogram the Flash */
IAP_Init();
/* Display main menu */
Main_Menu ();
}
/* Keep the user application running */
else
{
/* Test if user code is programmed starting from address "APPLICATION_ADDRESS" */
if (((*(__IO uint32_t*)APPLICATION_ADDRESS) & 0x2FFE0000 ) == 0x20000000)
{
/* Jump to user application */
JumpAddress = *(__IO uint32_t*) (APPLICATION_ADDRESS + 4);
Jump_To_Application = (pFunction) JumpAddress;
/* Initialize user application's Stack Pointer */
__set_MSP(*(__IO uint32_t*) APPLICATION_ADDRESS);
Jump_To_Application();
}
}
while (1)
{}
}
/**
* @brief Initialize the IAP: Configure USART.
* @param None
* @retval None
*/
void IAP_Init(void)
{
USART_InitTypeDef USART_InitStructure;
/* USART resources configuration (Clock, GPIO pins and USART registers) ----*/
/* USART configured as follow:
- BaudRate = 115200 baud
- Word Length = 8 Bits
- One Stop Bit
- No parity
- Hardware flow control disabled (RTS and CTS signals)
- Receive and transmit enabled
*/
USART_InitStructure.USART_BaudRate = 115200;
USART_InitStructure.USART_WordLength = USART_WordLength_8b;
USART_InitStructure.USART_StopBits = USART_StopBits_1;
USART_InitStructure.USART_Parity = USART_Parity_No;
USART_InitStructure.USART_HardwareFlowControl = USART_HardwareFlowControl_None;
USART_InitStructure.USART_Mode = USART_Mode_Rx | USART_Mode_Tx;
STM_EVAL_COMInit(COM1, &USART_InitStructure);
}
#ifdef USE_FULL_ASSERT
/**
* @brief Reports the name of the source file and the source line number
* where the assert_param error has occurred.
* @param file: pointer to the source file name
* @param line: assert_param error line source number
* @retval None
*/
void assert_failed(uint8_t* file, uint32_t line)
{
/* User can add his own implementation to report the file name and line number,
ex: printf("Wrong parameters value: file %s on line %d\r\n", file, line) */
/* Infinite loop */
while (1)
{
}
}
#endif
/**
* @}
*/
/******************* (C) COPYRIGHT 2011 STMicroelectronics *****END OF FILE****/
復制代碼
所有資料51hei提供下載:
STM32F4xx_AN3965_V1.0.0.7z
(1.07 MB, 下載次數: 60)
2019-10-11 20:56 上傳
點擊文件名下載附件
下載積分: 黑幣 -5
作者:
middin
時間:
2020-7-2 15:17
這個實例是在官方哪兒下載的
作者:
qingyemurong
時間:
2020-9-11 15:00
middin 發表于 2020-7-2 15:17
這個實例是在官方哪兒下載的
https://www.st.com/content/st_co ... =IAP-t=tools-page=1
歡迎光臨 (http://m.zg4o1577.cn/bbs/)
Powered by Discuz! X3.1
主站蜘蛛池模板:
欧美日韩国产二区
|
成人一区二区视频
|
五月婷婷丁香
|
特级西西444www大精品视频
|
一区二区三区免费在线观看
|
免费在线看黄网站
|
美女免费网站
|
www一区
|
精品久久一区
|
日韩精品网
|
午夜xxx
|
黄色大片在线
|
狠狠干在线视频
|
亚洲三级网
|
av一区二区三区
|
欧美一二
|
婷婷丁香激情
|
黄色三级免费
|
日韩在线毛片
|
亚洲高清视频在线
|
久热精品在线
|
中文一级片
|
日韩欧美在线一区
|
四虎在线观看视频
|
亚洲欧美成人
|
一区在线观看
|
黑人精品一区二区
|
91精品国产99久久久久久红楼
|
黄色免费小视频
|
激情网站在线观看
|
一区二区三区四区在线
|
99精品网
|
亚洲不卡视频
|
国产二区三区
|
少妇一级淫片免费放
|
在线观看的av
|
狠狠干夜夜操
|
国产成人亚洲精品自产在线
|
黄色成人在线观看
|
欧美黄色一级视频
|
国产视频一区在线播放
|