Developer support experience survey - We value your feedback
Ask questions and find answers on STM32Cube packages, including HAL, LL and middleware, and expansion software.
Most recent activity
Hi, I have set ADC + DMA in H743, I reuse code that work in products every days but today a strange beauvoir happened, ADC work only in debug mode, somebody know this issue?thanks friends.
I have a timer with an interrupt every 1ms to create time stamps for my later algorithm developement. I flag for the adc to sample once every 5 seconds, but I see that the ADC bleeds over or it changes multiple times before stopping. Is there anyway to stop this? I only want one sample. Is APB1 Timer clocks or APB1 peripheral clocks the clock that determines the speed of my timer? I am counting internally, I want to scale and set up count accordingly to get an interrupt every 1 ms. I would very much appreciate an explanation as I am new.
Hello Guys!I'm using STM32F746 NUCLEO board for USB Bootloader application. And I'm using CubeMx 6.9.2 for configuring USB device. when I'm connecting my USB device on CN13 connector and monitoring the Application State in debug ... so its always Staying at APPLICATION_START, Not Changing to APPLICATION_READY state.I got one article on ST Community in that they suggested to use USB host library V3.5.0 and I tried this library but still its not working. USB_OTG_FS Settings:USB_HOST Mode Settings:FATFS Mode Settings:Anyone Knows any thing about it please reply.
We want to be able to set the RDP bytes to level 1 (read protect, but fallback allowed) via software for production. The device in question is based on an STMF723 and will be battery powered and fully assembled at the point where this protection needs to be applied on the production line.I have the following function to set the option bytes: HAL_FLASH_Unlock(); HAL_FLASH_OB_Unlock(); watchdog_feed(); HAL_FLASHEx_OBGetConfig(&flash_init); // 0 for no lock, 1 for upgradeable lock, 2 for permanent lock flash_init.RDPLevel = OB_RDP_LEVEL_1; HAL_FLASHEx_OBProgram(&flash_init); HAL_FLASH_OB_Launch(); // the Launch function will cause a reset if it works // if we get here, it failed HAL_FLASH_OB_Lock(); HAL_FLASH_Lock()However, at the point where I "launch", the chip hangs and must be fully power cycled. At that point the read protect has worked, but this is not a possible step in production. Is there any way to set the RDP level without requiring a power cycle?
Hi,I am new to HID and have some questions regarding the ST HID Middleware package.I am using an STM32F479F as a Custom HID device. I used the example from the STM32 USB training to get everything up and running. It works.When the host (PC) performs a write, then there is a callback to the USBD_CUSTOM_HID_DataOut function. I can process the request, and when everything is finished, I would use the USBD_CUSTOM_HID_SendReport function to send the data out. Only then the callback to the USBD_CUSTOM_HID_DataIn appears to be triggered.For my understanding, I get a write from the host, process the data, and when it is done, I transfer the data out. Independently from a host read operation. Is this true?Is there a callback in the ST HID Middleware which is triggered when a host read request arrives?Thank you.
Am trying to Use of a USB to transmit data (transmit/receive) between a board and anHyperTerminal PC application. Am working with Nucleo-STM32H563 board. But i didnt get expect data in hyper terminal. Here i have attached code part . Kindly correct it/* Call PreOsInit function */USBPD_PreInitOs();/* USER CODE BEGIN 2 *//* USER CODE END 2 */MX_ThreadX_Init();/* We should never get here as control is now taken by the scheduler *//* Infinite loop *//* USER CODE BEGIN WHILE */while (1){/* USER CODE END WHILE *//* USER CODE BEGIN 3 */HAL_PCD_EP_Transmit(&hpcd_USB_DRD_FS, *data, data, 10);HAL_GPIO_TogglePin(LED_GPIO_Port, LED_Pin);HAL_Delay(1000); }/* USER CODE END 3 */} /**
I am currently working on a project that involves integrating USB functionality for data transfer and data logging on an STM32F407VG micro-controller. Specifically, I want to log data files on an SD card and enable the user to download these logged files from the SD card via USB. Additionally, I'd like to allow users to copy files from their PC to the SD card via USB, all through the STM32F407VG using the SDIO communication protocol.I'm facing a challenge in making the USB_OTG_FS (On-The-Go Full Speed USB) and the SD card (using FatFS) work together seamlessly. I would greatly appreciate your guidance and any insights you might have on how to achieve this integration.Here are some specific questions I have:How do I configure USB_OTG_FS as a USB Device in STM32CubeMX or other development tools?What are the essential initialization and setup steps for using the USB_OTG_FS as a USB Device alongside the FatFS library for SD card communication?Are there any sample code snippets or project e
Dear,I am currently in the process of designing a custom PCB with your STM32WLE5CCU6 chip (QFN Package). Consequently, I have a few questions:Given that the PCB will be exclusively sold in Europe and that I need to optimize power consumption, should my design align with the schematic provided in the attachment (MB1720-HighBand_LowPower-A01_Schematic_Internal)? I assume that due to the geographic location, I should use the High Band version. Please confirm this for me.Can we purchase your PCB with this chip (MB1720)?Can I power all peripherals with LiSOCl2 batteries recommended for LoRa applications? The rated voltage of these batteries is 3.6 V.Thank you in advance!Sincerely,Zelimir Trisic
I have merged the examples for this Discovery board LwIP_HTTP_Server_Netconn_RTOS, and STM32CubeExpansion_SBSFU_V2.6.2 (2_Images) projects. I initially had issues with multiple defines for SVC_Handler interrupt but have that resolved now and FreeRTOS is now running. The LwIP stack initializes up to the point in the low level init during netif_set_link_up() trying to do netif_issue_reports(). This thread seems to hang in HAL_ETH_Transmit_IT() when it tries to resume the DMA transmission. When I compare the Eth_handle with the running LwIP project, many of the memory pointers are different. It seems there's a difference (problem) in the DMA initialization of this merged project. Anyone have ideas on how to resolve this?
I am unable to install the STM32 device packages required by the setup of the Embedded Coder Support Package for STMicroelectronics STM32 Processors.Based on my investigation, this error seems to originate with the STM32 CubeMX software. The hardware setup steps download and setup the required software using STM32 CubeMX, and here there is an error when STM32 CubeMX does so.The Error I get from Install STM32Cube Firmware is :Installation of STM32Cube firmware failed with the following error:[ERROR] AnalyticsContext:980 - The ST intranet updater server is unknown: mcucrossselector.codex.cro.st.com[ERROR] ServerAccessManage:1058 - Problem during Server Connexion : IO error PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target[ERROR] ServerAccessManage:537 - Problem during Server Connexion : : updaters.zip.[ERROR] ServerAccessManage:1058 - Problem during Server Connexion : IO error PKIX path
I want to start the ethernet protocol with NUCLEO-H743ZI. For this I used the following tutorials :https://community.st.com/t5/stm32-mcus/how-to-create-project-for-stm32h7-with-ethernet-and-lwip-stack/ta-p/49308https://github.com/stm32-hotspot/STM32H7-LwIP-Examples/tree/v1.2_ide_v1.9.0and I was able to do the ping operation with CUBEIDE, but my main goal is to use Keil. And when I go through exactly the same steps for Keil, it doesn't get pinged.note: I found that I had to put "DEBUG" on mode "trace". When I didn't do the work, the microcontroller didn't do anything (not even flashing).CUBEMX version 6.4.0STM32CubeH7 version 1.9.0KEIL version 5.36.0.0
Hi All,I am trying to use microSD on Nucleo-144 STM32H723ZG(T6U) by using an external microSD module called "Pmod MicroSD" by digilent Pmod microSD Card Slot. The SD card I am using is this one: Trancend 4GB MicroSD . I am able to use the SD card with SPI, but struggle with SDIO (which the slot and card is supposed to support, not SDMMC).I have connected the slot as following:D0(Pin 3) to PC8, D1(Pin 7) to PC9, D2(Pin 8) to PC10, D3(Pin 1) to PC11, SCK(Pin 4) to PC12, CMD(Pin 2) to PD2+ GND - GND, and VCC - 3.3VIn STM32CubeIDE I set SDIO by choosing SDMMC1 in connectivity, then "SD 4 bits Wide bus". I make sure the pins correspond to how I have connected. Everything else is set default here.Then I choose FATFS, SD Card. Here we have one thing called Detect_SDIO: I dont know what this is, and what I need to connect there from the Pmod, or if that is needed. I need at least to choose a GPIO input, and chose it as PA3.Then I choose Automatic clock resolver. (SDMMC1 is set t
Hi Team,Recently i was using stm32 stlinkv2 in the STM32F411CEU6. They debugger was workig fine . After flashing 10-20 times , the debugger stopped working and throwig up the error:STMicroelectronics ST-LINK GDB server. Version 7.4.0Copyright (c) 2023, STMicroelectronics. All rights reserved.Starting server with the following options:Persistent Mode : DisabledLogging Level : 1Listen Port Number : 61234Status Refresh Delay : 15sVerbose Mode : DisabledSWD Debug : EnabledInitWhile : EnabledTarget no device foundError in initializing ST-LINK device.Reason: No device found on target.and a pop up notification stating as follows :__Error in final launch sequence:Failed to execute MI command:target remote localhost:61234Error message from debugger back end:localhost:61234: Connection timed out.Failed to execute MI command:target remote localhost:61234Error message from debugger back end:localhost:61234: Connection timed out.localhost:61234: Connec
Hallo!I am trying to calculate and display the temperature measurement of 2 NTC thermistor's using STM32F103RBT6. I have done the ADC conversion and hardware connections correct. I was able to get continuous values with a delay of 1 second before using input commands. Now, however the measurement and display of output in PuTTY is not continuous. I programmed the mcu to start temperature measurement when the input is '1' and stop it when input is '2'. But I have to press '1' each time to obtain a measurement , even though I used the same HAL_UART_Transmit(&huart2, (uint8_t*)buffer, strlen(buffer), HAL_MAX_DELAY) . Is it a problem in my code or can we not continously transmit data in this case?
I encountered the problem that NDM does not work at all on a processor of this model STM32G030F6 ın all versıon cubeidethis is my code /* USER CODE BEGIN Header *//** ****************************************************************************** * @file : main.c * @brief : Main program body ****************************************************************************** * @attention * * <h2><center>&copy; Copyright (c) 2023 STMicroelectronics. * All rights reserved.</center></h2> * * This software component is licensed by ST under BSD 3-Clause license, * the "License"; You may not use this file except in compliance with the * License. You may obtain a copy of the License at: * opensource.org/licenses/BSD-3-Clause *&nbs
I did pulled up pin PH3-BOOT high (3.3V). I tried simple code but it looks like it is sitting there and doing nothing. I get this error message. Most chips would have just BOOT pin one function not PH3-BOOT.Multiple errors reported.1) Failed to execute MI command:-var-create - * bError message from debugger back end:-var-create: unable to create variable object2) Unable to create variable object3) Failed to execute MI command:-data-evaluate-expression bError message from debugger back end:No symbol "b" in current context.4) Failed to execute MI command:-var-create - * bError message from debugger back end:-var-create: unable to create variable objectI do not see if I need to change anything. I wonder if it has to do anything how the chip boot up
Hi @ST Community ,I struggle to configure the clock speed to the frequency I desire.The chip I am using is STM32C011F6U and the code I use as first function in main() is the following:uint16_t cr = RCC->CR;uint16_t cal = RCC->ICSCR;uint16_t cfgr = RCC->CFGR;//Reset Clock divider to 1 (full 48MHz)cr &= ~(RCC_CR_HSIDIV_0 | RCC_CR_HSIDIV_1 | RCC_CR_HSIDIV_2);cr |= (1U << 11);cr |= (1U << 12);cr |= (1U << 13);RCC->CR = cr;//Enable HSI48 ClockRCC->CR |= RCC_CR_HSION;//Wait for HSI to be readywhile((RCC->CR &= RCC_CR_HSIRDY) == 0u);//Default HSI calibration trimming valuecal &= ~RCC_ICSCR_HSITRIM;cal |= RCC_ICSCR_HSITRIM_6;RCC->ICSCR = cal;//Set APB divider to 8cfgr &= ~RCC_CFGR_PPRE;cfgr |= (RCC_CFGR_PPRE_2 | RCC_CFGR_PPRE_1);RCC->CFGR = cfgr;//Set AHB divider to 1cfgr &= ~RCC_CFGR_HPRE;RCC->CFGR = cfgr; However the above doesn't seem to have any effect and the clock frequency never change. I have also tried to
Hello STMicroelectronics community,I'm currently working on a project involving the BlueNRG-2N Bluetooth Low Energy (BLE) module, and I'm looking to reduce the Bluetooth range to approximately 1 or 2 meters (means over 2 meter, I want my bluetooth server side = a BlueNRG-2N chips inside a board not detected by the client BT side = Smartphone ). The BlueNRG-2 module offers an extended range, and for my specific application, I need to limit the range to this shorter distance. After going through the BlueNRG-2 documentation and software development kit (SDK), I have identified that I should adjust the transmit power level to achieve this goal.I have already located the aci_hal_set_tx_power_level function in the SDK, which allows me to set the transmit power in dBm.I tried :aci_hal_set_tx_power_level(0, 0); // Disable high power mode and set low power levelHowever, still Bluetooth can be detected from 4 meters !!! I'm seeking further guidance and best practices on how to configure t
I am building a USBPD sink with reference to the UM2552, but in the sample code on page 16, it seems that the ")" corresponding to the IF on the 9th line has disappeared, is this a typo? Also, is there a correct example somewhere?
new to algobuilder.I want to have a float input circular buffer that then goes through an IIR filter. When I add both to algobuilder I can't seem to wire the circular buffer to the IIR filter block, presumably as the circular buffer output bus width is showing as a bus with the number of outputs as the number of elements in the circular buffer (qty 10) when the IIR is single float input.How do I extract one float from the circular buffer at an index reference point using algobuilder?
Hi, I'm using stm32l432kb and I want to use the internal reference voltage Vrefint as reference voltage for the AD converter. Is this possible?Regards
Hi , I'm a fresher who was given with testing of packet transfer with external Ethernet - Phy by interfacing STM32F439ZI with DP83848 . I need some help at API level and testing procedure .
Hi,I'm working with self designed board (STM32F765 MCU) and currently able to initialize SAI2 peripheral to work with codec in DMA mode.At some point in my code, I need to change the sample rate of my codec (through MCLK).The sequence of operations is basically as follows://1. DeInit SAIHAL_SAI_DeInit(&hsai_BlockB2); //Deinit SAI_MODEMASTER_TX block set at old AudioFrequencyHAL_SAI_DeInit(&hsai_BlockA2); //Deinit SAI_MODESLAVE_RX block//2 Init SAI with new freq. SAI_AUDIO_FREQUENCY_96Khsai_BlockA2.Instance = SAI2_Block_A;hsai_BlockA2.Init.AudioMode = SAI_MODESLAVE_RX;hsai_BlockA2.Init.Synchro = SAI_SYNCHRONOUS;hsai_BlockA2.Init.OutputDrive = SAI_OUTPUTDRIVE_DISABLE;hsai_BlockA2.Init.FIFOThreshold = SAI_FIFOTHRESHOLD_1QF;hsai_BlockA2.Init.SynchroExt = SAI_SYNCEXT_DISABLE;hsai_BlockA2.Init.MonoStereoMode = SAI_STEREOMODE;hsai_BlockA2.Init.CompandingMode = SAI_NOCOMPANDING;hsai_BlockA2.Init.TriState = SAI_OUTPUT_NOTRELEASED;if (HAL_SAI_InitProtocol(&hsai_Bl
hi, everyone! May you have a nice day! In en.stm32cubeg4_v1-5-0\STM32Cube_FW_G4_V1.5.0\Projects, core_cm4.h file. I encounter the following codes: __STATIC_INLINE void __NVIC_EnableIRQ(IRQn_Type IRQn){ if ((int32_t)(IRQn) >= 0) { __COMPILER_BARRIER(); NVIC->ISER[(((uint32_t)IRQn) >> 5UL)] = (uint32_t)(1UL << (((uint32_t)IRQn) & 0x1FUL)); __COMPILER_BARRIER(); }}So the questions are:what's the meaning of __COMPILER_BARRIER();?why it's called here, is ISERx registers related to it?could anyone share some literature on this?thank you for your attention!Best wishes!
Hii'm working on a projekt where we want to use the LoRaWAN capability's of the B-L072Z-LRWAN1 borde as well as it's adc's and dac's to do this we set up the adc/dac with cubemx but also use the example projekt from the I-CUBE-LRWAN "expansion" packso my question is, is there a smart way to include the example code in the cubemx projekt at first i thought git would be useful however the stm32cubeide projekt that gets created dose not copy the used files just linkes to them which means that one is not able to use them with git and i have not fund at way to copy them into the projekt automatically
Already have an account? Login
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.