Photonic Codes