HS_SPI access on LPC55S06JHI48

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

HS_SPI access on LPC55S06JHI48

1,553件の閲覧回数
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)

 

ラベル(1)
0 件の賞賛
返信
3 返答(返信)

1,513件の閲覧回数
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 件の賞賛
返信

1,541件の閲覧回数
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 件の賞賛
返信

1,540件の閲覧回数
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 件の賞賛
返信