Announcements

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

cross mob
TinkerML
Level 1
Level 1
10 sign-ins 5 replies posted 5 sign-ins

I have redesigned the hardware for the BGT60TR13C sensor.

I'm also using the library at the link below for testing:

https://github.com/Infineon/sensor-xensiv-bgt60trxx

Here is the radar setting:

2024-01-30_154028.png

I have enabled the data test mode as below:

   /* Enable sensor data test mode. The data received on antenna RX1 will be overwritten by 
       a deterministic sequence of data generated by the test pattern generator */
    if (xensiv_bgt60trxx_enable_data_test_mode(&sensor.dev, true) != XENSIV_BGT60TRXX_STATUS_OK)
    {
        CY_ASSERT(0);
    }

I'm trying to read the FIFO data from the BGT60TR13C radar sensor via FIFO, but it seems it always returns the wrong data.

2024-01-30_152105.png

The fifo_buffer variable is declared as uint16_t fifo_buffer[64];

I have set the 8-bit SPI mode and used 21MHz for the test to read FIFO data.

2024-01-30_153906.png

The data of each element in the fifo_buffer array is always smaller than 0xFF, but the value of the test_word variable is higher than 0xFF.

Here is the result after I changed to use SPI 16-bit mode:

2024-01-30_162030.png

The fifo_buffer always returns the fixed array in test mode, is it correct?

I found the line 

 

	uint16_t test_word = XENSIV_BGT60TRXX_INITIAL_TEST_WORD;

 

In my program, the value of XENSIV_BGT60TRXX_INITIAL_TEST_WORD = 1.

How can I find the correct value of the XENSIV_BGT60TRXX_INITIAL_TEST_WORD variable?

Could you please give me some suggestions to find out what is wrong with my issues ??

Thanks

0 Likes
1 Solution
Deepa_V
Moderator
Moderator
Moderator
50 likes received 250 replies posted 5 likes given

Hi @TinkerML ,

We have noted an issue on the library. Will rectify it soon. 

Best Regards,

Deepa

View solution in original post

0 Likes
6 Replies
Deepa_V
Moderator
Moderator
Moderator
50 likes received 250 replies posted 5 likes given

Hi @TinkerML ,

You have to enable LFSR_EN bit of the SFCTL register to enable the data test mode and that too after a FIFO reset. 

Please refer Table 27 of the datasheet for the same.

And the LFSR will actually generate a pseudo random bit M-sequence that can be used to fill up the FIFO instead of the ADC data. The implemented LFSR is described by the following polynomial: x12+x11+x10+x4+1.

Regarding the initial value of LFSR :

/** Initial value of the LFSR test sequence generator. **/
#define XENSIV_BGT60TRXX_INITIAL_TEST_WORD              (0x0001U)

 

Best Regards,

Deepa

0 Likes
TinkerML
Level 1
Level 1
10 sign-ins 5 replies posted 5 sign-ins

Hi @Deepa_V !

Thank you for the information!

Yes, I have already enabled the LFSR_EN bit of the SFCTL register.

And the BGT60TR13C also returns a constant array. I have changed some of the different SPI frequencies and got the same constant array.

 

2024-01-31_131921.png

But the value of FIFO does not match with the polynomial: x^12 + x^11 + x^10 + x^4 +1. 

TinkerML_1-1706682490614.png

I still do not clearly understand the result as above.

Could you please let me know is it correct?

Thanks!

0 Likes
Deepa_V
Moderator
Moderator
Moderator
50 likes received 250 replies posted 5 likes given

Hi @TinkerML ,

This is the code snippet that generates the sequences in the data test mode implementing the polynomial for LFSR. 

Deepa_V_0-1706690658355.png

The idea is that in this test mode, the data is not from ADC but from this linear feedback shift register (LFSR). That's what the digital pipeline depicts !
We're checking out the values and trying to reproduce the same at our end. Will soon get back to you on this !

Best Regards,

Deepa

0 Likes
lock attach
Attachments are accessible only for community members.
TinkerML
Level 1
Level 1
10 sign-ins 5 replies posted 5 sign-ins

Hi @Deepa_V !

I would like to send you the read-out data from the data test mode, please refer to the attached file for more information.

2024-01-31_160848.png

In my program, the value of XENSIV_BGT60TRXX_INITIAL_TEST_WORD is 1.

	uint16_t test_word = XENSIV_BGT60TRXX_INITIAL_TEST_WORD;

So, the value of the test_word variable is start from 1;

Thanks

0 Likes
TinkerML
Level 1
Level 1
10 sign-ins 5 replies posted 5 sign-ins

 Hi @Deepa_V !

I have also tried some other ways to find out  the problem as below:

  • Change another BGT60TR13C sensor
  • Change SPI frequency
  • Change the test_word variable
  • Turn off the data test mode => FIFO data have changed on every reading.

But I still got the same result, the FIFO data also returned the same constant array as below:

TinkerML_0-1706758871156.png

 

Thanks!

0 Likes
Deepa_V
Moderator
Moderator
Moderator
50 likes received 250 replies posted 5 likes given

Hi @TinkerML ,

We have noted an issue on the library. Will rectify it soon. 

Best Regards,

Deepa

0 Likes