Python Write Variable To Binary Code