He was in stage 4 sleep. His eyes may be open, he may be speaking, walking, or
even doing something that seems purposeful like folding a blanket... but he is asleep. It's a parasomnia.
Trying to awaken the child doesn't help, and may agitate them more. Just hold them, be near them, and keep them safe until it passes.