cancel
Showing results for 
Search instead for 
Did you mean: 

ADC1283 Not Returning Valid Data with PIC32MZ2048EFH100

Tushar_raval
Associate II

Hello STM Support Team,

I am currently using the ADC1283 to acquire analog data with the PIC32MZ2048EFH100 microcontroller via SPI.

I have verified that the MCU’s SPI module works correctly when tested independently. However, when interfacing with the ADC1283, the device is not returning valid conversion data and consistently responds with 0xFF.

At this point, I am unsure whether the issue is hardware-related or software-related. I am sharing the following for your review:

  • Firmware source files (.C and .H) (I referred one of your example firmware for ADC1283 from any online portal and created logic). 

  • SPI configuration details

  • Schematic diagram

  • logic analyzer waveform.

Could you please review them and help identify the root cause of the issue?

Our project is currently in the testing phase, so resolving this issue is quite urgent. Your prompt support would be greatly appreciated.

Thank you in advance.

Best regards,
Tushar

1 ACCEPTED SOLUTION

Accepted Solutions
Chris21
Senior III

I think you have SDI and SDO reversed, SDO should go to Din.

View solution in original post

5 REPLIES 5
Peter BENSCH
ST Employee

Unfortunately, you only attached ‘hardware Schematic1.jpg’ with a practically illegible 96dpi, so that neither the type of level translator nor its device number (Uxx) can be read. If it is one of the suspected TXS0104 or TXB0104, please check whether you are controlling OE correctly: typically, SS is low-active with SPI, but the level translator works in reverse.

Regards
/Peter

In order to give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.

I am using TXS0104EQPWRQ1 level translator.   I am attaching the schematic in pdf format for batter resolution.

I also tested the voltage of CS pin from both the site during CS high and low condition. it changes the voltage level properly.

as per the datasheet the OE pin is only for enable and disable the TXS0104EQPWRQ1 level translator.

26754bce-497a-4044-9dfc-1bf374d33ceb.jpg

Best regards,
Tushar

Thank you for the PDF, before it looked to me as if OE was controlled by SS.

Have you tried controlling U9 directly instead of through U12 (of course supplying U9 with 3.3V instead of 5V)?

In order to give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.
Chris21
Senior III

I think you have SDI and SDO reversed, SDO should go to Din.

Hello Chris, @Peter BENSCH 

yes, this is a good observation. 

I swapped the SDO and SDI and tested. 

Now ADC is working and providing data through the SPI.

Thanks for providing solution.