I a, working on PMOD AD2 Digilent as I2C slave, powered with AD 7991 Chip. The device is connected to FPGA BOARD ZCU 102 via PMOD ports through dot .xdc file . I am working on Verilog hardware language . While working with address verification the device is behaving well as it is returning NACK upon wrong address selection and ACK bit ifIi am addressing it correct which is 7h28. Also i am configuring it via configuration register, where Configuration register is byte long for analog channel for conversion selection and reference voltage selection.
Inputs:
For channel 1 i am providing 1V 1 KHz sine wave input (AC).
For Channel 2 i am providing 1V 1 KHz sine wave input (AC).
For Channel 3 and 4 DC voltage i am applying of Voltage less than 1V .
Onboard reference voltage was 2.048 V but i am using device as 4 channel device that is MODE of reference voltage selection is external that is CR (Configuration register ) is 8'h10 ( 8'b00010000) for channel 1 ADC conversion and use supply voltage as reference voltage.
likewise CR (Configuration register ) is 8'h20 ( 8'b00100000) for channel 2 ADC conversion and use supply voltage as reference voltage.
similarly for each channel selection CR register i am configuring.
Then I am putting I2C stop condition to finish write and start is followed by stop to read Conversion data register (CD) contents, which is 2 bytes long. First 2 bits reserved 00, next 2 bit indicate channel whose data is converted and next 12 bits indicated ADC data being converted analog to digital form.
Observation:
For CHANNEL 1 CD - outputs looks like 0000, 0001, 0003, 00ff, 03ff,07ff, 0fff
For channel 2 CD - outputs looks like 1fff
For channel 3 CD - outputs looks like 3fff
For channel 4 CD - outputs looks like 3fff
Doubt: I am not clear why channel 1 is giving change in voltage levels and not channel 2 . Even though i am applying same input to both and why CD register not returning channel 3 data and why data for channel 3, 4 remains fff.
I have also tried channel 2 input solo 1V 1Khz and channel 1,3 grounded.
Then also output looks like :
For CHANNEL 1 CD - outputs looks like 0000, 0001, 0003.
For channel 2 CD - outputs looks like 1fff only.
Please help on this.
Like if it requires hardware change or i am making mistake in configuration or I2C master is not prefect
Question
Chunnu
Hi ,
I a, working on PMOD AD2 Digilent as I2C slave, powered with AD 7991 Chip. The device is connected to FPGA BOARD ZCU 102 via PMOD ports through dot .xdc file . I am working on Verilog hardware language . While working with address verification the device is behaving well as it is returning NACK upon wrong address selection and ACK bit ifIi am addressing it correct which is 7h28. Also i am configuring it via configuration register, where Configuration register is byte long for analog channel for conversion selection and reference voltage selection.
Inputs:
For channel 1 i am providing 1V 1 KHz sine wave input (AC).
For Channel 2 i am providing 1V 1 KHz sine wave input (AC).
For Channel 3 and 4 DC voltage i am applying of Voltage less than 1V .
Onboard reference voltage was 2.048 V but i am using device as 4 channel device that is MODE of reference voltage selection is external that is CR (Configuration register ) is 8'h10 ( 8'b00010000) for channel 1 ADC conversion and use supply voltage as reference voltage.
likewise CR (Configuration register ) is 8'h20 ( 8'b00100000) for channel 2 ADC conversion and use supply voltage as reference voltage.
similarly for each channel selection CR register i am configuring.
Then I am putting I2C stop condition to finish write and start is followed by stop to read Conversion data register (CD) contents, which is 2 bytes long. First 2 bits reserved 00, next 2 bit indicate channel whose data is converted and next 12 bits indicated ADC data being converted analog to digital form.
Observation:
For CHANNEL 1 CD - outputs looks like 0000, 0001, 0003, 00ff, 03ff,07ff, 0fff
For channel 2 CD - outputs looks like 1fff
For channel 3 CD - outputs looks like 3fff
For channel 4 CD - outputs looks like 3fff
Doubt: I am not clear why channel 1 is giving change in voltage levels and not channel 2 . Even though i am applying same input to both and why CD register not returning channel 3 data and why data for channel 3, 4 remains fff.
I have also tried channel 2 input solo 1V 1Khz and channel 1,3 grounded.
Then also output looks like :
For CHANNEL 1 CD - outputs looks like 0000, 0001, 0003.
For channel 2 CD - outputs looks like 1fff only.
Please help on this.
Like if it requires hardware change or i am making mistake in configuration or I2C master is not prefect
correction
Link to comment
Share on other sites
0 answers to this question
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now