I used my CPAP machine and was able to stay on the bed. I have an extension cord that I keep in the travel bag and I plugged it in behind the tv set. I set the unit on the floor and I had to use the side of the bed nearest the divider curtain, but there weren't any problems with it.
My cord wasn't long enough to go above the curtains like Werner suggests, but I put the CPAP machine back in the travel bag every morning and just stowed the cord behind the tv.
hth