HS_SPI access on LPC55S06JHI48

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

HS_SPI access on LPC55S06JHI48

1,551 Views
christianlees
Contributor III

I'm  trying to use the HS SPI interface on a LPC55S06JHI48.

It is connected to flexcomm 8 according to the datasheet and manual but the device with this package.  When I try to access SPI8 I get this error

assertion "i < (uint32_t)FSL_FEATURE_SOC_FLEXCOMM_COUNT" failed: file ".fsl_flexcomm.c", line 106, function: FLEXCOMM_GetInstance

FSL_FEATURE_SOC_FLEXCOMM_COUNT is defined as 8 in the LPC55S06_features.h file.

In that same file is this line 

/* @brief FLEXCOMM8 SPI(HS_SPI) INDEX 8 */
#define FSL_FEATURE_FLEXCOMM8_SPI_INDEX (8)

How do I go about using this SPI interface with the SDK? (version 2.10.0)

 

Labels (1)
0 Kudos
Reply
3 Replies

1,511 Views
christianlees
Contributor III

Turns out you can get it to work using the SDK if you change two lines LPC55S06_features.h file

#define FSL_FEATURE_SOC_SPI_COUNT (9) // Changed 4 to 9

#define FSL_FEATURE_SOC_FLEXCOMM_COUNT (9) // Changed 8 to 9

After these changes it can be accessed as SPI8

The SDK needs to be updated to support the HSSPI interface that isn't such a nasty hack.

0 Kudos
Reply

1,539 Views
xiangjun_rong
NXP TechSupport
NXP TechSupport

Hi,

As a workaround, I think you can use the code to set up the high speed spi.

CLOCK_EnableClock(kCLOCK_Hs_Lspi);
FLEXCOMM8->PSELID=0x02;

Hope it can help you

BR

XiangJun Rong

0 Kudos
Reply

1,538 Views
xiangjun_rong
NXP TechSupport
NXP TechSupport

Hi,

I have tried to change to SPI8 from SPI7, no problem, I can pass compilation without any problem.

xiangjun_rong_0-1638519896570.png

BR

XiangJun Rong

0 Kudos
Reply