Lattice p-Form Electromagnetism and Chain Field Theory