What you are describing is called a DEILD (Dream Exit Initiated Lucid Dream)--a special type of WILD. DEILDing is when you consciously wake up from a dream, stay still and relaxed to stay in REM, and then immediately fall back to sleep without losing conscious awareness--thus a dream forms and you enter it lucidly.

It's one of my favorite techniques, in my opinion. Once you wake up and you're conscious, all you have to do is not move and you're in for a lucid dream within the next 10 seconds.