summaryrefslogtreecommitdiff
path: root/tmk_core/protocol/arm_atsam/shift_register.c
diff options
context:
space:
mode:
Diffstat (limited to 'tmk_core/protocol/arm_atsam/shift_register.c')
-rw-r--r--tmk_core/protocol/arm_atsam/shift_register.c12
1 files changed, 8 insertions, 4 deletions
diff --git a/tmk_core/protocol/arm_atsam/shift_register.c b/tmk_core/protocol/arm_atsam/shift_register.c
index 8d63af1b59..3adb682aa8 100644
--- a/tmk_core/protocol/arm_atsam/shift_register.c
+++ b/tmk_core/protocol/arm_atsam/shift_register.c
@@ -54,7 +54,9 @@ void shift_out_impl(const uint8_t *data, uint16_t length) {
#else
-void shift_init_impl(void) { spi_init(); }
+void shift_init_impl(void) {
+ spi_init();
+}
void shift_out_impl(const uint8_t *data, uint16_t length) {
spi_start(SR_EXP_RCLK_PIN, true, 0, 0);
@@ -67,7 +69,9 @@ void shift_out_impl(const uint8_t *data, uint16_t length) {
// ***************************************************************
-void shift_out(const uint8_t *data, uint16_t length) { shift_out_impl(data, length); }
+void shift_out(const uint8_t *data, uint16_t length) {
+ shift_out_impl(data, length);
+}
void shift_enable(void) {
setPinOutput(SR_EXP_OE_PIN);
@@ -90,8 +94,8 @@ sr_exp_t sr_exp_data;
void SR_EXP_WriteData(void) {
uint8_t data[2] = {
- sr_exp_data.reg & 0xFF, // Shift in bits 7-0
- (sr_exp_data.reg >> 8) & 0xFF, // Shift in bits 15-8
+ sr_exp_data.reg & 0xFF, // Shift in bits 7-0
+ (sr_exp_data.reg >> 8) & 0xFF, // Shift in bits 15-8
};
shift_out(data, 2);
}