Added new LEDs_Disable(), Buttons_Disable() and Joystick_Disable() functions to the board hardware drivers.
This commit is contained in:
@@ -76,6 +76,12 @@
|
||||
PORTD |= BUTTONS_BUTTON1;
|
||||
}
|
||||
|
||||
static inline void Buttons_Disable(void)
|
||||
{
|
||||
DDRD &= ~BUTTONS_BUTTON1;
|
||||
PORTD &= ~BUTTONS_BUTTON1;
|
||||
}
|
||||
|
||||
static inline uint8_t Buttons_GetStatus(void) ATTR_WARN_UNUSED_RESULT;
|
||||
static inline uint8_t Buttons_GetStatus(void)
|
||||
{
|
||||
|
||||
@@ -91,7 +91,13 @@
|
||||
static inline void Joystick_Init(void)
|
||||
{
|
||||
DDRD &= ~JOY_MASK;
|
||||
PORTD |= JOY_MASK;
|
||||
PORTD |= JOY_MASK;
|
||||
}
|
||||
|
||||
static inline void Joystick_Disable(void)
|
||||
{
|
||||
DDRD &= ~JOY_MASK;
|
||||
PORTD &= ~JOY_MASK;
|
||||
}
|
||||
|
||||
static inline uint8_t Joystick_GetStatus(void) ATTR_WARN_UNUSED_RESULT;
|
||||
|
||||
@@ -91,6 +91,12 @@
|
||||
PORTB &= ~LEDS_ALL_LEDS;
|
||||
}
|
||||
|
||||
static inline void LEDs_Disable(void)
|
||||
{
|
||||
DDRB &= ~LEDS_ALL_LEDS;
|
||||
PORTB &= ~LEDS_ALL_LEDS;
|
||||
}
|
||||
|
||||
static inline void LEDs_TurnOnLEDs(const uint8_t LedMask)
|
||||
{
|
||||
PORTB |= LedMask;
|
||||
|
||||
Reference in New Issue
Block a user