The Luna showroom in New York / Luna

Mattress cover will also ensure that temperature is perfect while you’re in the Land of Nod

A new smart mattress hopes to create the perfect conditions for sleeping and waking up by controlling your house.

Luna’s new device fits around the mattress like a cover, and monitors whether those sleeping on it are asleep. When it senses that they are, it can power down lights or change heating settings. And when it detects that they’re waking back up, it can start brewing coffee or turn the lights back on.

And while you’re asleep, it will track the room temperature and how much sleep you get, creating the perfect conditions. The bed has “dual zone temperature”, which means that it can monitor differnet sides of the bed separately.

The device is being funded through a campaign on Indiegogo, which promises to “Turn Your Bed into a Smartbed”. It normally costs $249 (£165), but can be bought for $179 through the Indiegogo campaign.

Techcrunch saw the product in a showroom and said that it could accurately tell when demonstrators pretended to go to sleep and wake up.

One of the co-founders of the company told the website: “For men, the most exciting part is our interaction with smart home devices — so the lights, your Netflix, Spotify.

“For women, instead, it’s temperature we have seen most of the couple they fight about temperature while men love to sleep cold while women love to sleep hot and through the different temperature and zone control, it’s something we can solve.”

Data is stored on the smart mattress cover itself, and then sent to Luna for storage and analysis.