Skip to main content
Mohan1
Associate III
September 29, 2020
Question

How to pass 10 arrays simultaneously in a for loop?

  • September 29, 2020
  • 1 reply
  • 1202 views

Hello everyone,

I am trying to get data from 10 ADC channels and want to display all the data simultaneously on the LCD. I successfully get the data from ADC channels but unable to display it simultaneously .Please give me suggestions over it and i am writing code in C language.

    This topic has been closed for replies.

    1 reply

    Tesla DeLorean
    Guru
    September 29, 2020

    Create a structure containing the arrays?

    Create an array of pointers, to the other arrays?

    Display how? As numeric values, as a graph?

    Perhaps draw a picture of what you are trying to describe?

    Tips, Buy me a coffee, or three.. PayPal VenmoUp vote any posts that you find helpful, it shows what's working..
    Mohan1
    Mohan1Author
    Associate III
    September 29, 2020

    @Community member​ Thanks for your quick response sir. I am just using the arrays which contain data from ADC channel and i converted that value into integer. I have 10 channels of ADC and i am using 10 arrays for that. So how can i display all the data in numerical form in LCD contineously?

    Tesla DeLorean
    Guru
    September 29, 2020

    sprintf() the data to a string

    Scroll or advance the screen to accommodate the new line.

    Draw the string as a bitmap into the frame buffer from your font tables if a graphical screen. If a text screen copy the string into the newly blanked line in the display buffer.

    If the screen driver has very limited functionality you'll need to break this down into the required steps. HW is typically not intelligent, you have to do all the work to make things occur.

    Tips, Buy me a coffee, or three.. PayPal VenmoUp vote any posts that you find helpful, it shows what's working..