Skip to main content
Graduate
May 6, 2024
Question

USB host or usb cdc or UART

  • May 6, 2024
  • 4 replies
  • 5591 views

In my graduation project, I'm utilizing the STM32H735_DK microcontroller to communicate with a GMSL (Generalized Memory Scalable Logic) device. Typically, these devices are configured using terminal programs like Putty or TeraTerm. Commands, such as "PICT START," are sent via a USB A to USB B cable from a PC to the GMSL.

 

sana1_0-1715029002465.pngsana1_1-1715029034646.png

 

sana1_2-1715029194638.png

 

Despite my attempts to replicate this communication using UART and USB CDC with the STM32, I've encountered difficulties. Conversely, my friend successfully communicated with a GMSL device using a Raspberry Pi via a serial port.

sana1_3-1715029876065.png

 

I'm unsure how to resolve these issues and would appreciate any assistance. Thank you!

    This topic has been closed for replies.

    4 replies

    Graduate II
    May 6, 2024

    The DISCO' ST-LINK provides for a COM port CDC connection which terminates on the STM32H735 as a UART, this is perhaps the easiest to deal with.

    You could use a USB CDC Device implementation on the H735 via one of it's own USB interfaces. This is somewhat more complicated as the STM32 must run it's USB processing loop, and if you want to do other things concurrently you're either going to need to use an RTOS, or create your own stateful implementation that can run briefly, and come back later, or periodically pump the USB task/work.

    Mess that up and the host is going to stall the USB transactions.

    The RPi has an OS, you don't.

    You need to implement a subset of that functionality or timeliness required to implement USB.

    You won't be the first to find it challenging to move away from the linear execution model.

    sana1Author
    Graduate
    May 7, 2024

     

    thank u for ur answer , i try to work with uart and usb  cdc but it dosen't work 

    Graduate II
    May 7, 2024

    Unfortunately "doesn't work" is very difficult to debug.

    Show the UART code, show the wiring.

    How is this GMSL device connected to the STM32H735-DK

    You're going to have to explain this a whole lot better for people to remotely debug what on earth you're doing.

    Can your friend explain how he did it to you? Or to us?

    Does the GMSL connect via USB? Is there any other way to connect it?

    For the H735 to connect that way you'd need a USB HOST driver

     

    Super User
    May 7, 2024

    @sana1 wrote:

    a GMSL (Generalized Memory Scalable Logic) device. 


    Not finding any hits for that.

    But many for "GMSL" as "Gigabit Multimedia Serial Link" - is that what you mean?

    Technical Moderator
    May 8, 2024

    Hi @sana1 

     

    The following FAQ may help you on How to write your question to maximize your chance... - STMicroelectronics Community

    You need to provide details on how you establish communication between the GMSL device and at least using your raspberry? Attach the datasheet of GMSIL device. Unfortunately, pictures attached does not explain your hardware setup. Knowing the connector cannot allow us to predict the protocol used.

    Thank you for your understanding.