Skip to content

Commit

Permalink
beginning underscore for members exitTime and tripTime
Browse files Browse the repository at this point in the history
  • Loading branch information
mochoy committed Jun 17, 2017
1 parent 991c309 commit 059b042
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions SmartBlaster/SmartBlaster.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,7 @@ void SmartBlaster::resetChronoVals(void) {
}

double SmartBlaster::calculateChronoReadings(double firstTime, double secondTime) {
if ( (tripTime > -10) && (exitTime > -10) ) {
if ( (_tripTime > -10) && (_exitTime > -10) ) {
resetChronoVals();
return (DART_LEGNTH_FEET) / ((secondTime-firstTime)/1000000.0);
}
Expand All @@ -188,7 +188,7 @@ void SmartBlaster::chrono(void) {
_tripTime = micros();
//when tripped and expecting second value
} else if ( (_tripTime != -10) && (_exitTime == -10) && (map(analogRead(_AMMO_COUNTING_INPUT_PIN), 0, 1023, 0, 100) < IR_MAP_TRIP_VAL) ) {
exitTime = micros();
_exitTime = micros();
initDisplayChronoReadings(calculateChronoReadings(_tripTime, _exitTime));

countAmmo();
Expand Down

0 comments on commit 059b042

Please sign in to comment.