Closed sreimchen closed 1 year ago
Documentation says: err_in_fifo – If enabled, bit 15 of the FIFO contains error flag for each sample byte_shift – Shift FIFO contents to be one byte in size (for byte DMA) - enables DMA to byte buffers.
I didn't find much information about the error flag but I think it should just be set if an error appeared while reading the sample by the ADC. In the simulation that never happens at the moment which is fine. I don't know why it is called err_in_fifo in the SDK because that doesn't make sense to me: If the FIFO is full then the sample is dropped anyway... I think the naming chosen by the RP team is confusing... in my opinion it should be named like "error_adc_reading" or am I missing something important?
At the moment the error flag is always set (15th bit) if full resolution (12 bit) reads are configured which are stored as 2 byte samples in the ADC's FIFO. That is wrong in my opinion because the error flag should just be set if an error appeared. An error appears if the ADC concludes that there was an error after sampling.