how to change spi clock speed in wiced

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
BaGo_4138971
Level 3
Level 3

Hi All,

How to intialize SPI to communicate with sflash in wiced. How we can generate different clock frequencies on the clk pin.

Please let me know how i can do this?

Thanks,

Basavanagouda.

0 Likes
1 Solution

if 43907 is used  now,  we often modify SPI_CLOCK_SPEED_HZ to change the SPI clock.

#ifdef USE_SPI0_DEVICE

static const wiced_spi_device_t spi0_device =

{

.port        = WICED_SPI_1,

.chip_select = WICED_GPIO_22,

.speed       = SPI_CLOCK_SPEED_HZ,

.mode        = SPI_MODE,

.bits        = SPI_BIT_WIDTH

};

#endif

static const wiced_spi_device_t spi1_device =

{

.port        = WICED_SPI_2,

.chip_select = WICED_GPIO_NONE,

.speed       = SPI_CLOCK_SPEED_HZ,

.mode        = SPI_MODE,

.bits        = SPI_BIT_WIDTH

};

View solution in original post

0 Likes
4 Replies