File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -63,7 +63,7 @@ void led_init(void)
63
63
// RB8 - LED
64
64
// ANASELB RB8 not analog
65
65
ANSELBCLR = TU_BIT (8 );
66
- // TRISH RH2 input
66
+ // TRISH RH2 output
67
67
TRISBCLR = TU_BIT (8 );
68
68
// Initial value 0, LED off
69
69
LATBCLR = TU_BIT (8 );
@@ -128,7 +128,7 @@ void board_led_write(bool state)
128
128
129
129
uint32_t board_button_read (void )
130
130
{
131
- return (PORTB >> 12 ) & 1 ;
131
+ return (( PORTB >> 12 ) & 1 ) == 0 ;
132
132
}
133
133
134
134
int board_uart_write (void const * buf , int len )
Original file line number Diff line number Diff line change @@ -60,7 +60,7 @@ void led_init(void)
60
60
{
61
61
// RH2 - LED
62
62
// ANASELH no analog function on RH2
63
- // TRISH RH2 input
63
+ // TRISH RH2 output
64
64
TRISHCLR = TU_BIT (2 );
65
65
// Initial value 0, LED off
66
66
LATHCLR = TU_BIT (2 );
@@ -126,7 +126,7 @@ void board_led_write(bool state)
126
126
127
127
uint32_t board_button_read (void )
128
128
{
129
- return (PORTB >> 12 ) & 1 ;
129
+ return (( PORTB >> 12 ) & 1 ) == 0 ;
130
130
}
131
131
132
132
int board_uart_write (void const * buf , int len )
You can’t perform that action at this time.
0 commit comments