STM32L476 Discovery USB CDC Class Source code or Example
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2017-09-04 7:24 AM
Hi,
I am using STM32L476 Discovery Board, as part of my project i need to enable USB OTG Port as CD C Class. Could some one help me in fining any example for USB OTG CDC Class for STM32L476 Discovery Board. I found an example for STM32L476 Eval board Can i use the same Application Example for Discovery Board also. Please help me out in finding the solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2017-09-04 7:49 AM
Hello,
You can port the CDC example for STM32L476G_EVAL, get inspired from this working application, change the pins and modify the example depending on your needs.You can also use the STM32CubeMX tool to initialize peripherals, build and generate your starting project.
For more details, refer to/external-link.jspa?url=http%3A%2F%2Fwww.st.com%2Fcontent%2Fccc%2Fresource%2Ftechnical%2Fdocument%2Fuser_manual%2Fcf%2F38%2Fe5%2Fb5%2Fdd%2F1d%2F4c%2F09%2FDM00108pdf%2Ffiles%2FDM00108pdf%2Fjcr%3Acontent%2Ftranslations%2Fen.DM00108pdf
that explains more the use of STM32Cube USB device library.- User manual Discovery kit with STM32L476VG MCU
- Application note Getting started with STM32L4 Series hardware development
Best Regards
Imen
Thanks
Imen
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2017-09-06 6:27 AM
Hello,
Below please find attached a presentation, which shows step by step how to develop an USB VCP example application on STM32L4 Discovery kit. In addition I attached a project (for Keil IDE), which implements USB VCP application based on steps described in presentation.
I hope it will be helpful to you.
Regards
Szymon ________________ Attachments : STM32L4 Discovery USB VCP hands on.pdf : https://st--c.eu10.content.force.com/sfc/dist/version/download/?oid=00Db0000000YtG6&ids=0680X000006HySo&d=%2Fa%2F0X0000000b83%2FruwYoZ0kJdFaq2Xl2Rl_Iv0bLLjyEDHwdv0IzPewarU&asPdf=falseUSB_VCP.zip : https://st--c.eu10.content.force.com/sfc/dist/version/download/?oid=00Db0000000YtG6&ids=0680X000006HySe&d=%2Fa%2F0X0000000b7v%2F.q1pP1RgQbDW0zXBRKXWXDP1XWigSGomqYMHymQC9H4&asPdf=false- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2019-01-28 5:35 AM
Hi, I tried following the instructions in the presentation with the latest CubeMX 5.0.1, but when I got to Generate Code it popped up a message "These IPs still have some not configured or wrong parameter values [Clock]. Do you still want to generate code ?". Is that something that can be ignored for this example ? Thanks.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2019-01-28 5:38 AM
Hi, could you clarify where the "the CDC example for STM32L476G_EVAL" can be found. I tried all the links above and got "page not found" for all. Thanks
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2019-01-28 5:45 AM
Hello,
The CDC example is available under the STM32CubeL4 firmware package (to download from ST web site or STM32CubeMx tool):
STM32Cube_FW_L4_V1.13.0\Projects\STM32L476G-EVAL\Applications\USB_Device\CDC_Standalone
Kind Regards,
Imen
Thanks
Imen
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2019-01-28 6:20 AM
Ah, I already had the STM32CubeL4 code, but i was looking under 32L476GDISCOVERY rather than under STM32L476G-EVAL. Thanks !
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2019-01-28 7:53 AM
Hi,
You have to configure the clock before generate code.
You can click on the "Resolve Clock Issues" button to resolve automatically your configuration issues .
Kind Regards,
Imen.
Thanks
Imen
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2019-01-28 8:02 PM
Hi again, so I finally got to try the Resolve Clock Issues button. After double-checking that I've set everything as specified in the "STM32L4 Discovery USB VCP hands on.pdf" that Szymon linked to, when I click Reslove Clock Issues it pops up "Cannot found a solution for some constraints".
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2019-01-31 8:26 AM
Update - When I was getting the Resolve Clock error, I had created the project by specifying the board (STM32L476 Discovery, a.k.a. STM32L4-Discovery, a.k.a. 32L476GDISCOVERY). I went back and started a new project, specifying the CPU this time (STM32L476VG) rather than the board, did all the setup, and there were no Resolve Clock errors this time. Code was generated and ran successfully on the board.
