April 26, 2024, 10:28:56 PM

Using both DAC of MOD-IO2

Started by ilario, October 20, 2023, 05:28:34 PM

Previous topic - Next topic

ilario

Dear all,
I started looking how to use the DAC of MOD-IO2 but I found out (in the PDF contained in the ZIP file with the firmware) that only one can be set via I2C.

Is there any way to use both of the DAC of MOD-IO2?
Should I modify the firmware and reflash the MOD-IO2 in order to do that?

Are the firmware sources hosted somewhere or are only available in the ZIP file linked on the product page? Is there a way to submit patches, in the remote case I successfully manage to add the support for the second DAC?

Thanks!

LubOlimex

I am not sure if you can have two DAC without disabling the ADC first. Refer to the datasheet of the chip first.

For the moment the sources are only available as archive, but you can create own repo at GitHub modifying them the way you like. We can also create a GitHub page for MOD-IO2 but  I am not sure if two DACs and no ADC would work for us.
Technical support and documentation manager at Olimex

ilario

Checking the datasheet found here https://ww1.microchip.com/downloads/aemDocuments/documents/OTH/ProductDocuments/DataSheets/40001607D.pdf (the link to the datasheet included in page 15 of the MOD-IO2 user manual is broken) I realized that there is a much bigger problem to my usage scenario: both DACOUT1 and DACOUT2 are driven by the same DAC module (see Figure 16-1 at page 127).
So, even if I manage to use them both, they will have the same voltage.

In order to obtain more than one DAC from each MOD-IO2 I could make a small low-pass filter for the PWM outputs.

But rather, I think I will buy some "Adafruit MCP4728 Quad DAC with EEPROM - STEMMA QT / Qwiic" https://www.adafruit.com/product/4470 and connect them to an I2C multiplexer (unless you have any other product to suggest). I will keep using the MOD-IO2 for their relays :)

Thanks for your help!