and key
  ;default - send (possibly transformed) single char 
  ldy #1      ;means A contains single byte to send
@done:
rts



; -------------------------------------
; create an ansi control sequence
; -------------------------------------


output_string:
  tya         ; restore original key

; --- crsr U ---
  cmp #$91    ; test crsr U
  bne @not_U
  ldax  #ansi_cursor_up
  ldy   #2
  rts
; --- crsr L ---
@not_U:      
  cmp #$9d    ; test crsr L
  bne @not_L
  ldax #ansi_curso