diff --git a/ked/csl/stm32f042/Device/hardwareDescription.h b/ked/csl/stm32f042/Device/hardwareDescription.h index 530a311..70dafba 100644 --- a/ked/csl/stm32f042/Device/hardwareDescription.h +++ b/ked/csl/stm32f042/Device/hardwareDescription.h @@ -230,6 +230,15 @@ static const uint32_t timerRes_Prescaler[MAX_TIMER_CHANNEL_COUNT] = { 0xFFFF, /*!< Timer 17 Prescaler Max Value */ }; + +typedef enum{ + SPI_CH_1, + SPI_CH_2 +} spiCH_t; + + + + #ifdef __cplusplus } #endif diff --git a/ked/csl/stm32f042/Src/spi.c b/ked/csl/stm32f042/Src/spi.c index e69de29..05af6c0 100644 --- a/ked/csl/stm32f042/Src/spi.c +++ b/ked/csl/stm32f042/Src/spi.c @@ -0,0 +1,13 @@ +#include "spi.h" + + +void spi_initMater(spiCH_t_spi_hw_ch) +{ + +} + + +uint8_t spi_trx(spiCH_t_spi_hw_ch, uint8_t tx_data) +{ + return 0; +} diff --git a/main.c b/main.c index 4afbfe9..4420bad 100644 --- a/main.c +++ b/main.c @@ -4,6 +4,7 @@ #include "usart.h" #include "ascii.h" #include "timer.h" +#include "spi.h" void timer_test(timerNo_t timer, pinNo_t pin) { diff --git a/main.cpp b/main.cpp index 1a9f936..e2eb625 100644 --- a/main.cpp +++ b/main.cpp @@ -4,6 +4,7 @@ #include "usart.h" #include "ascii.h" #include "timer.h" +#include "spi.h" void timer_test(timerNo_t timer, pinNo_t pin) { diff --git a/tmux_workbench.sh b/tmux_workbench.sh new file mode 100755 index 0000000..c9e0773 --- /dev/null +++ b/tmux_workbench.sh @@ -0,0 +1,20 @@ +#!/bin/bash + +dir=$(pwd) +echo $dir + +tmux new -s 'git' -d 'fish' +tmux new -s 'compile' -d 'fish' + +tmux new -s 'main' -d 'vim main.cpp' + +cd $dir/ked/csl/stm32f042/Src/ +tmux new -s 'src' -d 'fish' + +cd $dir/ked/csl/stm32f042/Device/ +tmux new -s 'device' -d 'fish' + +cd $dir/ked/csl/interfaces/ +tmux new -s 'interface' -d 'fish' + +tmux a