Convert some AVR GPIO operations to macros (#23424)
This commit is contained in:
parent
7220715dd1
commit
61c7c1f74c
71 changed files with 877 additions and 840 deletions
|
@ -71,13 +71,12 @@ uint8_t matrix_cols(void)
|
|||
|
||||
void matrix_init(void)
|
||||
{
|
||||
|
||||
DDRC &= ~(1<<7);
|
||||
PORTC |= (1<<7);
|
||||
DDRB &= ~(1<<7 | 1<<5);
|
||||
PORTB |= (1<<7 | 1<<5);
|
||||
DDRD &= ~(1<<6 | 1<<4 | 1<<1);
|
||||
PORTD |= (1<<6 | 1<<4 | 1<<1);
|
||||
gpio_set_pin_input_high(C7);
|
||||
gpio_set_pin_input_high(B5);
|
||||
gpio_set_pin_input_high(B7);
|
||||
gpio_set_pin_input_high(D1);
|
||||
gpio_set_pin_input_high(D4);
|
||||
gpio_set_pin_input_high(D6);
|
||||
|
||||
for (uint8_t i=0; i < MATRIX_ROWS; i++) {
|
||||
matrix[i] = 0;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue