Solar Panels works on the principal photo voltaic effect. Here when sunlight falls on semi-conductor materials, electrons a gets excited and it moves from valance band to conduction band. There by leaving a whole pair in the valence band. This electron and hole movement within a semiconductor materials is called electricity.
A Solar panel consists of numbers of Solar Cells, which is made of semi-conductor materials – both N Type and P type. Electrons generated from each solar cells are collected using busbars - lines which we see in solar panels. These collected electron flow is called electricity, which is brought to junction boxes. From junction boxes we take output.
There are different types of semiconductor materials used for solar panel manufacturing. Like Silicon, cadmium telluride (CdTe) & copper indium gallium dieseline – CIGS. Also some other materials recently developed include Perovskite Photovoltaic, Organic Photovoltaic, and Quantum Dots etc.