This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

NHET,HTU,Request can't answer

l0 CNT { reg=A,max=7};
l1 SHFT { smode=OR0,cond=UNC,pin=1,data=0xd5};
l2 DJZ { reqnum=0,request=GENREQ,cond_addr=l4,reg=B,data=7};
l3 BR { next=l0,cond_addr=l0,event=NOCOND};
l4 MOV32 { next=l5,remote=l1,type=IMTOREG&REM,reg=NONE,data=0xff};
l5 MOV32 { next=l0,remote=l3,type=IMTOREG&REM,reg=B,data=7};

#define data_num 20
//unsigned int data_table[data_num] = {42,51,85,85,255,166,69,51,85,85,255,255,69,38,27,166,69,51,85,85};

unsigned int data_table[data_num] = {255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255,255};
/* USER CODE END */

void main(void)
{
/* USER CODE BEGIN (3) */
htuInit();
//
hetInit();
//
configNHET1();
//
while(1);
/* USER CODE END */
}

/* USER CODE BEGIN (4) */
void htuInit(void)
{
htuRAM1 ->DCP[0].ITCOUNT = 0x00010000+ data_num;
htuRAM1->DCP[0].IHADDRCT = 0x00000000
|(1U<<23U) /* DCP0 CPx DIR = main memory to NHET */
|(0U<<22U) /* SIZE = 32-bit */
|(0U<<21U) /* ADDMH = 16 bytes */
|(0U<<20U) /* ADDFM = constant mode main memory */
|(1U<<18U) /* TMBA = one shot buffer A */
|(0U<<16U) /* TMBB = one shot buffer B (not rel.) */
|(18U<<2U); /* IHADDR = 0xA => 0x8 PCNT data field */
/* DCP0 CPA startaddress of source buffer */
htuRAM1 ->DCP[0].IFADDRA = (unsigned int)data_table;
/* enable DCP0 CPA */
htuREG1 ->CPENA= 0x00000001;
/* enable HTU */
htuREG1 ->GC = 0x00010000;


}
//
void configNHET1()
{

hetREG1->REQENS = 1 ;

hetREG1->DIR = (1 << PIN_HET_1) ;

hetRAM1->Instruction[1].Control =
(hetRAM1->Instruction[1].Control & 0xFFFFE0FF) |
(1 << 8);
}

purpose:

  I want to send the data_table[data_num] = {42,51,85,85,255,166,69,51,85,85,255,255,69,38,27,166,69,51,85,85} out ,in the pin 1

 using the Nhet

thank you