working on m4 encoding