Promising technologies such as sensors, networking, and edge have led to many smart healthcare solutions to monitor and track patient health status. The health sector is now experiencing a significant transformation from conventional patient care to a smart healthcare environment. Smart health care allows medical professionals to monitor patients remotely and visualize the disease prognosis effectively. The Internet of medical things connect patients, doctors, and medical equipment via wireless networking technologies to process the data with Artificial Intelligence models. One of the domains of automated health care systems is to alert the caregivers and hospital on emergency conditions. This research study is a novel work that aims to help the caregivers of somnambulism patients attend to them in case of emergency. Sleep quality improves the health and work efficiency of any person. The caregivers of sleepwalking patients suffer from lack of sleep as the patient gets active during the night hours. The model is based on fall detection and sleep detection from wearable sensor data. The fall detection model includes feature selection by LASSO and classification by ensemble classifier. The proposed methodology shows improved performance for the fall detection model for all ensemble machine learning classifiers.