Added new LEDs_Disable(), Buttons_Disable() and Joystick_Disable() functions to the board hardware drivers.
This commit is contained in:
		
							parent
							
								
									a147cee95f
								
							
						
					
					
						commit
						5563da6a62
					
				
					 65 changed files with 422 additions and 16 deletions
				
			
		| 
						 | 
				
			
			@ -84,6 +84,16 @@
 | 
			
		|||
				PORTF_PIN2CTRL = PORT_OPC_PULLUP_gc;
 | 
			
		||||
			}
 | 
			
		||||
 | 
			
		||||
			static inline void Buttons_Disable(void)
 | 
			
		||||
			{
 | 
			
		||||
				PORTE_OUTCLR = BUTTONS_BUTTON1;
 | 
			
		||||
				PORTF_OUTCLR = (BUTTONS_BUTTON2 | BUTTONS_BUTTON3);
 | 
			
		||||
 | 
			
		||||
				PORTE_PIN5CTRL = 0;
 | 
			
		||||
				PORTF_PIN1CTRL = 0;
 | 
			
		||||
				PORTF_PIN2CTRL = 0;
 | 
			
		||||
			}
 | 
			
		||||
 | 
			
		||||
			static inline uint8_t Buttons_GetStatus(void) ATTR_WARN_UNUSED_RESULT;
 | 
			
		||||
			static inline uint8_t Buttons_GetStatus(void)
 | 
			
		||||
			{
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -83,6 +83,12 @@
 | 
			
		|||
				PORTR_OUTSET = LEDS_ALL_LEDS;
 | 
			
		||||
			}
 | 
			
		||||
 | 
			
		||||
			static inline void LEDs_Disable(void)
 | 
			
		||||
			{
 | 
			
		||||
				PORTR_DIRCLR = LEDS_ALL_LEDS;
 | 
			
		||||
				PORTR_OUTCLR = LEDS_ALL_LEDS;
 | 
			
		||||
			}
 | 
			
		||||
 | 
			
		||||
			static inline void LEDs_TurnOnLEDs(const uint8_t LEDMask)
 | 
			
		||||
			{
 | 
			
		||||
				PORTR_OUTCLR = LEDMask;
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue