From 547093d69d001fc6bf90778acc479316149a6fd1 Mon Sep 17 00:00:00 2001 From: Omar Magdy Date: Tue, 23 Aug 2022 21:30:26 +0200 Subject: Removed prevPeriod from Traffic struct --- main.c | 6 +++--- trafficlight.h | 1 - 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/main.c b/main.c index bf8916d..c9c115b 100644 --- a/main.c +++ b/main.c @@ -6,9 +6,9 @@ uint32_t period_3 = RED_PERIOD; bool switch_pressed = false; -Traffic tf1 = {YELLOW, GPIO_PORTA_BASE, 2, 3, 4, 0}; -Traffic tf2 = {RED , GPIO_PORTF_BASE, 1, 2, 3, 0}; -Traffic tf_ped = {RED , GPIO_PORTB_BASE, 5, 4, 1, 0}; +Traffic tf1 = {YELLOW, GPIO_PORTA_BASE, 2, 3, 4}; +Traffic tf2 = {RED , GPIO_PORTF_BASE, 1, 2, 3}; +Traffic tf_ped = {RED , GPIO_PORTB_BASE, 5, 4, 1}; int main() { diff --git a/trafficlight.h b/trafficlight.h index 510b89c..026bcaa 100644 --- a/trafficlight.h +++ b/trafficlight.h @@ -18,7 +18,6 @@ typedef struct Traffic{ uint8_t red; uint8_t yellow; uint8_t green; - uint32_t prevPeriod; } Traffic; extern Traffic tf1; -- cgit v1.2.3