Skip to content
Permalink
Browse files
Added checkEBS function
  • Loading branch information
Serge Matebook committed Jul 19, 2019
1 parent a30053c commit 1679ac03df619bde7ae3f3b589c934ad5f8de91e
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 1 deletion.
@@ -190,6 +190,20 @@ public:
}
}

bool checkEBS()
{
if (vcu2ai_data.VCU2AI_AS_STATE == fs_ai_api_as_state_e::AS_EMERGENCY_BRAKE)
{
std::cout << "Detected emegrency break." << std::endl;
running = false ;
return true ;
}
else
{
return false ;
}
}

void deploy_EBS()
{
send_ebs = true ;
@@ -16,5 +16,6 @@ BOOST_PYTHON_MODULE( fspycan_ext )
.def( "get_right_pulse", &FsPyCan::get_right_pulse)
.def( "get_yaw", &FsPyCan::get_yaw)
.def( "deploy_EBS", &FsPyCan::deploy_EBS)
.def( "set_AS_Finished", &FsPyCan::set_AS_Finished);
.def( "set_AS_Finished", &FsPyCan::set_AS_Finished)
.def( "checkEBS", &FsPyCan::checkEBS);
}

0 comments on commit 1679ac0

Please sign in to comment.