Tool/software: Code Composer Studio
Now I am using 28377d and ET1100 to develop a ECAT servo. We use 8 bit Asynchronous µController Interface to transfer data between 28377 and ET1100. As to the EMIF, my configuration is as follows(use TI's demo project "pdi_hal_test_app" as reference):
Emif1Regs.ASYNC_CS2_CR.all = (EMIF_ASYNC_ASIZE_8 | // 8 Bit Memory
// Interface
EMIF_ASYNC_TA_1 | // Turn Around time
EMIF_ASYNC_RHOLD_4 | // Read Hold time
EMIF_ASYNC_RSTROBE_10 | // Read Strobe time
EMIF_ASYNC_RSETUP_6 | // Read Setup time
EMIF_ASYNC_WHOLD_2 | // Write Hold time
EMIF_ASYNC_WSTROBE_8 | // Write Strobe time
EMIF_ASYNC_WSETUP_4 | // Write Setup time
EMIF_ASYNC_EW_ENABLE | // Extended Wait
EMIF_ASYNC_SS_DISABLE // Strobe Select Mode
);
Now the problem is: When runs in DC mode with Twincat as the ECAT master, Twincat delivers 0x1b error about every 20 seconds. the PDI error register 0x30d's value is alwas 0xff rather 0. I have asked ETG for help. After I changed the watchdog from reading ET1100's register 0x440 to software watchdog which only use 28377 own timer, there's no 0x1b error any more(0x1b means sync manager watchdog error or timeout). This means there is something wrong in PDI interface, which results in reading 0x440 from ET1100 error. And if ignore this error, other things like PDO and SDO both work nomally.
In fact, if I use the following TI's demo project "pdi_hal_test_app" EMIF configuration absolutely, another problem often occurs when ECAT master change slave's state from PREOP to OP, the error says "read status 0x04, and status 0x08 expected", then the slave's state falls into SAFEOP ERR. And the two EMIF configuration's difference is I add two CLKs in each EMIF read stage. This may make sure PDI's read operation more stable. But I am not sure what I guess is right or not. And If i add 4 read CLKs or more, the ECAT servo slave will always falls in INIT ERR state. So I am really confused with EMIF configuration. Could you give me some advice and help? Thank you very much.
Emif1Regs.ASYNC_CS2_CR.all = (EMIF_ASYNC_ASIZE_8 | // 8Bit Memory
EMIF_ASYNC_TA_1 | // Turn Around time
EMIF_ASYNC_RHOLD_2 | // Read Hold time
EMIF_ASYNC_RSTROBE_8 | // Read Strobe time
EMIF_ASYNC_RSETUP_4 | // Read Setup time
EMIF_ASYNC_WHOLD_2 | // Write Hold time
EMIF_ASYNC_WSTROBE_8 | // Write Strobe time
EMIF_ASYNC_WSETUP_4 | // Write Setup time
EMIF_ASYNC_EW_ENABLE | // Extended Wait
EMIF_ASYNC_SS_DISABLE // Strobe Select Mode
);
2. Besides, I find EMIF write operation is much slower than EMIF read operation. That is, *XMEM_ps++ = *pTxData++ takes about 21 us, while read operation takes about 300ns/BYTE. I am not sure whether this has something to do with the 0x1b ERROR or not. Thank you.