Most software in the field today (80% is the figure I read - trying to find the article again) takes user input from a screen, queries a database, and sends results back to the user. After developing enough systems like this, you realize only the technologies are changing, not the problems solved. Keeping up with the latest tools does not change the dull repetition of this reality so you can easily lose incentive to keep up. And, frankly, I'm not sure companies need to pay someone with 20 years experience to do such mundane development.
Interviews for my last couple of employers centered more around growth in the organization, ie. understanding business processes, the business' industry, and organizational dynamics, not on technical knowledge. I think there comes a point when organizations begin evaluating a potential employee on potential to grow in the organization rather than grasp of functional vs. imperative paradigms, etc.
If staying a developer is what you really want, then it's probably worth learning another problem domain. Perhaps mining biological data for patterns, etc. (Heck, despite advances in neuroscience we can't explain why a stroke causes memories to "move" to another set of cells in one patient but are lost in another patient. There are plenty of problems to be solved.) Anything that makes the field fresh again. (Of course, you may run into the same problem I stated in paragraph 1.)