I'm trying to build this example: ADC_DAC.zip.
It's for the RM46x. The following variables are declared in sys_main.c
uint32 adc1_EV_results[43200]; uint32 adc1_G1_results[43200];
and notification.c:
uint32 adc1_EV_results_copy[43200]; uint32 adc1_G1_results_copy[43200]; extern uint32 adc1_EV_results[43200]; extern uint32 adc1_G1_results[43200];
int i = 0; if (channel == 0) { for (i=0; i<86400; i++) { adc1_EV_results_copy[i] = adc1_EV_results[i]; } } else if (channel == 1) { for (i=0; i<86400; i++) { adc1_G1_results_copy[i] = adc1_G1_results[i]; } } else { while(1); // should never get here }
Why is the counter the double of the array lenghth?