Feb 04, 2021
06:34 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Feb 04, 2021
06:34 AM
Hi,
I'm writing an application using the USBD_VCOM library, a relax kit with the XMC4800 and a Windows10 PC.
All my drivers are up to date.
I need my application to write a menu (multiple selections through characters) on the screen through a text terminal and the COM port .
Something like:
const unsigned char ucMenu[] =
"\n\r"
"1 ... OPTION1\n\r"
"2 ... OPTION2\n\r"
"3 ... OPTION3\n\r"
"4 ... OPTION4\n\r"
"5 ... OPTION5\n\r"
"6 ... OPTION6\n\r"
"\n"
"your choice: ";
This must happen automatically after that the terminal (I'm using Putty) has been connected to the COM port generated by the microcontroller.
At the moment, this is the sequence:
- run the application
- run Putty
- send a character on the COM port generated through USB
AND ONLY HERE I CAN print the menu because if I send anything on the port before the app receives the first character, this is not displayed
So basically, whatever I is written before I run Putty is not displayed and I need to input a character for the uC to receive the first byte and understand that it can print something which will be seen.
I'd like to find a way to get my app to understand when Putty is connected.
Would it be possible?
Thanks and regards,
Ale
I'm writing an application using the USBD_VCOM library, a relax kit with the XMC4800 and a Windows10 PC.
All my drivers are up to date.
I need my application to write a menu (multiple selections through characters) on the screen through a text terminal and the COM port .
Something like:
const unsigned char ucMenu[] =
"\n\r"
"1 ... OPTION1\n\r"
"2 ... OPTION2\n\r"
"3 ... OPTION3\n\r"
"4 ... OPTION4\n\r"
"5 ... OPTION5\n\r"
"6 ... OPTION6\n\r"
"\n"
"your choice: ";
This must happen automatically after that the terminal (I'm using Putty) has been connected to the COM port generated by the microcontroller.
At the moment, this is the sequence:
- run the application
- run Putty
- send a character on the COM port generated through USB
AND ONLY HERE I CAN print the menu because if I send anything on the port before the app receives the first character, this is not displayed
So basically, whatever I is written before I run Putty is not displayed and I need to input a character for the uC to receive the first byte and understand that it can print something which will be seen.
I'd like to find a way to get my app to understand when Putty is connected.
Would it be possible?
Thanks and regards,
Ale
0 Replies