2017-05-19 02:26 AM
I have a board with a STM32f070f6 which won't show up as communication device class on the usb port.
I tried to make it work without activating the usb and the LED blinks just fine (programing via usb/dfu file which indicates to me that the oscillator must be working?).
What I have done:
Connect 8MHz 3.3V CMOS oscilator:
https://www.digikey.com/product-detail/en/abracon-llc/ASEMB-8.000MHZ-XY-T/535-11138-1-ND/2624381
with a short trace to the PF0 pin and set the PF0 pin to High Speed Bypass input. PF1 is greyed out which I assume means high-impeadance state(?)
I checked the oscillator and the square wave is stable to about +/-5ppm, has 50% duty cycle, starts up after about 1ms and goes from 0V to 3.3V in it's high state with some ringing which should be well inside the 0.2* and 0.8*VDD specs given for the STM32f0. I do not see anything wrong here (see oscilloscope screenshots and settings files).
The heap and stack size was also increased to 0x400 and 0x800 since this caused some problems before.
I would be glad if somebody would have a suggestion of what to try?
#vcp #stm32 #dfu #usb2017-05-22 08:45 AM
Found the solution. It's a silly StmCube bug.
The problem was that the CubeMX is generating the following line
RCC_OscInitStruct.OscillatorType = RCC_OSCILLATORTYPE_HSI|RCC_OSCILLATORTYPE_HSE;
Just remove:
RCC_OSCILLATORTYPE_HSI
from the statement and run the code without it. Works for me.
2017-05-22 04:21 PM
Hi
Kellermann.Andreas
,I think you are you using old STM32CubeMx version 4.
https://community.st.com/0D50X00009XkiKFSAZ
https://community.st.com/0D50X00009XkY1PSAV
You should update the new version of CubeMx which contains enhancement and limitations fixes.
Thanks
Imen