added gpio playing functionality