Proposed Fold-up Bed Hinge

I need to fit a single bed into the spare bedroom. The best way to do this is probably a wall bed that folds up horizontally, but OUCH they’re expensive!

DIY it is then…

The most complex part is likely to be the hinge mechanism. In a horizontal fold there’s much less work and distance to lift, (Physics?) so I think I can get away with not needing shocks or springs to support the bed.

Another problem is that most folding beds are hinged at the unfolded bed’s height, so that the foldout action clears the rear of the unit. This raises the frame up by ~30cm, making the height of the unit much higher than the mattress width.

I’d love to be able to make some fancy 4-point linkage hinge, but that’s a little tough.

Instead, I think this hinge might work:

image

This is a side view of one of the two hinges, when the bed is opened. The wall side of the bed rests on the vertical strut shown, which pivots on the bed frame and the base. The spring allows the strut to hinge outward enough to let the mattress transition between horizontal and vertical, but pulls the strut back to vertical when the bed is fully open or closed. (It can’t go further ‘left’ as the bed frame runs up against the back of the unit.)
The outer side of the bed rests on its own braced legs.

What do you think? Good idea? Terrible?