cancel
Showing results for 
Search instead for 
Did you mean: 

CubeMX and STM32L-Discovery

alex_raven
Associate II
Posted on January 14, 2016 at 20:21

Hi. I'am developer from Russia. And, i have a problem. I generate project in CubeMX with Virtual Com Port (USB 2.0) and upload it in my device (STM32L-Discovery board with STM32L152RBT6). When i connect USB cable (Power from USB bus, cable from ST-Link disconnected), i have a message from Windows: ''device not recognized''. But, i have a test project from the internet, it's not working, but device is recognized. Whats wrong with project? HSE working from ST-Link resonator (I connect SB17 bridge)

This is my parameters:

0690X00000602aoQAA.jpg0690X00000602atQAA.jpg
5 REPLIES 5
Posted on January 15, 2016 at 11:52

Hi raven.alex,

''Power from USB bus, cable from ST-Link disconnected''

How the board is powered if ST-Link is disconnected?How are you connecting the USB port?

-Shahrzad-
alex_raven
Associate II
Posted on January 15, 2016 at 14:15

Very simple, i got usb cable with connectors, and connect it to board. 

I just generate project in CubeMX, and upload it on board. Device must be recognized, right? But, if i use project from the interned (Found it in 

http://myrobot.ru/forum/topic.php?forum=3&topic=501

), it recognized, but i can't send and recieve data, and i dont know why. I think about new library (HAL), and yesterday, itry it, but, it's not working. Maybe i'am a stupid?)

USB 

 

BOARD

DESCRIPTION 

 RED  EXT_5V  This is 5 volt from USB port

 BLACK  GND  This is GND from USB port

 WHITE  PA11  This is DATA- from USB

 GREEN  PA12  This is DATA+ from USB

For more details, i attached archive with the photos

0690X00000602ayQAA.jpg

0690X00000602auQAA.jpg

0690X00000602b3QAA.jpg

0690X00000602YAQAY.jpg

Posted on January 15, 2016 at 17:28

Hi raven.alex,

Did you select the Communication Device Class of USB Device in the pinout view? Give us your *.ioc.

Try to program your board with the example under STM32Cube_FW_L1_V1.4.0\Projects\STM32L152D_EVAL\Applications\USB_Device\CDC_Standalone with taking into account specificity of your discovery board.

0690X00000604tdQAA.png

-Shahrzad-

alex_raven
Associate II
Posted on January 15, 2016 at 17:52

Of course i did. I can't attach file. Errors) I upload ioc files with the old project, from forum, wich worked) Almost worked) It's recognized in Windows.

My files: 

https://dropmefiles.com/FTDSU

alex_raven
Associate II
Posted on January 17, 2016 at 00:47

i try to program my board with the example STM32L152D_EVAL, but i can't find, where USB pins are configure.