Moved setup and loop functions to the top.