HSPI Clock Polarity
HSPI Clock Polarity
Postby 0xPIT » Sun Jun 07, 2015 10:41 pm
Hi,
how can I change the Clock Polarity for Hardware-SPI? I need the clock to be low-active instead of the default which is high-active.
I've been playing with SPI_CTRL2, but this did not work as advertised in the Register-Description Excel file.
I was unable to delay MOSI for half a cycle.
Any help? Any examples?
Thanks,
- pit
how can I change the Clock Polarity for Hardware-SPI? I need the clock to be low-active instead of the default which is high-active.
I've been playing with SPI_CTRL2, but this did not work as advertised in the Register-Description Excel file.
I was unable to delay MOSI for half a cycle.
Any help? Any examples?
Thanks,
- pit
Re: HSPI Clock Polarity
Postby kolban » Thu Jul 09, 2015 5:31 am
Howdy there,
Have you seen this document:
download/file.php?id=577
It is:
8Q-ESP8266 HSPI Host Multi-device API v1.0
If I look on page 6, I find a parameter called "clk_polar"
This is associated with the function called hpsi_master_dev_init().
Is this what you are looking for?
Neil
Have you seen this document:
download/file.php?id=577
It is:
8Q-ESP8266 HSPI Host Multi-device API v1.0
If I look on page 6, I find a parameter called "clk_polar"
This is associated with the function called hpsi_master_dev_init().
Is this what you are looking for?
Neil
Re: HSPI Clock Polarity
Postby 0xPIT » Fri Jul 10, 2015 3:26 am
Thanks Neil, I could find
in the spi_overlap.* sources, will try soon.
Not sure if this is for slave mode, though, as it's called _SAMPLE.
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)
in the spi_overlap.* sources, will try soon.
Not sure if this is for slave mode, though, as it's called _SAMPLE.
Who is online
Users browsing this forum: No registered users and 89 guests
Login
Newbies Start Here
Are you new to ESP8266?
Unsure what to do?
Dunno where to start?
Start right here!
Latest SDK
Documentation
Complete listing of the official ESP8266 related documentation release by ESPRESSIF!
Must read here!
- All times are UTC+08:00
- Top
- Delete all board cookies
About Us
Espressif Systems is a fabless semiconductor company providing cutting-edge low power WiFi SoCs and wireless solutions for wireless communications and Internet of Things applications. We are the manufacturer of ESP8266EX.