Loading...
 

SW4STM32 and SW4Linux fully supports the STM32MP1 asymmetric multicore Cortex/A7+M4 MPUs

   With System Workbench for Linux, Embedded Linux on the STM32MP1 family of MPUs from ST was never as simple to build and maintain, even for newcomers in the Linux world. And, if you install System Workbench for Linux in System Workbench for STM32 you can seamlessly develop and debug asymmetric applications running partly on Linux, partly on the Cortex-M4.
You can get more information from the ac6-tools website and download (registration required) various documents highlighting:

System Workbench for STM32


USB CDC Host demo (FS or HS) STM32F7 Discovery

Well, i had found an example for an USB-CDC HAL based upon STm32F746 Disco board. This project is more complex, but i assume that you know how the USB-Support routines needs to be handled.
you need to download the “STM32_USB_Device_Library” sources and enable the HAL support for the USB.
Both are available by CubeMX and could be preconfigured for just a test. The attached File SRC.ZIP are the main fsource files that requires the both source codes from st. It uses the HS-USB port of the STM32F7 Disco board.
I assume this could be used on the other F7 Nucleos too, but i had not done them as now.
The packed source files are snipps - this is not an entire project. This shoudl explain how the interface needs to be handled.
If everythings is working fine, a COM device must be available in teh device manager of Windows 10, without installing a driver. The speed setting of the PC program, who open the virtual serial port, is unimportant - i usualy uses 115KBit/s.
I had added some comments in german to explain the functionality. Well, just use goolge xlator.
Generaly, you need to declare a routines for HS or FS USB. You need to have an ringbuffer for incomming and outgoing characters. The USB port handles the port by using an IRQ and their ISR.
The routes working proper in a freeRTOS environment too.

MX_USB_DEVICE_Init(); // init USB CDC Device 0)
{
sprintf (cp, “Got frame of length %d: %s “, len, buf);
GUI_DispStringAt (cp, 0, 230); // empfangene Zeichenkette ausgeben
}
}
osDelay(10);
}
}

.................................
And this is a sender call from STM to the PC - not magic

Len = strlen(uhrzeit);
CDC_Transmit_FS ( (uint8_t *) uhrzeit, Len); //! USB2.0 480Mbit



I hope this will helps you to solve your issues.