Yeah, since you heard the sound in your dream, you became lucid! It doesn't matter if you immediately woke up, you WERE in fact lucid for a second