stm32f4

Is there a trade-off for memory to memory DMA transfer when the data size is small?

孤者浪人 提交于 2020-05-16 03:16:24
问题 As my understanding and research, I know that if the data size is small (that is, the device uses DMA to generate or consume a small amount of data), the overhead is increased because DMA transfer requires the DMA controller to perform operations, thereby unnecessarily increasing system cost. Is that correct and is there any more description to my question? 回答1: As @Vinci and @P__J__ already pointed out, A DMA controller works autonomously and doesn't create overhead on the CPU it supplements

ERROR_DOWNLOAD_TASK_START_ISSUE on System Workbench STM32 Eclipse

大憨熊 提交于 2020-02-06 08:08:36
问题 Trying to start a new project for STM32F446RE board for blinking LED. There is an error which restricts me from downloading the firmware. I tried downloading the firmware from STM website and pasting in SystemWorkbench Firmware folder in AppData . 回答1: One can download the zip file at http://www.ebuc23.com/s5/ac6/software/firmware/stm32f4_dsp_stdperiph_lib_v180.zip and paste the Zip file and the extracted file in C:\Users\User_Name\AppData\Roaming\Ac6\SW4STM32\firmwares and reopen Eclipse and

ERROR_DOWNLOAD_TASK_START_ISSUE on System Workbench STM32 Eclipse

北慕城南 提交于 2020-02-06 08:06:08
问题 Trying to start a new project for STM32F446RE board for blinking LED. There is an error which restricts me from downloading the firmware. I tried downloading the firmware from STM website and pasting in SystemWorkbench Firmware folder in AppData . 回答1: One can download the zip file at http://www.ebuc23.com/s5/ac6/software/firmware/stm32f4_dsp_stdperiph_lib_v180.zip and paste the Zip file and the extracted file in C:\Users\User_Name\AppData\Roaming\Ac6\SW4STM32\firmwares and reopen Eclipse and

How do I use the STM32CUBEF4 HAL library to read out the sensor data with i2c?

家住魔仙堡 提交于 2020-01-12 08:26:15
问题 I want to use the latest HAL library instead of Standard Peripheral Library. And i want to readout the BMA250E G-sensor's chip_id, but it doesn't work. Value of aRxBuffer always keep at 0x00. But it should be 0xf9! What's wrong in my code? ‪#‎include‬ "stm32f4xx_hal.h" #define I2Cx_SDA_GPIO_CLK_ENABLE() __HAL_RCC_GPIOB_CLK_ENABLE() #define I2Cx_SDA_PIN GPIO_PIN_9 #define I2Cx_SDA_GPIO_PORT GPIOB #define I2Cx_SDA_AF GPIO_AF4_I2C1 #define I2Cx_SCL_GPIO_CLK_ENABLE() __HAL_RCC_GPIOB_CLK_ENABLE()

How do I use the STM32CUBEF4 HAL library to read out the sensor data with i2c?

岁酱吖の 提交于 2020-01-12 08:26:13
问题 I want to use the latest HAL library instead of Standard Peripheral Library. And i want to readout the BMA250E G-sensor's chip_id, but it doesn't work. Value of aRxBuffer always keep at 0x00. But it should be 0xf9! What's wrong in my code? ‪#‎include‬ "stm32f4xx_hal.h" #define I2Cx_SDA_GPIO_CLK_ENABLE() __HAL_RCC_GPIOB_CLK_ENABLE() #define I2Cx_SDA_PIN GPIO_PIN_9 #define I2Cx_SDA_GPIO_PORT GPIOB #define I2Cx_SDA_AF GPIO_AF4_I2C1 #define I2Cx_SCL_GPIO_CLK_ENABLE() __HAL_RCC_GPIOB_CLK_ENABLE()

Why USART2 Send a Garbage Value?

两盒软妹~` 提交于 2020-01-07 08:28:13
问题 Hello i'm using stm32f103c8 and i'm trying to use usart2 but it does not work . when i'm using USART1 with the same configuration of USART2 it works with me well . but USART2 send garbage to the PC terminal can someone help me to solve the problem in the USART2 ? This is the configuration of USART2 : int main(void){ RCC_VidInit(); //INTIALIZE EXTERNAL CRYSTAL OSCILATOR = 8 MHZ RCC_VidEnablePeripheralClock( APB2_BUS , 2 ); //ENABLE CLOCK OF GPIOA CLR_BIT( GPIOA->CRL , 8 ); SET_BIT( GPIOA->CRL

What are weak functions and what are their uses? I am using a stm32f429 micro controller

我的梦境 提交于 2020-01-01 21:58:06
问题 Wikipedia says: A weak symbol denotes a specially annotated symbol during linking of Executable and Linkable Format (ELF) object files. By default, without any annotation, a symbol in an object file is strong. During linking, a strong symbol can override a weak symbol of the same name. In contrast, two strong symbols that share a name yield a link error during link-time. When linking a binary executable, a weakly declared symbol does not need a definition. In comparison, (by default) a

Why USART transmits incorrect data as the APB1 frequency changes. (RCC <= 21MHz)

两盒软妹~` 提交于 2019-12-24 19:15:35
问题 I want to use the USART communication protocol in my project. Communication is provided but incorrect data is sent (STM> PC). I'd try: Boundrade bands are the same. Suitable combinations of PLL Source Mux (HSI-HSE) and System Clock Mux (HSI-HSE-PLLCLK) were tested. Available: HSE and PLLCLK APB1 Clock frequency was changed within the allowed range. It was observed that the data obtained at each change also changed. Sometimes STM sent very fast data. The STM card was fed from a different

How to write/read to FLASH on STM32F4, Cortex M4

末鹿安然 提交于 2019-12-17 16:23:52
问题 I want to write a variable, for example an integer with the number 5 to the FLASH and then after the power goes away and the device is turned on again read it. I already know that in order to write something I first need to erase the page and then write. In the manual it says: Write OPTKEY1 = 0x0819 2A3B in the Flash option key register (FLASH_OPTKEYR) Write OPTKEY2 = 0x4C5D 6E7F in the Flash option key register (FLASH_OPTKEYR) How do I perform this tasks? Sector 0 has a Block adress from

Repeat an instruction a certain number of times without a “loop”?

时光总嘲笑我的痴心妄想 提交于 2019-12-10 11:50:00
问题 I've used PICs before and now I'm using with STM32F415. On a time-critical part of my code I need to put a very exact delay to adjust the period of the DAC-DMA that are working together to create a periodic analog signal. The delay I want to add goes from 0 to 63 clock cycles (If I were able to do 10-63 clock cycles it would be OK aswell). In PIC24F assembly, there's the instruction "REPEAT" which allows me to repeat the next instruction a certain number of times. That would work great for me