Add gpio test files, changed average dregrees function