AnsweredAssumed Answered

DASP-TS201s wrong read datas

Question asked by oreh-o@mail.ru on Nov 6, 2013
Latest reply on Nov 21, 2013 by MaheshN

Helo all,

 

  I have the multiprocessing system from four processors (adsp-ts201s),sdram and external memory FPGA Altera Cyclone
  where ram is 0x1000 words on 64 bit datas.
  If writing datas through cluster bus from processor to processor or to SDRAM or to memory cyclone and after reading this dates
  these datas is not right because from chache.
  Cache is off.
  The datas reading correct if set several cycles reading in function.
  Why is it? 
 
  Best regards,
  Oleg
 
 
 
It is cache:
########################## 
asm("J0 = CACMD_DIS;; ");
asm("CACMDB = J0;; ");
##########################

 

It is function:
typedef unsigned int UINT;

 

  UINT DataMemoryTest( UINT *start_memory, UINT lenght_memory)
{
  UINT   i,errors=0;
volatile  UINT   *memory_temp; 

//************************Writing in memory pattern 0xAAAAAAAA*******************

 

  memory_temp = start_memory;
 
          for(i=0;i<lenght_memory;i++)
          {
            *memory_temp++ = 0xAAAAAAAA;

 

          }          
         
               
//Reading from memory pattern 0xAAAAAAAA
  memory_temp = start_memory;
   
          for(i=0;i<lenght_memory;i++)
          { 
                    
//Check to error
               if((*memory_temp++) !=  0xAAAAAAAA)
               {                
                  errors++;
                  WrStructAddrErrors((UINT) memory_temp--);
                                                                
               }              
         
          }
     
//************************Writing in memory pattern 0x55555555*******************

 

  memory_temp = start_memory;
 
          for(i=0;i<lenght_memory;i++)
          {       
            *memory_temp++ = 0x55555555;

 

          }          
         
              
//Reading from memory pattern
  memory_temp = start_memory;
      
          for(i=0;i<lenght_memory;i++)
          { 
                    
//Check to error
               if((*memory_temp++) !=  0x55555555)
               {                
                  errors++;
                  WrStructAddrErrors((UINT) memory_temp--);
                                                                
               }              
         
          }
         
  return errors;
}

Outcomes