Hi Antonio, I've been reading your response and analyzing the component ADXL345P. Specifically, to initialize the accelerometer, if databuf [0] corresponds to ADXL345_THRES_TAP register (depending on the component datasheet), databuff [1] corresponds to the OFSX register (address 0x1E), then databuff [16] should be for POWER_CTL BW_RATE register and not as shown on the driver, so I still do not understand the order used in the driver. On the other hand, why do you use as a management device address # define ADXL345_ADDRESS 0x53?
Thanks. 2011/12/30 Antonio Liñán C. <[email protected]> > Sorry for the delayed response, I'm on vacations :) > > I believe it's set up that way because in databuff[0] the address of the > first register is passed (0x1D) and from there the next registers (0x1E, > 0x1F...) are configured with the following corresponding values stated > in databuf[1-18]. > > Regards, happy holidays! > > Antonio. > > On Tue, 2011-12-27 at 21:02 +0100, antonio rosa wrote: > > Hi to all, > > > > I'm using the driver ADLX345 provides by Zolertia and I have a > > question. Them you granted the resource I2C and you are in the case > > ADXLCMD_START, > > why you fill the two first positions of databuf with a value that > > refering to the same register THRES HOLD TAP (I don't know if the > > databuf[1] is for THRESH_TAP or OffsetX). Can you help me, please ? > > databuf[0] = ADXL345_THRESH_TAP; > > databuf[1] = 0x40; //ADXL345_THRESH_TAP > > > > > > > > > > > > > > > > > > > > > > > > > > > > _______________________________________________ > > Tinyos-help mailing list > > [email protected] > > https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help > > >
_______________________________________________ Tinyos-help mailing list [email protected] https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help
