Add transmission gear position event in PolicyManager
[apps/agl-service-windowmanager.git] / src / policy_manager / policy_manager.cpp
index 20c1e79..a40bb48 100644 (file)
@@ -145,6 +145,19 @@ int PolicyManager::checkPolicy(json_object* json_in, json_object** json_out) {
                          stm::gStmParkingBrakeStateNo2Name[crr_state.parking_brake.state],
                          json_out);
 
+    //     "accel_pedal": {
+    //         "is_changed": <bool>,
+    //         "state": <const char*>
+    //     },
+    HMI_DEBUG("wm", "accelerator pedal state (is_changed:%d state:%d:%s)",
+              crr_state.accel_pedal.is_changed,
+              crr_state.accel_pedal.state,
+              stm::gStmAccelPedalStateNo2Name[crr_state.accel_pedal.state]);
+    this->addStateToJson("accel_pedal",
+                         crr_state.accel_pedal.is_changed,
+                         stm::gStmAccelPedalStateNo2Name[crr_state.accel_pedal.state],
+                         json_out);
+
     //     "car": {
     //         "is_changed": <bool>,
     //         "state": <const char*>