cpu/sam0_common/periph/spi: uncrustify
This commit is contained in:
parent
c5ad13cb18
commit
5ea4fcd9c8
@ -73,7 +73,7 @@ void spi_init(spi_t bus)
|
|||||||
/* reset all device configuration */
|
/* reset all device configuration */
|
||||||
dev(bus)->CTRLA.reg |= SERCOM_SPI_CTRLA_SWRST;
|
dev(bus)->CTRLA.reg |= SERCOM_SPI_CTRLA_SWRST;
|
||||||
while ((dev(bus)->CTRLA.reg & SERCOM_SPI_CTRLA_SWRST) ||
|
while ((dev(bus)->CTRLA.reg & SERCOM_SPI_CTRLA_SWRST) ||
|
||||||
(dev(bus)->SYNCBUSY.reg & SERCOM_SPI_SYNCBUSY_SWRST));
|
(dev(bus)->SYNCBUSY.reg & SERCOM_SPI_SYNCBUSY_SWRST)) {}
|
||||||
|
|
||||||
/* configure base clock: using GLK GEN 0 */
|
/* configure base clock: using GLK GEN 0 */
|
||||||
#ifdef GCLK_CLKCTRL_GEN_GCLK0
|
#ifdef GCLK_CLKCTRL_GEN_GCLK0
|
||||||
@ -103,7 +103,7 @@ void spi_init_pins(spi_t bus)
|
|||||||
|
|
||||||
int spi_acquire(spi_t bus, spi_cs_t cs, spi_mode_t mode, spi_clk_t clk)
|
int spi_acquire(spi_t bus, spi_cs_t cs, spi_mode_t mode, spi_clk_t clk)
|
||||||
{
|
{
|
||||||
(void) cs;
|
(void)cs;
|
||||||
|
|
||||||
/* configure bus clock, in synchronous mode its calculated from
|
/* configure bus clock, in synchronous mode its calculated from
|
||||||
* BAUD.reg = (f_ref / (2 * f_bus) - 1)
|
* BAUD.reg = (f_ref / (2 * f_bus) - 1)
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user