2025-12-01 11:51 PM
Hi, I'm new to STM32 and FMC. I'm connecting STM32H755 to PCL6045, a motor controller which has data/address pins that can be access through FMC. This is what I've done so far:
1) Configure the FMC inside CubeMX with clock set to 20MHz (max 20MHz reference clock according to PCL6045BL datasheet)
I don't know why there's no unmuxed option in the CubeMX since I need to use the FMC_D instead of FMC_DA pins and the address pins start from FMC_A16 until FMC_A20. As for now I just connect FMC_DA to the data lines from PCL6045BL.
2) Then, I try to write something to the selected register of axis X
PclAxisWriteReg(ID_X, WRFL, 10);The base address that I use is 0x60000000. Every time I run the code related to PCL6045BL, it always gives a HardFault error. I have also edited the main.c to use FMC_DATA_ADDRESS_MUX_DISABLE manually but it does not seem change anything. I don't know if I miss something important or my steps are wrong somewhere.