Method and circuit for writing and reading a digital semiconductor memory for video signals