Skip to content

Commit

Permalink
camera range modified from 25 cm to 30 cm
Browse files Browse the repository at this point in the history
  • Loading branch information
musalman709 committed Apr 13, 2021
1 parent 9699c0a commit dd5dc09
Show file tree
Hide file tree
Showing 6 changed files with 11 additions and 11 deletions.
4 changes: 2 additions & 2 deletions src/modules/AutoMoDeBehaviourAvoidPheromone.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ namespace argos {
CVector2 sResultVector(0,CRadians::ZERO);

for (it = sReadings.BlobList.begin(); it != sReadings.BlobList.end(); it++) {
if ((*it)->Color == m_cColorReceiverParameter && (*it)->Distance >= 4.5 && (*it)->Distance <= 25) {
if ((*it)->Color == m_cColorReceiverParameter && (*it)->Distance >= 4.5 && (*it)->Distance <= 30) {
if ((*it)->Angle.SignedNormalize().GetValue() >= 0 && (*it)->Angle.SignedNormalize().GetValue() <= m_unFOVParameter) {
sColVectorSum += CVector2(1 / (((*it)->Distance) + 1), (*it)->Angle);
}
Expand Down Expand Up @@ -131,7 +131,7 @@ namespace argos {
} else {
m_unFOVParameter = 3.14; // Omni directional view of 360 degree
}

} else {
LOGERR << "[FATAL] Missing parameter for the following behaviour:" << m_strLabel << std::endl;
THROW_ARGOSEXCEPTION("Missing Parameter");
Expand Down
4 changes: 2 additions & 2 deletions src/modules/AutoMoDeBehaviourGoAwayColor.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ namespace argos {
CVector2 sResultVector(0,CRadians::ZERO);

for (it = sReadings.BlobList.begin(); it != sReadings.BlobList.end(); it++) {
if ((*it)->Color == m_cColorReceiverParameter && (*it)->Distance >= 4.5 && (*it)->Distance <= 25) {
if ((*it)->Color == m_cColorReceiverParameter && (*it)->Distance >= 4.5 && (*it)->Distance <= 30) {
if ((*it)->Angle.SignedNormalize().GetValue() >= 0 && (*it)->Angle.SignedNormalize().GetValue() <= m_unFOVParameter) {
sColVectorSum += CVector2(1 / (((*it)->Distance) + 1), (*it)->Angle);
}
Expand Down Expand Up @@ -132,7 +132,7 @@ namespace argos {
} else {
m_unFOVParameter = 3.14; // Omni directional view of 360 degree
}

} else {
LOGERR << "[FATAL] Missing parameter for the following behaviour:" << m_strLabel << std::endl;
THROW_ARGOSEXCEPTION("Missing Parameter");
Expand Down
4 changes: 2 additions & 2 deletions src/modules/AutoMoDeBehaviourGoToColor.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ namespace argos {
CVector2 sResultVector(0,CRadians::ZERO);

for (it = sReadings.BlobList.begin(); it != sReadings.BlobList.end(); it++) {
if ((*it)->Color == m_cColorReceiverParameter && (*it)->Distance >= 4.5 && (*it)->Distance <= 25) {
if ((*it)->Color == m_cColorReceiverParameter && (*it)->Distance >= 4.5 && (*it)->Distance <= 30) {
if ((*it)->Angle.SignedNormalize().GetValue() >= 0 && (*it)->Angle.SignedNormalize().GetValue() <= m_unFOVParameter) {
sColVectorSum += CVector2(1 / (((*it)->Distance) + 1), (*it)->Angle);
}
Expand Down Expand Up @@ -129,7 +129,7 @@ namespace argos {
} else {
m_unFOVParameter = 3.14; // Omni directional view of 360 degree
}

} else {
LOGERR << "[FATAL] Missing parameter for the following behaviour:" << m_strLabel << std::endl;
THROW_ARGOSEXCEPTION("Missing Parameter");
Expand Down
4 changes: 2 additions & 2 deletions src/modules/AutoMoDeBehaviourGoToPheromone.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ namespace argos {
CVector2 sResultVector(0,CRadians::ZERO);

for (it = sReadings.BlobList.begin(); it != sReadings.BlobList.end(); it++) {
if ((*it)->Color == m_cColorReceiverParameter && (*it)->Distance >= 4.5 && (*it)->Distance <= 25) {
if ((*it)->Color == m_cColorReceiverParameter && (*it)->Distance >= 4.5 && (*it)->Distance <= 30) {
if ((*it)->Angle.SignedNormalize().GetValue() >= 0 && (*it)->Angle.SignedNormalize().GetValue() <= m_unFOVParameter) {
sColVectorSum += CVector2(1 / (((*it)->Distance) + 1), (*it)->Angle);
}
Expand Down Expand Up @@ -128,7 +128,7 @@ namespace argos {
} else {
m_unFOVParameter = 3.14; // Omni directional view of 360 degree
}

} else {
LOGERR << "[FATAL] Missing parameter for the following behaviour:" << m_strLabel << std::endl;
THROW_ARGOSEXCEPTION("Missing Parameter");
Expand Down
2 changes: 1 addition & 1 deletion src/modules/AutoMoDeConditionPheromoneDetected.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@
bool bColorPerceived = false;

for (it = sReadings.BlobList.begin(); it != sReadings.BlobList.end(); it++) {
if ((*it)->Color == m_cColorParameter && (*it)->Distance >= 4.5 && (*it)->Distance <= 25) {
if ((*it)->Color == m_cColorParameter && (*it)->Distance >= 4.5 && (*it)->Distance <= 30) {
//LOG << "Distance Pheromone: " << (*it)->Distance << std::endl;
if ((*it)->Angle.SignedNormalize().GetValue() >= 0 && (*it)->Angle.SignedNormalize().GetValue() <= m_unFOVParameter) {
bColorPerceived = true;
Expand Down
4 changes: 2 additions & 2 deletions src/modules/AutoMoDeConditionProbColor.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@
} else {
m_unFOVParameter = 3.14; // Omni directional view of 360 degree
}

} else {
LOGERR << "[FATAL] Missing parameter for the following behaviour:" << m_strLabel << std::endl;
THROW_ARGOSEXCEPTION("Missing Parameter");
Expand All @@ -87,7 +87,7 @@
bool bColorPerceived = false;

for (it = sReadings.BlobList.begin(); it != sReadings.BlobList.end(); it++) {
if ((*it)->Color == m_cColorParameter && (*it)->Distance >= 4.5 && (*it)->Distance <= 25) {
if ((*it)->Color == m_cColorParameter && (*it)->Distance >= 4.5 && (*it)->Distance <= 30) {
//LOG << "Distance Block: " << (*it)->Distance << std::endl;
if ((*it)->Angle.SignedNormalize().GetValue() >= 0 && (*it)->Angle.SignedNormalize().GetValue() <= m_unFOVParameter) {
bColorPerceived = true;
Expand Down

0 comments on commit dd5dc09

Please sign in to comment.