ADE7880 issue in power up and I2C communication

Hi all,

i am working on waveform sampling mode of ADE7880 . i have facing issue in initialization , i have gone through the datasheet , and my initialization code is

//.........ADE788 RESET ...................
HAL_GPIO_WritePin(GPIOE, GPIO_PIN_9, GPIO_PIN_RESET); //Reset pin low
HAL_Delay(100);

//.........PM0 set and PM1 reset.................
HAL_GPIO_WritePin(GPIOA, GPIO_PIN_5, GPIO_PIN_SET); // PM0 ->1
HAL_GPIO_WritePin(GPIOA, GPIO_PIN_6, GPIO_PIN_RESET); //PM1 ->0

//.........ADE788 RESET conti...................
HAL_GPIO_WritePin(GPIOE, GPIO_PIN_9, GPIO_PIN_SET);//Reset ->1

HAL_Delay(1000); // wait 1 sec for now IRQ1 go low when part is ready to communicate.

r = HAL_I2C_IsDeviceReady(&hi2c1, 0x38, 3, 5);

I am using STM32f407 uc , from one github project i found that DEV_addresss of ade7880 is 0x38, so i put it to  test the i2c communication but it Returns HAL_ERROR

is any problem in my code of initialization - and i just initialized IRQ dont know what next...

help plz

Thanks in Regards,



nil
[edited by: vivekpkd at 6:36 AM (GMT -4) on 8 Oct 2021]