A mattress topper which uses machine learning and novel sensors to detect the onset of pressure ulcers before they develop on the skin surface to enable early interventions. It monitors patient movement and automates the documentation to provide a holistic solution for the prevention of pressure ulcers.