From 5c4ad4969514b82285ef37922f7acf61600c70de Mon Sep 17 00:00:00 2001 From: Uros Majstorovic Date: Thu, 8 Apr 2021 04:03:03 +0200 Subject: reintrodiced spi_dev --- fw/fe310/eos/spi_dev.c | 89 ++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 89 insertions(+) create mode 100644 fw/fe310/eos/spi_dev.c (limited to 'fw/fe310/eos/spi_dev.c') diff --git a/fw/fe310/eos/spi_dev.c b/fw/fe310/eos/spi_dev.c new file mode 100644 index 0000000..d279faf --- /dev/null +++ b/fw/fe310/eos/spi_dev.c @@ -0,0 +1,89 @@ +#include +#include + +#include "encoding.h" +#include "platform.h" + +#include "eos.h" +#include "msgq.h" +#include "interrupt.h" +#include "event.h" + +#include "board.h" + +#include "net.h" +#include "spi.h" +#include "spi_priv.h" +#include "spi_cfg.h" +#include "spi_dev.h" + +static uint8_t spi_dev; +static uint8_t spi_lock; +static uint16_t spi_div[EOS_SPI_MAX_DEV]; + +void eos_spi_dev_init(void) { + int i; + + for (i=0; i