Analog Read Block Duplication

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

Analog Read Block Duplication

1,044 次查看
peaces
Contributor III

Hello everyone,

I want to read more analog values in the "EQADC_Push_ComMand" block but I am not allowed to increase the "Number of Commands" value (more than four) is there any other solution?
When I use multiple EQADC_ISR blocks in Freemaster and monitor the incoming data one by one, there is a problem with the last transmitted data.
Problem: reading only once on the last data read.

 

Analog.PNG

Data1.PNG

Data2.PNG

Screenshots taken at different times as data continues to flow.
Marked unchanged data.

0 项奖励
回复
2 回复数

1,004 次查看
peaces
Contributor III

Hello @mariuslucianand 
I want to read data using all the analog inputs in the image, but I cannot do this because of the 4 operations allowed by the EQADC block. Since there is no solution in the example given, what I want to do is in the appendix.

peaces_0-1623939475213.png

 

 

0 项奖励
回复

1,017 次查看
mariuslucianand
NXP Employee
NXP Employee

Hello @peaces ,

Sorry for my delayed answer!

We cannot increase the "Number of commands" values because, according to the Manual, "Every CFIFO and RFIFO, including CFIFO0, has four entries."

But having a look at the screenshots you've provided, it looks like you are using only a single block of EQADC Push Command, probably with 4 commands, each one ending in a different result buffer. What you can do, is to use multiple EQADC Push Command blocks, each one inserting 4 commands in a different CFIFO and each command to store the results in a different RFIFO. Basically, you can convert 4 values using CFIFO0 to RFIFO0, the next 4 using CFIFO1 and RFIFO1, and so on. Of course, you have to enable the CFIFOs in the ADC Config block.

mariuslucianand_0-1623845689936.png

Please have a look at the attached model.

For the FreeMaster, you can try using the interrupts mechanism. For that, you have to open the FreeMaster config block, and select short or long interrupt (in long it will handle all the data FreeMaster data transfer) with an increased priority higher than the RFIFO interrupts.

Hope this helps,

Marius

0 项奖励
回复