Activity Forums Questions & Troubleshooting Hardware Resolution of analog IO

  • Resolution of analog IO

     Lucko updated 5 months ago 2 Members · 3 Posts
  • Lucko

    Member
    January 13, 2021 at 11:58 am

    Hi!

    I’m attempting to find info on analog write and read resolutions. I have Maxi Pure Automation. Is it 10bit read and 8bit write? What about real analog ones? Also only 8bits?

    Also I have a question about analogWriteResolution(). I’m geting this error. We had Arduino DUE and there was no error with the same code when we change resolution to 12bits. But hire I get an error even if I use 8bit or even 4 bit command… is this not working with Controllino?

    Thanks

  • ivan-controllino

    Administrator
    January 13, 2021 at 12:45 pm

    Hi Lucko, pozdrav and thank you for joining the forum!

    Regarding your first question: The Analog Inputs and Outputs have 10 bit read and 8 bit write resolution, you are right. We are currently working on updating our datasheets to also include such information.

    Regarding your second question: you can just use analogWrite() function with a value of 0 – 255, we don’t clearly understand why you want to set the resolution as it is fixed by the controller. If you could elaborate more on that part, we’re glad to help.

    • Lucko

      Member
      January 13, 2021 at 1:07 pm

      Hi!

      I would just like to port Arduino DUE code to it… You can do that with Arduino so even in case your analog is only 8bit you can still use 12bit value… So in this case I could just use almost same code… Now I need to change it from 4095 to 255 and so on…

      Also it looks like code is not 100% compatible in some other places but will ask that in the right part of a forum…

      Regards

Log in to reply.

Original Post
0 of 0 posts June 2018
Now