AnsweredAssumed Answered

CRC on 1446

Question asked by drugoimir on Apr 18, 2014
Latest reply on May 9, 2014 by drugoimir

Hello,

 

i've read that were some issues with the CRC generator on ADAU1442/6,

http://ez.analog.com/message/10660#10660

I've read also the solution proposed by Brett, which consists in clearing the

remaining program ram area and some other tricks to do on the compiled

hex file generated (i' did read it, but not in deep).

Since that discussion was 4 years old and thinking that ADI fixed this into the

last SigmaStudio, i tried "the easy way" using directly the file generated

by sigmastudio, but i see that some weird things are still present:

 

This is a program compiled without CRC check

void default_download_IC_1() {

    SIGMA_WRITE_REGISTER_BLOCK( DEVICE_ADDR_IC_1, REG_START_PULSE_SELECT_IC_1_ADDR, REG_START_PULSE_SELECT_IC_1_BYTE, R0_START_PULSE_SELECT_IC_1_Default );

    SIGMA_WRITE_REGISTER_BLOCK( DEVICE_ADDR_IC_1, REG_CORE_RUN_BIT_IC_1_ADDR, REG_CORE_RUN_BIT_IC_1_BYTE, R1_CORE_RUN_BIT_IC_1_Default );

    SIGMA_WRITE_REGISTER_BLOCK( DEVICE_ADDR_IC_1, PROGRAM_ADDR_IC_1, PROGRAM_SIZE_IC_1, Program_Data_IC_1 );

    SIGMA_WRITE_REGISTER_BLOCK( DEVICE_ADDR_IC_1, REG_SERIALINPUT0_DEFAULT_IC_1_ADDR , R3_SERIAL_INPUT_MODES_IC_1_SIZE, R3_SERIAL_INPUT_MODES_IC_1_Default );

.....

 

This is what i get when i turn on the CRC error check

void default_download_IC_1() {

    SIGMA_WRITE_REGISTER_BLOCK( DEVICE_ADDR_IC_1, REG_START_PULSE_SELECT_IC_1_ADDR, REG_START_PULSE_SELECT_IC_1_BYTE, R0_START_PULSE_SELECT_IC_1_Default );

    SIGMA_WRITE_REGISTER_BLOCK( DEVICE_ADDR_IC_1, REG_CORE_RUN_BIT_IC_1_ADDR, REG_CORE_RUN_BIT_IC_1_BYTE, R1_CORE_RUN_BIT_IC_1_Default );

    SIGMA_WRITE_REGISTER_BLOCK( DEVICE_ADDR_IC_1, PROGRAM_ADDR_IC_1, PROGRAM_SIZE_IC_1, Program_Data_IC_1 );

    SIGMA_WRITE_REGISTER_BLOCK( DEVICE_ADDR_IC_1, PROGRAM_ADDR_IC_1, PROGRAM_SIZE_IC_1, Program_Data_IC_1 );

    SIGMA_WRITE_REGISTER_BLOCK( DEVICE_ADDR_IC_1, PROGRAM_ADDR_IC_1, PROGRAM_SIZE_IC_1, Program_Data_IC_1 );

    SIGMA_WRITE_REGISTER_BLOCK( DEVICE_ADDR_IC_1, PROGRAM_ADDR_IC_1, PROGRAM_SIZE_IC_1, Program_Data_IC_1 );

    SIGMA_WRITE_REGISTER_BLOCK( DEVICE_ADDR_IC_1, PROGRAM_ADDR_IC_1, PROGRAM_SIZE_IC_1, Program_Data_IC_1 );

    SIGMA_WRITE_REGISTER_BLOCK( DEVICE_ADDR_IC_1, PROGRAM_ADDR_IC_1, PROGRAM_SIZE_IC_1, Program_Data_IC_1 );

    SIGMA_WRITE_REGISTER_BLOCK( DEVICE_ADDR_IC_1, PROGRAM_ADDR_IC_1, PROGRAM_SIZE_IC_1, Program_Data_IC_1 );

    SIGMA_WRITE_REGISTER_BLOCK( DEVICE_ADDR_IC_1, PROGRAM_ADDR_IC_1, PROGRAM_SIZE_IC_1, Program_Data_IC_1 );

    SIGMA_WRITE_REGISTER_BLOCK( DEVICE_ADDR_IC_1, REG_SERIALINPUT0_DEFAULT_IC_1_ADDR , R10_SERIAL_INPUT_MODES_IC_1_SIZE, R10_SERIAL_INPUT_MODES_IC_1_Default );

.....

 

In this latter case, it seems that the program memory is being loaded 8 times (?) and  also many registers are not defined.

Here are some, but there are many more:

R3_SERIAL_INPUT_MODES_IC_1_SIZE

R3_SERIAL_INPUT_MODES_IC_1_Default

R4_SERIAL_OUTPUT_MODES_IC_1_SIZE

 

So, what i've to do?

I've to "hack" the compiled hex as per Brett's workaround ?

May i apply the workaround on the "xxx.h, xx_param.h, xx_REG.h" files ?

I'm using those for device control and upload.

 

I'm about finishing this project and i'm missing just this feature, i cannot terminate it without.

 

Thanks for any advice.

Tom

Outcomes