start implement state table
next
just a encoding problems
add new features