sparkfun / SparkFun_Bio_Sensor_Hub_Library

26 stars 33 forks source link

Example File and Library File Corrections #7

Closed allmysparetime closed 4 years ago

allmysparetime commented 4 years ago

Example file: Example3_modify_AGC_Algo.ino

Line 65: Extra ")" at end of line causes compiler error. int error = bioHub.setAlgoRange(algoRange));

Line 102: Spelling ("Configuring"). Serial.println("Configuing Sensor.");

Library file: SparkFun_Bio_Sensor_Hub_Library.cpp

Line 911: Error results in incorrect initialization of "setAlgoSensitivity" and "setAlgoSamples" in setup() section of example. Currently: uint8_t statusByte = writeByte(CHANGE_ALGORITHM_CONFIG, SET_AVG_SAMPLES, AGC_SENSITIVITY_ID, avg);

Should be: uint8_t statusByte = writeByte(CHANGE_ALGORITHM_CONFIG, SET_AVG_SAMPLES, AGC_NUM_SAMP_ID, avg);

edspark commented 4 years ago

Fixed - I even had put the correct HEX value AGC_NUM_SAMP_ID in the comments but had failed to put it as an argument in the call to writeByte. Nice catch and fixed here.