Developer support experience survey - We value your feedback
Join discussions in the Product Forums. Ask questions, learn from your peers, and share insights on ST solutions to accelerate your design journey.
Most recent activity
Hi, I am really struggling to get clangd to work correctly in a setup I am trying to get going. I'm new to this VSCode workflow, and am finding VSCode seems to have a lot of persnickety behaviors that really require a lot of specificity to get things working right. Here is what I am trying to do:I start with a fresh workspace, and ONLY the STM32Cube vscode extension pack installed. I add two folders to my workspace:an stm32 project folder, as created by cubeMXa shared_code folder, which contains multiple subfolders, each of which contain .c/.h files. Nothing particularly fancy here. I can get this setup compiling fine, but clangd is complaining about various #include files in my shared code area. I understand that the reason for this is because there is no .clangd file in my shared_code area, so clangd can't "see" it from my project area. Intrepid internet searching has led me to adding this to my code-workspace file:{ "folders": [ { "name": "stm32_project", "pa
Hi,I have three small suggestions to improve the CMake build system generated by STM32CubeMX to be used by VS Code to fix some annoyances. 1.In cmake/stm32cubemx/CMakeLists.txt, useset(TOOLCHAIN_LINK_LIBRARIES "-lm")instead ofset(TOOLCHAIN_LINK_LIBRARIES "m")This way CMake knows that the "m" library is an external one. When the user setsset(CMAKE_LINK_LIBRARIES_ONLY_TARGETS ON)in the "CMakeLists.txt" in order to help finding issues in complex project setups, the old behaviour causes a CMake error as there is no explicit "m" target, but with "-lm" CMake is happy. Being able to use "CMAKE_LINK_LIBRARIES_ONLY_TARGETS" is desirable as it helps finding typos easily when many targets/components are defined across many individual CMake files.2.In cmake/stm32cubemx/CMakeLists.txt, usetarget_link_libraries(${CMAKE_PROJECT_NAME} PRIVATE ${MX_LINK_LIBS})instead oftarget_link_libraries(${CMAKE_PROJECT_NAME} ${MX_LINK_LIBS})i.e. use the explicit syntax. When the user wants to refer to addition
Hello,I used vscode with st externsion Ver3.6.4. One day, suddenly, VSCode started showing many red lines and warnings, including "main.h" source file is not valid UTF-8 clang (invalid_utf8).the file looks like:and many other redlines, because of clangd.how can fix it? it makes file very ugly, evenif it can be compiled no error.Thanks.
Hi, please can someone help me?when I try to deploy I get the following error:Spoiler (Highlight to read)PayloadTooLargeError: request entity too largeat readStream (C:\Users\diego.mavillonio\AppData\Local\STM32CubeMonitor\resources\app\node_modules\raw-body\index.js:163:17)at getRawBody (C:\Users\diego.mavillonio\AppData\Local\STM32CubeMonitor\resources\app\node_modules\raw-body\index.js:116:12)at read (C:\Users\diego.mavillonio\AppData\Local\STM32CubeMonitor\resources\app\node_modules\body-parser\lib\read.js:79:3)at jsonParser (C:\Users\diego.mavillonio\AppData\Local\STM32CubeMonitor\resources\app\node_modules\body-parser\lib\types\json.js:138:5)at Layer.handle [as handle_request] (C:\Users\diego.mavillonio\AppData\Local\STM32CubeMonitor\resources\app\node_modules\express\lib\router\layer.js:95:5)at trim_prefix (C:\Users\diego.mavillonio\AppData\Local\STM32CubeMonitor\resources\app\node_modules\express\lib\router\index.js:328:13)at C:\Users\diego.mavillonio\AppData\Local\STM32CubeMon
Is there an option in the STM32CubeIDE settings to reset to factory settings or something like “Default Settings”?I can’t restore the console window to its original state. When I compile the code, the console window used to appear at the bottom, but now it doesn’t show up anymore.
Hello,I recently bought the newly released development kit STM32N6570-DK that includes a touch screen and a MIPI camera manufactured by ST. It comes preprogrammed with some nifty demos, including the AI demo which should show off the AI capabilities with a stream from the included camera. When I load the AI demo the screen freezes up, and I can see the backlight to the screen turn off.Additionally I noticed there are some level shifters (TR1 on the camera module) on the PCB for the camera that either carry a clock or data line for MIPI. When I activate the demo the 3.3V line starts toggling at about 160MHz for about 2ms, and then stays low after that.For reference, I am powering the dev kit off of a USB 3.0 port on my laptop.Could you help me identify if this is a camera module, dev kit, power, or cable issue?Thanks,-Alex
IDE hangs after collapsing ( minimizing window) and expanding (maximizing). Or after Alt + Tab. From time to time."File -> Restart" only helps.I don't know how to fix this. Please, help.Tried to reinstall - the same situation. IDE uses internal Java: java.version=17.0.11As system Java versions, I have v.18, 21, 22 (checked via "update-alternatives --config java" command) Just have an idea to try to switch from internal to system version of Java, but did not find how it can be done. My config:Laptop Dell Vostro 3520Ubuntu 22.04.4
Hi, I am using 2 FDCAN ports on my custom board with STM32G0B1x MCU. As per application note AN5348, I can set message RAM offset for second port. But I don't see this setting in STM32Cube MX. As per reference manual, I got following details: But I am not sure where to set start and end addresses. Please help. Thanks, Pradeep
Hi, the current STM32CubeIDE for Visual Studio Code 3.6.4. (and maybe before) "Create empty project" generates in CMakeLists.txt # Core MCU flags, CPU type, instruction set and FPU setup set(cpu_PARAMS # Other parameters # -mthumb # -mcpu, -mfloat, -mfloat-abi, ... )The comments are misleading, because in cmake\vscode_generated.cmake:set(cpu_PARAMS ${cpu_PARAMS} ${CPU_FLAGS})and therefore, my cpu_PARAMS will be combined with the CPU_FLAGS which already include -mcpu etc.which effectively overwrites my settings.hthKnarfB
Hello Community,I have been working on a BLE project in which the server needs to send notification of a characteristics that is up to 512 bytes long. As in previous CubeMX versions (6.12 and before), I was expecting CubeMX to generate the function Custom_<CHAR_NAME>_Send_Notification() within custom_app.c to properly call aci_gatt_update_char_value_ext(), which indeed supports chars up to 512 (see code below).However, this is no longer the case from Ver. 6.13 onwards. Instead, CubeMX now generates only functions based on aci_gatt_update_char_value(), which handles lengths lesser than the limit (BLE_CMD_MAX_PARAM_LEN - 6), which is 243 maximum. Needless to say, my project no longer works without the proper notification function.ST Support said that the latest CubeMX behavior is "normal", but it did not explain why the code generation was changed, and most importantly how to handle long characteristics in the latest examples and documentati
Hello, I have a problem that I am having a hard time figuring out.My project is using an STM32H743 as a USB host on a custom PCB. Both OTG_HS and OTG_FS ports are connected to different devices. OTG_HS is using the internal PHY and operating at full-speed. An LTE modem located on the same PCB is connected to the OTG_HS port, and a CP2105 located on a separate PCB is connected to the OTG_FS port via a 10ft cable (D+ and D- wires are twisted and shielded). The CP2105 and host exchange ~1KB of data via bulk transfer every 1 second, while communication with the LTE modem is currently only during manual testing aside from enumeration. I used the USB host drivers generated by STM IDE and modified them to work with each device.The problem I'm running into occurs with the OTG_FS port. Occasionally, the communication will come to a complete halt. The URB state returns as URB_IDLE after the host tries to transmit data. Looking at the data signals, there is no data being transmitted from the host
Dear community we are pleased to announce the new release of STM32CubeIDE for VSCode Features Added active debug session reset by adding an extra button to the debug toolbar. Added device manager capability to edit connected devices' names. Added capability to break on a specific line using the runEntry attribute. Added quickReset attribute controlling debug session reset button behavior. Added serverJtagCfg attribute to specify a device in the JTAG chain by its position and IRpre-length. Added serverIncrementalFlashing attribute enabling incremental programming. Chores Updated license terms to reflect dependency updates. Forced CMake Tools to use the active folder on debug session launch. Removed support for blank characters in project names. Bug Fixes Fixed cpu_PARAMS management to correctly handle end user contributions. This thread is locked. Please start a new topic to ask your question.
Hello,First of all, I'm a newbie in STM32N6 boards, so I apologize in advance if my question is fairly basic.I am trying to deploy an application for object detection using the STM32N6570-DK.I am following the "Object Detection STM32N6 Model Deployment" tutorial from stm32ai-modelzoo-services/object_detection/docs/README_DEPLOYMENT_STM32N6.md at main · STMicroelectronics/stm32ai-modelzoo-services · GitHub.In my case, for testing I am trying to deploy the "yolov8n_256_quant_pc_uf_od_coco-person-st_tflite" file as the object detection model in combination with the Python script "st32ai_main.py". I planned to use my own YOLOv8-based object detector with other classes, but first I tried with an available tflite yolov8 model from ST and Ultralytics.Running the script I get the following output:(st_zoo) PS C:\Users\andres\Desktop\stm32ai-modelzoo-services\object_detection> python stm32ai_main.py --config-path ./src/config_file_examples/ --config-name deployment_n6_yolov8_config.
Hello Community,I have been working on a BLE project with one service and three characteristics, two of which have server notification properties, and I have noticed the following issue in CubeMX 6.15 (server side, custom template).The function Custom_<CHAR_NAME>_Send_Notification() is no longer auto-generated in custom_app.c if the length is greater that the limit supported by aci_gatt_update_char_value(), which is (BLE_CMD_MAX_PARAM_LEN - 6).In past CubeMX versions, any char with length greater that such limit genered of a function that internally called aci_gatt_update_char_value_ext(), which indeed supports chars up to 512:void Custom_CHAR_Send_Notification(void) /* Property Notification */ { uint8_t updateflag = 0; /* USER CODE BEGIN Data_NS_1*/ updateflag = Custom_App_Context.Data_Notification_Status; /* USER CODE END Data_NS_1*/ if (updateflag != 0) { Custom_STM_App_Update_Char_Ext(Connection_Handle, CUSTOM_STM_CHAR, (uint8_t *)NotifyCharData); }
Hi,I'm facing some issues with some STM32G474RET6s, and want to rule out counterfeit chips, even if that seems unlikely.After googling for some solutions, I confirmed the AP IDR register and the DBGMCU_IDCODE both hold a revision ID of 3, which I expected from the X code on the label. However, I noticed that the markings on the chip match the LQFP80 footprint, rather than the LQFP64 we purchased.I have read the qualifications about how device markings can differ, but it doesn't hurt to ask: is this outdated documentation, or is there a possible issue?Thanks.
Hi, When I create a new project on STM32CubeMX, it either freezes when I try to set up some peripherals, or I just get a blank screen when I try to reopen the porject after generating the code. I have tried rolling back to an older version, completely reinstalling, tried it on an ubuntu VM, switched devices, but nothing worked. kind regards, Sam
hello , i have an issue regarding stvp . before i used stvp on windows 7 and everything was working fine , but now i made an upgrade on windows 10 and it stops working. the error is ,,Cannot comunicate with the device .Check the swim cable .....'' If i try to program option bytes and verify them , it doesn t work , so in order to work i have to do it separately , and work only from second attempt. i have instaled the latest driver from st ,STSW-LINK009 and st_toolset pack 42 . what can i do to make it work like on windows 7?
Dear all, i have a problem with my custom board based on STM32H745.I need to use core M4 with USB_HS host with mass storage class (a pen drive) at 12Mbit full speed (internal Phy transceiver).I have configured the processor as per attached file (core M4, FatFS, USB host, 48MHz RC clock for USB).The problem is that the FATFS Applistate variable is always in "application start" and never became "application ready". So that USB pen drive can not be mounted.Previously, I succeded in use the FATFS pack with the same functions configured with core M7, but I want to use core M4 because I need it in my project architecture.Consider that with the same FATFS pack I'm able to use SD card on the M4 core.I can't figure why I'm not able to migrate the USB HS host from M7 to M4.See also attached the function where the USB Host should be recognized and configured to receive data (in my project microSD card store datas and I want to download it to pen drive)
Due to more performance requirement, i wanted to change the ThreadX timebase to 1ms. To what i have researched till now i need to make the following #define TX_TIMER_TICKS_PER_SECOND to 1000 which is usually set at 100 which is 10ms. Any idea what else need to be done to make the ThreadX timebase to 1ms other than this or is this enough already?Thanks a lot for guidance.
Hy,I try to configure MCO2 as adjustable clock out. For evaluation I use STM32N6 DK and STM32CubeMX 6.16.0 and STMCubeIDE 2.0.0I use all different settings and it works fine, but IC20 div setting has no effect. When I compare generated code, I see no difference, no matter what setting I put in IC20 div, neither changes the clock output frequency. RegardsHarald
Post edited by ST moderator to be inline with the community rules for the code sharing. In next time please use </> button to paste your code and a linker script content. Please read this post: How to insert source code. Hi,I was trying to use multiple ADCs in stm32f103c8t6. I have configured seven channels in ADC1 using DMA and ADC2 as single channel without DMA. Both trigger interrupts where ADC2 has the highest priority. The sampling time for the seven channels of ADC1 and single channel of ADC2 is 41.5 cycles and 239.5 cycles respectively. The ADC clock frequency is 10.667MHz. I calculate that ADC1 interrupt is triggered every 35.4us and ADC2 interrupt is triggered every 23.6us. System clock is 64Mhz. I have a third Interrupt which is a timer interrupt which is triggered every 560us. So the problem now is that when the sampling time of ADC2 is reduced 71.5 cycles (approx 8 us) or below, only the ADC2 is getting triggered. The code is not triggering the ADC1 interrup
Hi, So i am using STM32CubeIDE to program my STM32 card, except that when i create my project, it doesnt generate an MX file. So when i try to include the library "stm32fxxx_hal.h", it doesn't work. Why is that? And am I obliged to work with STM32CubeMX in parallel with STM32CubeIDE?PS : I use the latest version of the software, and my card is an stm32f303RET6.Thank you.
Launched STM32CubeProgrammer v2.20.0 after a long time since last use - it prompts an update available via an icon button.Clicked the icon, clicked Next, ticked a box, clicked "install Now", it starts download ing a big file...When the file has finished downloading it then displays an error message - see attached screenshot.Unable to unzip file: /home.main/.STM32CubeProgrammer/downloads//STM32CubeProgrammer2.21.0_linux64.zipNote the double slash // in the path.Also tried launching it direct from a terminal prompt out of my /opt folder.... same result.
Hi everyone,I am using a STM32H563RG and I need the RTC to work even if the VDD is powered off. To do that, I am plugging a battery on the VBAT pin to power the RTC and the Backup domain. But I tested it and it seems the RTC is stopped and the backup domain is cleared when VDD is powered off.Here is my initialisation code :/* Configure the system clock */ SystemClock_Config(); /* USER CODE BEGIN SysInit */ /* USER CODE END SysInit */ /* Initialize all configured peripherals */ MX_GPIO_Init(); MX_GPDMA1_Init(); MX_ICACHE_Init(); MX_CRC_Init(); MX_SPI1_Init(); MX_TIM3_Init(); //MX_RTC_Init(); MX_ADC1_Init(); MX_ADC2_Init(); MX_TIM2_Init(); MX_FileX_Init(); MX_IWDG_Init(); MX_TouchGFX_Init(); /* USER CODE BEGIN 2 */ LL_PWR_EnableBkUpRegulator(); LL_PWR_EnableBkUpAccess(); if(LL_RTC_BKP_GetRegister(RTC,LL_RTC_BKP_DR0) == 0x32F2){ //Read Backup register to see if it was previously written RTC_Datas.RTC_initialized = 1; //Set flag GPIO_Set(Led_orang); //Turn Orange LED On }
I am working on an STM32 + Azure RTOS project where I need to access the same SD card in two different modes: When the microcontroller accesses the SD card directly, I use FileX with an SDIO/SPI driver. When the SD card is connected to a PC via USB, I use USB MSC (Mass Storage Class) so that the PC can read/write the card. Individually, both functions work perfectly: FileX can read/write SD card when MCU is accessing itUSB MSC works when PC is connected However, when I try to support both modes simultaneously, the SD card fails to work correctly.There is no reference example from ST or Microsoft showing how to share the SD card between FileX and USB MSC at runtime. My main question: How can I properly share the same SD card between FileX (MCU access) and USB MSC (PC access) in Azure RTOS, ensuring that both do not access the file system at the same time? Is there an official method, mutex mechanism, media lock, or recommended design pattern for this scenario?
Already have an account? Login
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.