raw.py: added interactive functionality when called from console.