From: Jan "Yenya" Kasprzak Date: Wed, 29 Aug 2012 22:57:05 +0000 (+0200) Subject: led_set_status function X-Git-Tag: gedasymbols-20120913~29 X-Git-Url: https://www.fi.muni.cz/~kas/git//home/kas/public_html/git/?a=commitdiff_plain;h=aa9fba4f95f90d29d33ea8f30412ae951253b909;p=bike-lights.git led_set_status function --- diff --git a/lights.h b/lights.h index ec2397f..d357b55 100644 --- a/lights.h +++ b/lights.h @@ -58,6 +58,7 @@ void ambient_adc(uint16_t adc_val); /* pattern.c */ void pattern_init(); void patterns_next_tick(); +void led_set_status(unsigned char status); /* buttons.c */ void init_buttons(); diff --git a/pattern.c b/pattern.c index 3638686..64d8640 100644 --- a/pattern.c +++ b/pattern.c @@ -154,3 +154,7 @@ void patterns_next_tick() } } +void led_set_status(unsigned char status) +{ + led_set_pattern(N_PWMLEDS+1, number_pattern(status)); +}