SPI / i2C setup in LPC55S69

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

SPI / i2C setup in LPC55S69

886 次查看
HappyDBG1
Contributor I

Would like to have clarifications on Flexcomm and Pin Config setups on LPC55S69.

(1) In SPI mode, max of peripherals EACH Flexcomm's connection (FCs with SSEL0 and SSEL1) is only 2, but each FC3/FC4/FC8 can connect up to 4 sensors ?

(2) In i2c mode, what's the max of peripherals for each FCx with pullups ?

(3) In GPIO Pin Configuration's Mode, does PullDown/Up setup reflect the board's HW, or will MCU will supply pullup/down based on settings ?

(4) In SPI mode Pin Configuration screen, can setup "Direction" be "Not specified" for MISO/ MOSI lines ? or do MISO pins have to be setup as Input (Master) or Output (Slave) and can't be changed ?

Thank you,

0 项奖励
回复
4 回复数

867 次查看
HappyDBG1
Contributor I

Thank you Scott.

0 项奖励
回复

873 次查看
HappyDBG1
Contributor I

Hi Scott,

Thank you for your speedy response. 

If the setup is: MCU is the SPI Master, and several peripherals are setup as Slaves (typical setup), with one Slave per Flexcomm,

Is there an example code for SPI send / receive test?  The samples codes provided are from board-to-board.

Thanks again...

0 项奖励
回复

869 次查看
scottm
Senior Contributor II

Those board-to-board demos are the send and receive demos. You ought to be able to write a test that uses two FlexComm modules on the same chip, where one is master and the other slave.

I'm still in the process of bringing up my first LPC55S69 prototype and all I've done with SPI is verify that I can read the device ID bytes from a SPI NOR flash. I started with the lpcxpresso55s69_spi_interrupt demo.

0 项奖励
回复

880 次查看
scottm
Senior Contributor II

I've only just started working with the LPC55S69 myself but I might be able to answer some of your questions.

The number of SPI SSEL outputs available is going to depend on the variant/package you've selected. If you've got a large number of devices you can always use GPIOs, but then you need to handle chip selection in your own code.

The number of I2C peripherals you can connect depends on the bus speed and the total capacitance. Table 32 of the datasheet (Dynamic characteristic: I2C-bus pins) gives some specifics.

In the GPIO configuration, the pull up / pull down settings select the internal pull-up resistors for the pin. Use those if you want the MCU to provide pull-up or pull-down.

Checking my own project, I see that I don't have direction specified for any of the SPI pins. The selected function should override the GPIO settings. Section 15.4.1 in the user's manual covers pin configuration.

Hope that helps,

Scott

0 项奖励
回复