remove catlist
added swap32() function
simplify
simplify read_status()
removed statep param from bypass_test()
made COMMAND_ENDING dynamic