Our son requires his head to be elevated for breathing and his knees to be bent for his hips. I took the specs from his home/hospital bed and built one with easily sourced lumber, screws, 12v actuators (the motors that lift the bed), and switches.
Your design might vary based on the height/length of the person you’re building the bed for. My son is about 4′ 10″ and the bed is 75″ inches long.
Lumber: 2x4s, 1×3 slats
Screws: 2 1/2″ and 1 1/4 or 1 1/2″
Actuators: 16″ for head and 12″ for the knees
Amazon – 12″ Actuator
Amazon – 16″ Actuator
Amazon – Reset Rocker Switch to control Actuators