How do you set and read ADC/DAC pin values?
pedward
Posts: 1,642
I must be missing something, but I don't see how you set the DAC value or read the ADC value from pins.
Anyone know the answer?
Anyone know the answer?
Comments
SETDACn for DAC output, there are 4 per COG.
I think ADCs are still done per Sigma-Delta modes of the counters, only the feedback and input resistors are now internally available for every pin.
EDIT: after looking into the Docs, it is more like that:
The pins implement a Sigma-Delta modulator (Comparator, Latch, Feedback filter) if you configure them so. They send then a bitstream of 0/1 according the input voltage.
To get an ADC value from that you need a counter that counts the ones over a certain period.
Andy