Yosef Karo, Translation:Shulchan Aruch — Orach Chaim 627…
“ However, if one ascends from the head and two from the foot [of the bed] and beams (meaning long pieces of wood like handle of a pike) are placed between them, it is permitted to spread sheets over it and sleep under because it has no handbreath-wide roof above. This applies when they are not higher than ten handbreaths. ”
