cleaned code again, added keyboard