The influence of grains and grain boundaries on the device characteristics of polycrystalline silicon solar cells