fixed encoding, added more commands