cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Observer
Observer
1,216 Views
Registered: ‎08-05-2017

Error jump and invalid data when running two cores in ZYNQ7020

Jump to solution

1. I am running a freertos(V9.0) in core 0 and bare metal in core1.

2. The Development tool is SDK 2015.1

3. There is a task polling to monitor data  (monitor_task)(the priority is zero).

4. There are error jump in the monitor_task and always read invalid data.(There are no share data with other tasks)

 

What condition will cause this phenomenon??

 

 

0 Kudos
1 Solution

Accepted Solutions
Observer
Observer
1,795 Views
Registered: ‎08-05-2017

Re: Error jump and invalid data when running two cores in ZYNQ7020

Jump to solution

@Bucher,

Thanks for your help,

The problem has already been solved.

1. Add #define configUSE_TASK_FPU_SUPPORT 2 in FreeRTOSConfig.h.

 2. Rewrite the memcpy,memset and memcmp functions.

 

View solution in original post

0 Kudos
4 Replies
Highlighted
Scholar
Scholar
1,192 Views
Registered: ‎03-22-2016

Re: Error jump and invalid data when running two cores in ZYNQ7020

Jump to solution

@ceejliu Can you post some more info like error messages or screenshots? 

Not clear to me.

vitorian.com --- We do this for fun. Always give kudos. Accept as solution if your question was answered.
I will not answer to personal messages - use the forums instead.
0 Kudos
Highlighted
Observer
Observer
1,176 Views
Registered: ‎08-05-2017

Re: Error jump and invalid data when running two cores in ZYNQ7020

Jump to solution

Dear  ,

 

Thanks for your replay.

 

The situation like this:  there is a task(low priority) to monitor the temperature and then check if the value is in the protect range.

                                     1. now the monitor value is 38.0℃.  When calling the function temp_check it will jump to 1)

                                     2. If the value is 51.0℃, sometimes it will jump to 2)

                                   

bool temp_check(float temp)

{

       if (temp > 50)

   {

 1)       //Record error

          return false;

   }

   else if (temp > 40)
   {
  2)     //Record warning
         return false ;
    }

   else

    {

  3)     return true;

    }

}

0 Kudos
Highlighted
Scholar
Scholar
1,163 Views
Registered: ‎03-22-2016

Re: Error jump and invalid data when running two cores in ZYNQ7020

Jump to solution

@ceejliu

The only thing I see that might be a problem is the comparison between a float and an integer. 

I know it sounds silly but try to make the constants all float - eg 50.0f instead of 50

Or conversely, try to convert temp to an integer (lrint or similar). 

Also it might be that the measurements are jumping around. Try to print out every (temp,action) you can and check for outliers.

vitorian.com --- We do this for fun. Always give kudos. Accept as solution if your question was answered.
I will not answer to personal messages - use the forums instead.
0 Kudos
Observer
Observer
1,796 Views
Registered: ‎08-05-2017

Re: Error jump and invalid data when running two cores in ZYNQ7020

Jump to solution

@Bucher,

Thanks for your help,

The problem has already been solved.

1. Add #define configUSE_TASK_FPU_SUPPORT 2 in FreeRTOSConfig.h.

 2. Rewrite the memcpy,memset and memcmp functions.

 

View solution in original post

0 Kudos