My H also blanks me when he comes to see kids and I don't sit with him when he is with kids as I see it as his "me time" with his children. It was hard at the beginning but now I'm fine with it! I reckon this is what you should do as it feels you are expecting him to interact with you when he is with kids.
Don't blame yourself for writing that text, we all have done it. Before you attempt to reply come and vent here and I'm sure after that you won't feel the need to reply.