User Activity

I'm trying to write on a LCD named 2004A. The problem is that the row i write are mixed up. I attached a photo of the result and the two main file of the project. Thanks for yout help.