Bad behaviour using keypad

To give you a better idea of what is happening I post a video did during tests a few days ago.

Pinouts: I tried right now to invert connection as xfpd wrote, but I have the same behaviour you can see in the video