Thanks Peter,
We have a minimal console in inc/console.inc but yours looks like the full API.
I would however, recommend changing all the long types to sys for 64 bit compatibility.
Here are some helper functions for mundane console use:
  Function output(string bufout)
  ==============================
  static sys buflen,bufrit
  buflen=len bufout
  WriteConsole ConsOut,strptr bufout,buflen,bufrit,null
  End Function
  Function input() As string
  ==========================
  static sys blen      
  static zstring bufin[300]      
  ReadConsole ConsIn,strptr bufin,299,blen,null
  return left bufin,blen
  End Function
  Function GetKey() as sys
  ========================
  static sys blen,mode
  static zstring z[4]
  GetConsoleMode ConsIn,mode
  SetConsoleMode ConsIn,0
  ReadConsole ConsIn,strptr z,1,blen,null
  SetConsoleMode ConsIn,mode
  return ?z
  End Function