Post Go back to editing

ADXL372 Autosleep mode fails no interrupt generated

Category: Datasheet/Specs

Hello,

I'm facing a serious probleme with the ADXL372:

I'm trying to put the ADXL372 to autosleep mode, int1 linked to activity (xyz) and int2 linked to inactivity (xyz) , but no interrupt is generated when I tilt the sensor.

this is how I set the rigsters :

adxl372_is_connected(&adxl_device);

adxl372_reset(&adxl_device);

adxl372_set_op_mode(&adxl_device,ADXL372_STANDBY);

adxl372_set_bandwidth(&adxl_device,ADXL372_BW_800HZ);//

adxl372_set_odr(&adxl_device,ADXL372_ODR_6400HZ ); //

adxl372_set_wakeup_rate(&adxl_device, ADXL372_WUR_512ms);

adxl372_set_activity_threshold(&adxl_device,ADXL372_ACTIVITY, 40, true, true); --> referenced active

adxl372_set_activity_threshold(&adxl_device, ADXL372_INACTIVITY, 100, true, true); --> referenced active

adxl372_set_activity_time(&adxl_device, 100); // X 3.3ms if ODR = 6400 Hz else 6.6ms

adxl372_set_inactivity_time(&adxl_device,100 ); // X 13ms if ODR = 6400 Hz else 26ms

adxl372_interrupt_config(&adxl_device, int1,int2);

adxl372_set_lpf(&adxl_device,ADXL372_LPF_DISABL ); //

adxl372_set_hpf(&adxl_device,ADXL372_HPF_ENABEL); //

adxl372_set_filter_settle(&adxl_device, ADXL372_FILTER_SETTLE_16); //

adxl372_set_act_proc_mode(&adxl_device, ADXL372_LOOPED);

adxl372_set_autosleep(&adxl_device,true);

Can anybody tell me what is wrong in my doing ? hwo can I be sur that the device is in autosleep mode ? why no interrupt is generated ?

For information : I read back all register to check that what I write is realy wrinten physicaly in the device.

I'm waiting for your help

Parents
  • Hi  , 

    thank you for all the detail on your post. 

    From what I see on the configurations, the Activity is set to referenced mode. threshold is set to 0.4g, with an activity timer of 330ms (100x3.3ms). This means that the activity will be detected only if the acceleration input is over the activity threshold for at least those 330ms. 

    Notice that the ADXL372 noise RMS at 1600Hz ODR is 3.5 LSB, which is 0.35g RMS, converting to peak noise that is 1.15g! And this is when ODR is 1600Hz, in your case ODR is 6400Hz (peak noise is about 3g). So it makes sense that the activity is never triggered because the activity block does not see a signal that is over the threshold for at least 330ms, due to the random behavior of white noise. 

    If you for example set the activity threshold to 0LSB, the activity should trigger when a single sample is detected over the activity threshold, and in this case, activity should trigger continuously due to the noise.  

    For such a low activity threshold I would recommend enabling the Low Pass Activity Filter: 

    adxl372_set_lpf(&adxl_device,ADXL372_LPF_ENABLE); //

    The cutoff frequency for this filter is fixed at 10Hz and is right before the Activity logic, which helps reduce the RMS noise and makes possible to detect activity events at thresholds <0.5g, such as your case.

    Please let me know if this works for you, 

    regards, 

    Pablo. 

Reply
  • Hi  , 

    thank you for all the detail on your post. 

    From what I see on the configurations, the Activity is set to referenced mode. threshold is set to 0.4g, with an activity timer of 330ms (100x3.3ms). This means that the activity will be detected only if the acceleration input is over the activity threshold for at least those 330ms. 

    Notice that the ADXL372 noise RMS at 1600Hz ODR is 3.5 LSB, which is 0.35g RMS, converting to peak noise that is 1.15g! And this is when ODR is 1600Hz, in your case ODR is 6400Hz (peak noise is about 3g). So it makes sense that the activity is never triggered because the activity block does not see a signal that is over the threshold for at least 330ms, due to the random behavior of white noise. 

    If you for example set the activity threshold to 0LSB, the activity should trigger when a single sample is detected over the activity threshold, and in this case, activity should trigger continuously due to the noise.  

    For such a low activity threshold I would recommend enabling the Low Pass Activity Filter: 

    adxl372_set_lpf(&adxl_device,ADXL372_LPF_ENABLE); //

    The cutoff frequency for this filter is fixed at 10Hz and is right before the Activity logic, which helps reduce the RMS noise and makes possible to detect activity events at thresholds <0.5g, such as your case.

    Please let me know if this works for you, 

    regards, 

    Pablo. 

Children
  • Hi Pablo,

    Thank's for your reply.

    For Now I want be sur that I can configure the ADXL372 autosleep mode and generate interrupt when detecting activity and incativity.

    Can you please give me a configuration example? you can propose the activity threshold value, referenced or not, ....I want just a working example.

    I m waiting for your reply.