correct writing element codes, remove reset