From e3a0899abde145a2212082041ffeaf0ca6529300 Mon Sep 17 00:00:00 2001 From: Determinant Date: Mon, 25 Sep 2017 21:17:18 -0400 Subject: ... --- src/main.rs | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) (limited to 'src/main.rs') diff --git a/src/main.rs b/src/main.rs index a79107c..0b63e58 100644 --- a/src/main.rs +++ b/src/main.rs @@ -53,9 +53,7 @@ fn update_clock() { minute: min, hour: hr, ..} = RTC.as_mut().unwrap() .read_fulldate(); - TIME = Clock{sec: sec, - min: min, - hr: hr, + TIME = Clock{sec, min, hr, reset: RESET_PERIOD}; } @@ -74,9 +72,9 @@ fn systick_handler() { exception!(SYS_TICK, systick_handler); impl<'a> ShiftRegister<'a> { - fn new(g: &'a stm32f103xx::gpioa::RegisterBlock, + fn new(gpioa: &'a stm32f103xx::gpioa::RegisterBlock, width: u8) -> ShiftRegister<'a> { - let this = ShiftRegister{gpioa: g, width: width}; + let this = ShiftRegister{gpioa, width}; this } -- cgit v1.2.3