There's really no way to tell what is happening to your knees without a complete examination by a Dr. Many Dr's have payment plans or other financial options. You really don't want to take any chances with your knees, how they work (or don't work) can really effect your quality of life.
That said, I think the first thing I would try is to change my sleep position. Sorry I can't be more helpful.