diff options
| author | Omar Magdy <omar.professional8777@gmail.com> | 2022-08-25 02:38:48 +0200 |
|---|---|---|
| committer | Omar Magdy <omar.professional8777@gmail.com> | 2022-08-25 02:38:48 +0200 |
| commit | 2b2a9c7e6f19d3f700a1466b190606f362484af6 (patch) | |
| tree | f82f270e2181d054965d51d5a7542cf9f0bf5fe4 /trafficlight.c | |
| parent | c3f4417efaa489c41e5d5d44fb28ae01e65ff6bc (diff) | |
| download | Traffic-light-2b2a9c7e6f19d3f700a1466b190606f362484af6.tar.xz Traffic-light-2b2a9c7e6f19d3f700a1466b190606f362484af6.zip | |
Fixed a bug where it would reset the timer of tf1 to 0 when I press the
switch instead of displaying the time which it was paused at
Diffstat (limited to 'trafficlight.c')
| -rw-r--r-- | trafficlight.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/trafficlight.c b/trafficlight.c index 969ffae..92bacaa 100644 --- a/trafficlight.c +++ b/trafficlight.c @@ -182,7 +182,7 @@ void BcdWrite(Bcd bcd, uint32_t timer, bool ped) { DIO_WritePin(&GPIO_PORTA_DATA_R, bcd.A, bin[0]); DIO_WritePin(&GPIO_PORTA_DATA_R, bcd.B, bin[1]); DIO_WritePin(&GPIO_PORTA_DATA_R, bcd.C, bin[2]); - GPIOPinWrite(GPIO_PORTE_BASE, 0xFF, (bin[3] << bcd.D)); + DIO_WritePin(&GPIO_PORTE_DATA_R, bcd.C, bin[3]); } else { for(int i = 0; i < 4; i++) { |
