p–n Heterojunction diodes made by assembly of ITO/nano-crystalline TiO2/polyaniline/ITO