diff options
author | Dominik Sliwa <dominik.sliwa@toradex.com> | 2017-04-10 13:41:28 +0200 |
---|---|---|
committer | Dominik Sliwa <dominik.sliwa@toradex.com> | 2017-04-10 13:41:28 +0200 |
commit | d0e5a94a55334b0a27652959fba5066f56128135 (patch) | |
tree | 058987518e64691297b4409d5b06d65e9b335167 /source/gpio_ext.c | |
parent | b3bc06bef795fdc57254729c74c04e2732a6092d (diff) |
CAN and communication updates
Diffstat (limited to 'source/gpio_ext.c')
-rw-r--r-- | source/gpio_ext.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/source/gpio_ext.c b/source/gpio_ext.c index 5741cb5..977a42e 100644 --- a/source/gpio_ext.c +++ b/source/gpio_ext.c @@ -89,7 +89,11 @@ uint8_t get_gpio_status(uint8_t pin) return status; } -int gpio_registers(uint8_t *rx_buf, uint8_t *tx_buf){ +int gpio_registers(dspi_transfer_t *spi_transfer) +{ + uint8_t *rx_buf = spi_transfer->rxData; + uint8_t *tx_buf = &spi_transfer->txData[1]; + if (rx_buf[0] == APALIS_TK1_K20_READ_INST) { switch (rx_buf[1]) { case APALIS_TK1_K20_GPIOREG: |