set up and initial map code