TDA5235 SPI Interface Problem

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
Not applicable
hi,
I am working on TDA5235 Receiver in my project. I interfaced it with SPI. Using SPI i am able Transferring Data from my controller. But i am unable to read data from Receiver. Can you help me How to
read data from TDA registers. I am using MC9SO8DZ60 Freescale Micro Controller.
0 Likes
6 Replies
User270
Level 5
Level 5
5 solutions authored First solution authored
Hi cnu123,

You need to check the setup for SPI interface, the signal quality and timing on SPI bus. Addtional you have to fulfill the protocol for read access.

TDA5235 SPI Slave, definition of pins:
NCS - select input, active low
SDI - data input
SDO - data output
SCK - clock input: Data bits on SDI are read in at rising SCK edges and written out on SDO at falling SCK edges. IDLE clock level is high.

Please check:
Is the SPI Mode correct for SCK idle high and SDI sampled at rising edge, SDO out at falling edge?
Is there a valid select signal NCS?
High level of all signals sufficient?
SCK clock signal < 2.2 MHz, edges ok and noise free (PCB impedance)?
The data are stable when sampled?
Timing is ok, e.g. delay from NCS active signal to begin of transmission? Please refer to the timing characteristics of the SPI bus in the data sheet.

The bus protocol for read access (command + address , data) is shown in attached picture, which you can find in the datasheet as well.
298.attach
0 Likes
Not applicable
thank you for ur response.

I Have checked all the parameters. All are ok as you mentioned. still i am not getting any response from TDA slave.
0 Likes
Not applicable
Hi forix,
i got response from TDA5235. but the waveform i received from TDA is not exact replica. What i sent. In that waveform High to low transition taking much time. May i know the reason and resolution for that one.
0 Likes
User270
Level 5
Level 5
5 solutions authored First solution authored
Hi cnu123,
please provide snapshot of oscilloscope showing the signals NCS, SDI, SDO and SCK. Please tell me as well which command and address was sent on SPI for this snapshot.
0 Likes
Not applicable
HI FORIX,

/* Master Transmit Code */
SPI_Transmit(0x02);
SPI_Transmit(0X19);
SPI_Transmit(0X77);

/* Master Receive Code */
SPI_Transmit(0x03);303.attach304.attach
SPI_Transmit(0xb3);302.attach
u8_lRxData = SPI_Transfer();302.attach
0 Likes
Not applicable
HI forix,
i got the correct wave form after reviewing hardware connections.
Now i am getting correct response from TDA5235 during STEP BY STEP execution. But I am not getting the correct sequence(i.e reading of SPIAT & SPIDT registers ) during RUN time.
During RUN time i have seen response on MISO pin. But those are not same values to previous sent Address and Data values. But During STEP BY STEP debugging those values are equal.
please could you help me where is the problem.
0 Likes