Agreed. if it weren't for Halo and the subsequent lock-in to that console, I suspect the XBox wouldn't have really gotten anywhere.
Consider that the XBox was still a massive money-sink for years on end, and I daresay that it has still not yet reached its overall ROI, let alone a profit. If it were built/sold by any company other than Microsoft (or similar behemoth-sized), the company would have gone broke years ago from it. They may eventually reach ROI and turn a profit, but I think that's still a couple of years off at best, and after that, I have no idea what kind of profit margin it would have.
My best guess is that Microsoft wanted to (and is still desperately trying to) make the XBox into a home media center, to the exclusion of everything else (DVRs, dedicated DVD/Blu-Ray players, etc). They may still latch on a cablecard/sat receiver, and maybe some tie-in to "The Internet of Things" (or whatever buzzphrase is being used nowadays), so that it becomes the brain of the "smart home"(ditto), so as to lock-in a potential market. But then, people being what they are, they stubbornly go out and buy tablets, 3rd-party home alarm/HVAC controllers, decide to use Dish instead of DirecTV or Comcast, run out and buy a Sling/AppleTV/Roku box, etc. I think it's that diversity (and the entrenchment of the players in it) which has kept them from making that final drive. This in the end may well turn the whole XBox thing into a permanent anchor on Microsoft's profit margins unless costs are cut somewhere... which makes me wonder why the shareholders haven't demanded that the console be made profitable or else.