fix bugs in framer-tdma.c
add frame format code