Jamming of directed traffic on a square lattice