Sound buffer generation code implemented but not tested