Not applicable
Feb 06, 2014
11:39 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Feb 06, 2014
11:39 PM
Hi all ,
I try to read the values of an angle sensor via the SPI bus. ( Infineon TLE 5012)
With only one data line the Chip must be driven in half-duplex mode.
Problem: The Data pin is not tristate in receive Mode( Input Mode ) , no reception is in the RX Buffer?
Does anyone have experience with half-duplex mode?
Her my attemt :
SPI001_WriteData(&SPI001_Handle0,&SendData,SPI001_STANDARD_HPC_OUTPUTMODE );
SPI001_WriteData(&SPI001_Handle0,&data_rx,SPI001_STANDARD_HPC_INPUTMODE );
while((SPI001_GetFlagStatus(&SPI001_Handle0,\
SPI001_FIFO_STD_RECV_BUF_FLAG))!=SPI001_SET)
{}
SPI001_ReadData(&SPI001_Handle0,&ReadData0);
SPI001_WriteData(&SPI001_Handle0,&data_rx,SPI001_STANDARD_HPC_INPUTMODE );
while((SPI001_GetFlagStatus(&SPI001_Handle0,\
SPI001_FIFO_STD_RECV_BUF_FLAG))!=SPI001_SET)
{}
SPI001_ReadData(&SPI001_Handle0,&ReadData1);
Thank you for support
I try to read the values of an angle sensor via the SPI bus. ( Infineon TLE 5012)
With only one data line the Chip must be driven in half-duplex mode.
Problem: The Data pin is not tristate in receive Mode( Input Mode ) , no reception is in the RX Buffer?
Does anyone have experience with half-duplex mode?
Her my attemt :
SPI001_WriteData(&SPI001_Handle0,&SendData,SPI001_STANDARD_HPC_OUTPUTMODE );
SPI001_WriteData(&SPI001_Handle0,&data_rx,SPI001_STANDARD_HPC_INPUTMODE );
while((SPI001_GetFlagStatus(&SPI001_Handle0,\
SPI001_FIFO_STD_RECV_BUF_FLAG))!=SPI001_SET)
{}
SPI001_ReadData(&SPI001_Handle0,&ReadData0);
SPI001_WriteData(&SPI001_Handle0,&data_rx,SPI001_STANDARD_HPC_INPUTMODE );
while((SPI001_GetFlagStatus(&SPI001_Handle0,\
SPI001_FIFO_STD_RECV_BUF_FLAG))!=SPI001_SET)
{}
SPI001_ReadData(&SPI001_Handle0,&ReadData1);
Thank you for support
- Tags:
- IFX
0 Replies