| aSRF08_GetRange | Index |
Definition:
Parameters:
| stemLib | - | An opaque library reference representing the aStem library which manages the communication with the BrainStem modules. |
| router | - | The IIC address of the module that is to be used to communicate with the SRF08 sensor. This need not be the router. |
| srf08address | - | The IIC address of the SRF08 sensor that is to perform the ranging. There are 16 available addresses starting at 0xE0 (the default) in increments of 2 (0xE0, 0xE2, etc.) |
| units | - | There are three units available. There are defines for each: aSRF08_INCH, aSRF08_CM, and aSRF08_MS for measurement in inches, centimeters, and milliseconds respectively. |
| pVals | - | This is storage where the results will be stored. This must be valid memory and have enough capacity to handle the specified number of readings (2 bytes per reading). |
| nVals | - | The number of readings to report (filling the pVals array). This number must be between 1 and 17. |
Return Value:
Description:
| Note: | The SRF08 ranger cannot handle the 1MBit IIC communication the BrainStem defaults to. You need to explicitly set the IIC baud rate to 400kb or less using the cmdVAL_SET command. |
Related: