Sol-gel prepared NiO thin films for electrochromic applications