Inaccurate anomaly detection gives the fatal impact that causes a domino effect and affecting the entire system, in an embedded system application. This paper proposes a data anomaly framework for event-based detection in embedded systems using an online machine learning scheme. The main focus of this paper is to show the performance improvement of online learning schemes in comparison to offline learning. The proposed system automatically processes time-series data, which includes trained features and labels of abnormal data. Robustness of the proposed system scheme is evaluated using logistic regression and neural network algorithms. The simulation results show that the accuracy of the proposed approach is more than 90% as compared to offline learning.