Compare commits

...
Sign in to create a new pull request.

1 commit

Author SHA1 Message Date
jaseg
87a9415c61 Tune basic demo code for direct lvc driver 2024-11-22 16:04:52 +01:00

View file

@ -13,7 +13,7 @@ int sampling_width = 0x20*8;
int sampling_phase = 0;
uint16_t adc1_raw[128];
uint16_t adc2_raw[COUNT_OF(adc1_raw)];
uint32_t adc1_readings[512];
uint32_t adc1_readings[2048];
uint32_t adc2_readings[COUNT_OF(adc1_readings)];
void debug_plot_hook(void);
@ -423,12 +423,11 @@ void HRTIM1_Master_IRQHandler(void) {
HRTIM1->sMasterRegs.MICR = HRTIM_MICR_MREP;
int t = global_sampling_offset * 0x20 - 0x80 + sampling_phase;
int t = sampling_phase;
HRTIM1->sTimerxRegs[3].CMP3xR = t + 0x20 * 0;
HRTIM1->sTimerxRegs[3].CMP4xR = t + 0x20 * 8;
HRTIM1->sTimerxRegs[1].CMP3xR = t + 0x20 * 22;
HRTIM1->sTimerxRegs[1].CMP4xR = t + 0x20 * 14;
GPIOC->BRR = (1<<10);
HRTIM1->sTimerxRegs[1].CMP4xR = t + 0x20 * 6;
}
void update_leds() {