SWACNT (Data Direction Register for Port A)
Name | D7 | D6 | D5 | D4 | D3 | D2 | D1 | D0
| |
$281 | SWACNT | PA7 | PA6 | PA5 | PA4 | PA3 | PA2 | PA1 | PA0 |
This controls the data direction of each of the 8 pins on Port A (SWCHA)).
Port A is typically used to interface to various hand-held controllers, typically joysticks and paddles.
Set the direction for each pin (PB7-PB0) individually as 0 for input, 1 for output.
Related