move to cycbuf
delete the old switch buffer coding