cancel
Showing results for 
Search instead for 
Did you mean: 

XCP timeout error in MATLAB Simulink when trying to monitor code on Nucleo STM32G431RB

MBorn.4
Associate

Hello,

I am trying to monitor a simple model build in MATLAB Simulink and running on my Nucleo STM32G4321RB board.

Building and deploying the model on the controller is possible, the code is running properly. But when I try to use the external mode function in Simulink, to monitor the running code, there is an error:

"XCP internal error: timeout expired, in response to XCP CONNECT command".


_legacyfs_online_stmicro_images_0693W00000bjDC8QAM.png 

The model itself is very simple. Read digital input from User-Button and output state to User-LED.

According to the user manual UM2505 from ST, on the G431RB-board the LPUART1 is connected to STLINK-V3E Virtual COM Port by default.

So I have setup the LPUART1 in CubeMX in asynchronous mode at 115200 Bits/s.

And also configured the Simulink model for LPUART1 and COM3 (as given by Windows device manager)


_legacyfs_online_stmicro_images_0693W00000bjDEsQAM.png 

But it just won't work. And I could not find any helpful answers on google for this problem.

I also tried UART1 and UART3 in desperation, but that's not working either, of course.

Does anyone have an idea, how to get this running?

Thanks for your help.

2 REPLIES 2
Ezzeldin
Associate

Any updates from ur side ? as i have same problem as u 

 

sanathhere
Associate III

Hello,

I have the same error and I am still not able to solve it nor find any solution online. I am using a USB TTL 232 RPI cable for my MEMS accelerometer. Could anyone please confirm or suggest a solution? Thank you!