Infrared receiver

Hi! I tried to receive the codes of buttons of a remote control (0x....) to be able to control my robot, but the problem is that I can't receive them, it doesn't appear in the serial monitor.But sometimes, when I remove the IR receiver, something appears, but not always, I think I didn't connect it well, here's what I did and tell me please if I did a mistake:
two pins in left and right to 5v power and pin 11, and the middle to the gnd (ground). Is there a way to fix it? Did I do a mistake? Thanks a lot!

two pins in left and right to 5v power and pin 11, and the middle to the gnd (ground)

Without any idea of which IR receiver you're using, this is meaningless.

Also, you haven't shown us your code, so we have no chance of helping to diagnose your problem.

And removing the IR receiver while the circuit is powered might result in random characters appearing in the serial monitor, but it proves nothing.

Before you post your code, I recommend that you read these:-
How to use this forum - please read
How to use this forum

And please draw a schematic diagram of your connections. Also let us know what steps you've already taken to rectify your problem.

OldSteve:
And please draw a schematic diagram of your connections. Also let us know what steps you've already taken to rectify your problem.

In addition to the items suggested by Steve, I suggest the following.

It would likely be helpful if you uploaded an in focus picture of your setup. It can often help to take the item outside in order to get a lot of light. Use these instructions to insert uploaded images.

I would be good to have links to the parts you're using.