We present an extensive study of the electronic properties of amorphous silicon nitride for a wide range of N concentrations. Local densities of states on Si and N for the ``ideal'' random network structure, defect states introduced into the semiconducting gap by both Si and N dangling bonds, the effect of wrong bonds (N\char22{}N bonds below stoichometry and Si\char22{}Si bonds above stoichiometry) on the local density of states, and, the energy dependence (from 0 to 10 eV) of the imaginary part of the dielectric function have been obtained as a function of N content. The main purpose has been the development of a theoretical model for amorphous compound that were both internally consistent and in overall agreement with experiment. We stress the following main results: (i) The semiconducting gap opens continuously from pure a-Si to the stoichiometric compound a-${\mathrm{Si}}_{3/7}$${\mathrm{N}}_{4/7}$. For low N content the gap widening is linear in x/(1-x) whereas, just before stoichiometry is reached, the gap opens very sharply to its maximum value. (ii)