2017-11-15 04:20 AM
Hello Community,
currently i'm starting development with Nucleo-H743ZI. I'm using STM32CubeMX V4.22.1 and
Atollic True Studio V8.0.0 on Win10.I'm creating a new CubeMX project. Under Board Selector i'm selecting the Nucleo144NUCLEO-H743ZI as target.1. First i fixed pinning in the Pinout Tab.
Under USB_OTG_FS i do the following settings:- Mode: Device Only- Activate_VBUS: VBUS sensing- Activate SOF: YesUnder SYS:- Debug: Trace Asynchronous SWUnder RCC:- HSE: Crystal/Ceramic Resonator- LSE: Crystal/Ceramic ResonatorUnder MiddleWares:- Class for FS IP: CDC (VCP)2. Second i go to Clock Configuration:
- Setting HSE Input Frequency to 8MHz- PLL Source Mux: PLL source is HSE- PLL1: DIVM1=4; DIVN1=400; DIVP1=2- System Clock Mux: switch to PLLCLK (on SYSCLK appears 400MHz)- Prescaler for core/peripherals: D1CPRE=1; D1HPRE=2; HPRE=2; D1PPRE=2; D2PPRE1=2; D2PPRE2=2; D3PPRE=2- PLL3: DIVM3 = 4; DIVN3 = 192; DIVQ=8 (right to DIVQ3 48MHz appears)- USB Clock Mux: select PLL3Q (on clock to USB 48MHz appears)3. Go to the Configuration Tab:
A. Under Connectivity switch to USB_FS to open dialog:I'm using the following Parameter Settings:- Speed: FS 12MBit/s- EP0 Max Packet size: 64Bytes- internal IP DMA: Disable- Low Power: Disable- Battery Charging: Disable- Link Power Management: Disable- Use dedicated EP0 interrupt: Disable- VBUS sensing: Enabled- Signal start of frame: EnabledNVIC Settings:- USB OTG FS EP1 OUT Global Interrupt: Disable- USB OTG FS EP1 In Global Interrupt: Disable- USB OTG FS Global Interrupt: Enabled (by default)GPIO Settings:- leave unchangedB. Under System BDMA:- leave unchangedC. Under System CORTEX_M7:- CPU ICache: Enabled- CPU DCache: Enabled- MPU: MPU NOT USEDD. Under System DMA:- leave unchangedE. Under System GPIO:- leave unchangedF. Under System MDMA:- leave unchangedG. Under System NVIC:- leave unchangedH. Under System RCC:- leave unchanged except of:- Flash Latency(WS): 7 WS (8 CPU cycles)I. Under Middleware USB_DEVICE:Parameter Settings:- USBD_MAX_NUM_INTERFACES = 1- USBD_MAX_NUM_CONFIGURATION = 1- USBD_MAX_STR_DESC_SIZ = 512Byte- USBD_SUPPORT_USER_STRING: Disable- USBD_SELF_POWERED: Enabled- USBD_DEBUG_LEVEL: 0: No debug messages- USB CDC Rx Buffer Size: 2048Bytes- USB CDC Tx Buffer Size: 2048BytesDevice Descriptor FS:- PID: 22336- PRODUCT_STRING: STM32 Virtual ComPort- SERIALNUMBER_STRING: 1A- CONFIGURATION_STRING: CDC Config- INTERFACE_STRING: CDC Interface4. Go to CubeMX Project Tab, change Project Settings:
In Tab Project:- Project Name: select a project name- Project Location: set Path to Project- IDE: TrueSTUDIO- Under Firmware Package Name and Version appears: 'STM32Cube FW_H7 V1.1.0'Tab Code Generator:- leave all unchangedTab Advanced Settings:- leave all unchanged5. Go to CubeMX Project Tab: Press Generate Code...
6. Switch to AtollicTrue Studio:
- Import Project- Compile Project- Select Tab RUN->Debug (Debugger starts)- Run the project...7. Open Windows Device Manager Tree:
Looking under communications (COM&LPT) and waiting to a new STMicro VCP appears...Nothing happens!!! No new connection (USB/VCP) appears...To find the problem i try the following:
1. Check PLL: route SYSCLK to MCO2, use Oszi to verify: i can verify a square wave signalon the Oszi with same frequency as displayed in CubeMX clock configuration tool MCO2 info box.2. Check the USB cabels: I change the USB cable. Same effect. Nothing appears in Windows Device Manager.3. I use Win10 (Maybe the Problem???): Change to a Windows 7 Laptop. Plug the flashed Nucleo inthe USB ports (STLink for Powering, 2nd Micro-USB to H7-USB-FS-Port). Same effect.Nothing appears in Windows Device Manager.So now i decided to change the platform:
1. Go back to Win10. Take a Nucleo-F767ZI. Create a CubeMX Project. Do the same steps as above but parametersslightly adapted to F767. Use FW package 'STM32Cube FW_F7 V1.8.0' and create an Atollic True Studio Project.Plug the board onto the USB ports.Import the project in Atollic True Studio.Compile and run. And SUCCESS: A new serial port appears in the Windows Device Manager (named USB Serial Device).So now i ask myself, what is the problem with the H743-Nucleo?
I think cables are not the problem. The Micro-USB port connectors on both Nucleos seems to be the same.Also not Win10 (because F767 works).I have studied the STM32H743xI errata too but found nothing that could cause the problem.Maybe there is somebody out there, who can advice me? Any remarks?
Regards
TorstenUpdate: I found what i'm looking for and solve the problem...
#stm32cube_fw_h7_v1.0.0 #stm32h743 #nucleo-h743 #usb-fs #cubemx-4.222017-11-15 06:59 AM
Hello
torsten.aurich
,Good to know that your problem is fixed.
It would be grateful to share the solution, this will be
helpful for other users on our STM32 forum facing the same kind of issues.
Best Regards
Imen
2017-11-16 12:24 AM
Hello Imen,
Of course I like doing that. The solution can be found in the post:
https://community.st.com/0D50X00009XkYZLSA3
Regards
Torsten
2017-11-16 07:10 AM
Hi,
Thank you for sharing the post and solution.
I reported this issue to the appropriate team for investigation.
Best Regards
Imen
2017-11-28 11:53 PM
May be you know how to resolve, I worked with nucleo144 board (stm32f767) and I had some problem. Windows define board how unkown usb device. But Keil debuger stopped in irq handler 'void OTG_FS_IRQHandler(void)'. May be I dont`t initialize any option.
2018-11-19 09:12 AM
@Torsten Aurich So, what was your discovery? I have a similar problem of USB/VCP not working at all with example project derived code, which I'm struggling with for a month now.
2018-11-19 10:55 AM
This problem is solved here.
https://community.st.com/s/question/0D50X00009XkYZLSA3/stm32h7-nucleo-usb-fs-cdc
Gene
2018-11-19 07:08 PM
@ETone Thanks for the info, but the call already exists in my code ...
I have filed a new Q&A.