diff options
author | Kevin O'Connor <kevin@koconnor.net> | 2018-05-04 12:47:26 -0400 |
---|---|---|
committer | Kevin O'Connor <kevin@koconnor.net> | 2018-05-07 09:10:34 -0400 |
commit | 31ae74c56c9663fdbcc8f332efd0e331d2e024ff (patch) | |
tree | 7bb72b7c414aded9288ca54ccad85ae6f0ee7dbe /src/sam3x8e/gpio.h | |
parent | 22487d95e9b9b0ada171c72df5f5fbb3f3985724 (diff) | |
download | kutter-31ae74c56c9663fdbcc8f332efd0e331d2e024ff.tar.gz kutter-31ae74c56c9663fdbcc8f332efd0e331d2e024ff.tar.xz kutter-31ae74c56c9663fdbcc8f332efd0e331d2e024ff.zip |
sam3x8e: Add SPI support
Signed-off-by: Petri Honkala <cruwaller@gmail.com>
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
Diffstat (limited to 'src/sam3x8e/gpio.h')
-rw-r--r-- | src/sam3x8e/gpio.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/sam3x8e/gpio.h b/src/sam3x8e/gpio.h index 0c75f642..1cab4614 100644 --- a/src/sam3x8e/gpio.h +++ b/src/sam3x8e/gpio.h @@ -28,4 +28,11 @@ uint32_t gpio_adc_sample(struct gpio_adc g); uint16_t gpio_adc_read(struct gpio_adc g); void gpio_adc_cancel_sample(struct gpio_adc g); +struct spi_config { + uint32_t cfg; +}; +struct spi_config spi_setup(uint32_t bus, uint8_t mode, uint32_t rate); +void spi_transfer(struct spi_config config, uint8_t receive_data + , uint8_t len, uint8_t *data); + #endif // gpio.h |