Applications of the pyroelectric effect