MCPcopy Create free account
hub / github.com/RT-Thread/rt-thread / spi_soft_set_sclk

Function spi_soft_set_sclk

components/drivers/spi/dev_soft_spi.c:147–158  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

145}
146
147static void spi_soft_set_sclk(void *data, rt_int32_t state)
148{
149 struct rt_soft_spi_config *cfg = (struct rt_soft_spi_config *)data;
150 if (state)
151 {
152 rt_pin_write(cfg->sck, PIN_HIGH);
153 }
154 else
155 {
156 rt_pin_write(cfg->sck, PIN_LOW);
157 }
158}
159
160static void spi_soft_set_mosi(void *data, rt_int32_t state)
161{

Callers

nothing calls this directly

Calls 1

rt_pin_writeFunction · 0.50

Tested by

no test coverage detected