HSPI Chip Select Polarity

metalphreak
Posts: 5
Joined: Wed Apr 29, 2015 4:33 pm

HSPI Chip Select Polarity

Postby metalphreak » Tue May 12, 2015 11:25 am

I have an SPI device that requires CS be active high rather than the default active low. Is there a configuration bit to change the polarity of the HSPI CS pin?

0xPIT
Posts: 9
Joined: Mon Jan 05, 2015 9:26 pm

Re: HSPI Chip Select Polarity

Postby 0xPIT » Fri Jul 10, 2015 3:27 am

In spi_overlap.c|h of SDK 1.2.0:

Code: Select all

#define HSPI_FALLING_EDGE_SAMPLE()      SET_PERI_REG_MASK(SPI_USER(HSPI),  SPI_CK_OUT_EDGE)
#define HSPI_RISING_EDGE_SAMPLE()         CLEAR_PERI_REG_MASK(SPI_USER(HSPI),  SPI_CK_OUT_EDGE)

Who is online

Users browsing this forum: No registered users and 12 guests