|  | Routines | 
| Prev: B00B | Up: Map | Next: B06D | 
| B03C | LD A,($B2DB) | Get the input mechanism. (B2DB) | ||
| B03F | OR A | Is it 0? | ||
| B040 | JR Z,$B059 | Jump forward if it is. | ||
| B042 | CP $01 | Is it 1? | ||
| B044 | JR NZ,$B04E | Jump forward if it is. | ||
| 
Use Kempston input
 | ||||
| B046 | IN A,($1F) | Read the Kempston interface. | ||
| B048 | BIT 1,A | Was 'left' pressed? | ||
| B04A | JR NZ,$B056 | If so, jump forward to signal success. | ||
| B04C | JR $B06B | Otherwise, jump forward to indicate nothing read. | ||
| 
Use Sinclair input
 | ||||
| B04E | LD A,$EF | |||
| B050 | IN A,($FE) | |||
| B052 | BIT 4,A | |||
| B054 | JR NZ,$B06B | |||
| 
'Right' was pressed, so indicate this.
 | ||||
| B056 | LD A,$01 | Return A with 1 to mark success. | ||
| B058 | RET | |||
| 
Use keyboard input.
 | ||||
| B059 | LD A,$FB | |||
| B05B | IN A,($FE) | |||
| B05D | OR $EA | |||
| B05F | LD B,A | |||
| B060 | LD A,$DF | |||
| B062 | IN A,($FE) | |||
| B064 | OR $F5 | |||
| B066 | AND B | |||
| B067 | CP $FF | |||
| B069 | JR NZ,$B056 | |||
| 
'Right' wasn't pressed, so indicate this.
 | ||||
| B06B | XOR A | Return A with 0. | ||
| B06C | RET | |||
| Prev: B00B | Up: Map | Next: B06D |