added basic listening functionality