Unless otherwise provided, any person violating any of the provisions or failing to comply with any of the mandatory requirements of any ordinance of the city is guilty of a violation. Except where a different punishment is prescribed by any ordinance of the city, any person convicted of a violation under the ordinances of the city shall be punished by a fine not to exceed $500.