record is working, but connect function is not set up correctly to handle play and record.