I have been there OP and I want you to know that you are doing a fantastic job. You are keeping your little boy fed and safe and warm. You love him, and he will sense that.
I felt exactly like you when my son was 4 weeks old. I used to lie in bed next to him with my eyes tightly closed trying to literally rewind time to get my old life back. I actually felt that there was a greater chance of me successfully time travelling using the powers of my mind than of me being a good mum. I used to wake up and count down the hours until I could sleep again, in 15 minute blocks. I loved him in a sort of abstract way, but I didn't get him and always felt overwhelmed, like he deserved so much better than me as his mum. Also, sleep deprivation is a bastard.
For me things really turned a corner at 8 weeks. I felt much more confident, and I felt like I knew DS much better, that we understood each other and that I could be a good mum to him. But for me at least were still tough until 6 months, and got progressively easier. At around 18 months thinsg really fell into place and now, 2 years on, I genuienly love every single minute I spend with him. We are a team and we love each other.
Things that helped me, in case they also help you:
DP going back to work. Once I was by myself weirdly I felt like the pressure was off, like it was just me and son fending for ourselves as best we could, and it helped me bond with him. No judgement, no one to see my attempts, just me and son doing our own thing.
Going to baby group and meeting up with other mums. Don't get me wrong, I absolutely did not want to do this, in fact, I stood outside of the first one and openly sobbed. But it gave me something to do and the mundane chit chat made me realise that I wasn't alone, that other people were also struggling and most importantly it made me realise that I actually did have lots of positive things to say about my son. I also made lifelong friends at those places.
Making time and effort to do things that I loved with DS. Taking DS for walks in placed I liked, going to my favourite bookshop, going out to a cafe and ordering whatever I liked. Slowly doing more and more things that I wanted to do helped me gain back control of my life and see how I could still enjoy it, which made me a better mum.