cancel
Showing results for 
Search instead for 
Did you mean: 

Getting STM32L152C6U6A to act as an USB Device

AHett.2
Associate

Hi people and experts,

Andi speaking. I am fairly new to designing PCBs with the STM32 family and of course it didn't took me long to run into my first problems :D My latest project includes a STM32L152C6U6A. Flashing the PCB, running the first hello Word etc. was no problem so far, but getting the thing identifiying itself as an USB device seems to be impossible for me. Now I am asking kindly for your help, maybe someone of you can figure out what I did wrong. This is how I approached this so far:

SCHEMATIC

0693W00000D0nYrQAJ.png 

What is the failure:

  • When I plug in the pcb via usb, windows tells me it can't recognize the usb device due to missing information (Failure when requesting device information)

What I already tried and did not work:

  • I swapped R14 and R15 for 22 Ohms resistors and removed R7 because of the internal pull up
  • I already measured the clock, it is working as expected running with 16Mhz
  • I preconfigured the device (selected USB and USB device) and flashed the generated code. These are my settings:

 0693W00000D0natQAB.pngCLOCK CONFIGURATION

0693W00000D0nckQAB.png 

I can't really tell if this is a software or a hardware problem. Please let me know if you need any further information to help me with that problem. Any hints are highly appreciated.

Thanks a lot in advance,

Cheers Andi

Edit: BOOT0 is pulled LOW

1 ACCEPTED SOLUTION

Accepted Solutions

Hello @AHett.2​ ,

We have an Evaluation board for STM32L1 series with STM32L152VB MCU : STM32L152-EVAL - Evaluation board for STM32L1 series - with STM32L152VB MCU - STMicroelectronics

You can refer to the following link and be inspired by the USB schematic : https://www.st.com/resource/en/schematic_pack/stm32l152-eval_sch.zip

As well, for validation, you can use an example provided in our L1 Firmware package ( Path : Projects\STM32L152D-EVAL\Applications\USB_Device )

I hope this helps.

BeST Regards,

Walid

View solution in original post

1 REPLY 1

Hello @AHett.2​ ,

We have an Evaluation board for STM32L1 series with STM32L152VB MCU : STM32L152-EVAL - Evaluation board for STM32L1 series - with STM32L152VB MCU - STMicroelectronics

You can refer to the following link and be inspired by the USB schematic : https://www.st.com/resource/en/schematic_pack/stm32l152-eval_sch.zip

As well, for validation, you can use an example provided in our L1 Firmware package ( Path : Projects\STM32L152D-EVAL\Applications\USB_Device )

I hope this helps.

BeST Regards,

Walid