cancel
Showing results for 
Search instead for 
Did you mean: 

STM32F429 TouchGFX project blocks CAN1 configuration - how to enable CAN functionality?

Mike11
Associate

I'm working on a project that needs both TouchGFX GUI and CAN communication. After configuring my STM32F429 with TouchGFX, I'm unable to enable CAN1 in STM32CubeMX. 

From what  I understand, CAN2 is a slave/dependent peripheral that requires CAN1 to be active, so I need CAN1 functioning first. If I create a can task with CAN2 it does not work (Loopback mode), and if I enable CAN1 the display will stop working.

Is there a recommended pin configuration that allows both TouchGFX and CAN to coexist?

Has anyone successfully implemented both TouchGFX and CAN on the F429?

Thanks!

1 ACCEPTED SOLUTION

Accepted Solutions

CAN1 is not available with TouchGFX. As you said, all the available CAN1 pins are either used by LTDC or FMC:

mALLEm_0-1748957027465.png

Meanwhile CAN2 is available. You can use it on PB12/PB13.

If CAN2 is not working, please open a new thread. That doesn't have a relation with TouchGFX function.

I suggest to run CAN2 separately without TouchGFX to simplify the analysis.

Thank you

To give better visibility on the answered topics, please click on "Accept as Solution" on the reply which solved your issue or answered your question.

View solution in original post

6 REPLIES 6
mƎALLEm
ST Employee

Hello @Mike11 and welcome to the community,

You need first to ensure that there is no overlap in the GPIOs usage with LCD and touchscreen functionality with CAN IOs. This is the first step you need to check.

If there is an overlap you need to use other IOs for CAN.

To give better visibility on the answered topics, please click on "Accept as Solution" on the reply which solved your issue or answered your question.

Hello @mƎALLEm  thanks for the answer.

The issue for is that all the pins for CAN1 are used by LTDC and FMC

From what I see the possible pins for CAN1 are PB8  PD0 and PA11 for CAN1_RD and PB9 PD1 and PA12 for CAN1_TD.  PB8 PB9, PA11 PA12 are used by LTDC, and PD0 and PD1 are used by FMC ( SDRAM1 Data).

You didn't tell what  board are you using?

You didn't share your ioc file

Meanwhile, if all the alternate functions available for CANx are used by the LTDC and FMC, unfortunately for you, it will not possible to use both TouchGFX and CAN at the same time.

 

To give better visibility on the answered topics, please click on "Accept as Solution" on the reply which solved your issue or answered your question.

I am using STM32F429I-DISC1. As for the .ioc I am reffering to any TouchGFX generated project(just a background added from TouchGFX). I will add it in this reply. Is there no alternative for SDRAM1 for using Touch GFX?

 

CAN1 is not available with TouchGFX. As you said, all the available CAN1 pins are either used by LTDC or FMC:

mALLEm_0-1748957027465.png

Meanwhile CAN2 is available. You can use it on PB12/PB13.

If CAN2 is not working, please open a new thread. That doesn't have a relation with TouchGFX function.

I suggest to run CAN2 separately without TouchGFX to simplify the analysis.

Thank you

To give better visibility on the answered topics, please click on "Accept as Solution" on the reply which solved your issue or answered your question.