set up to autonomously sample with one sensor
Fork of SI1142 by
Diff: SI1143.h
- Revision:
- 6:50b60d59d568
- Parent:
- 5:3fadc61598bc
--- a/SI1143.h Mon Oct 21 20:12:56 2013 +0000 +++ b/SI1143.h Mon Oct 21 20:35:00 2013 +0000 @@ -185,6 +185,9 @@ /** * Creates a baseline for sampling measurements. * Should be done early in your code and after a reset. + * + * @param ready Tells how many seconds to wait before getting samples from the device. + * @param repeat Tells how many samples to get from each leds on the device. Each repeat takes 12 ms. */ void bias(int ready, int repeat); @@ -239,16 +242,25 @@ /** * Wait for the device to respond, then send it a specific command. + * + * @param cmd Command to send to the device. Read p20 of the datasheet for more details. */ void command(char cmd); /** * Read a register from the device. + * + * @param address Register to read from. + * @param num_data Bytes to read (always 1). + * @return Contents of register. */ char read_reg(/*unsigned*/ char address, int num_data); /** * Write to a register on the device. + * + * @param address Register to write to. + * @param num_data Data that is to be written. */ void write_reg(char address, char num_data);