At least for me, I enjoy trying to solve problems using code. Kind of like how some people enjoy solving cross-words, math problems, and what have you.
As for the larger things that could potentially lead to a business, those types of problems usually come from something I encounter at work. If I'm stuck using software that sucks, identify some obvious demand, etc.