Updated iDevice writing and basic XML format added