Announcement

Collapse
No announcement yet.

internal interruptions

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • internal interruptions

    Hello

    Currently, I programming a GEN4 70DCT-CLB screen with Visi. I receive data from the COM0 and I have some pushbuttons on my screen. I would like to create internal interruptions to manage priorities between the pushbuttons and the data received in the serial communication.

    I read in the manual that the screen comes with interruptions by timer and external interruptions (GPIO). But, have the screen another way to create interruptions or specifically, internal interruptions without timers?

    I would appreciate your attention and a possible solution to my question

  • #2
    Hello,

    Welcome to the forum!

    To get a bigger picture and suggest an appropriate solution, would it be alright
    if you could elaborate further on what you're trying to accomplish with your
    project? I need to know, why you would want an "internal interruptions without timers"?

    "I read in the manual that the screen comes with interruptions by timer and external
    interruptions (GPIO). But, have the screen another way to create interruptions or
    specifically, internal interruptions without timers?"
    From what I can understand, do you want the push button to function without delay
    and do it's task right away? If yes, then you could skip using timer event altogether to
    avoid delaying the task you intend to do.

    Hope this helps and best regards,
    Sherwin

    Comment


    • #3
      Hi sherwin4D and thanks for your response

      Answering to your question, I work in the graphing of some data that the screen receives by serial communication from my computer.

      In the screen, the user has 3 buttons to switch between 3 windows (each window with its own graph). My computer sends data every second, the screen receives, processes and plots these data in real time.

      Here is an example of my code:

      repeat

      Pushbutton();

      c:=serin();

      if (c > 0)

      if (c == 2)
      p:=puntR;
      endif

      str_PutByte(p, c);
      p++;

      if (c == 3)
      process_and_graph ()
      endif

      endif
      forever

      Currently, my program doesn't have any timer, because I worry that it generates delay plotting the data.

      I want to give priority to my tasks, I mean, in case the user pushes a button, the program finishes processing and graphing the data and then performs the action of that button.

      I wanted to know if the processor has any instruction to organize the program as semaphore (to control access to a common resource by multiple processes in a concurrent system such as a multitasking operating system) or for prioritizing events without timer.
      Last edited by camila0417; 9th May 2019, 07:42 AM.

      Comment


      • #4
        Hi,

        Thanks for providing additional information regarding your current project.

        Currently, my program doesn't have any timer, because I worry that it
        generates delay plotting the data.
        There should be no delay in plotting your data even if you used a timer in ViSi
        as it is a non-blocking function.

        I want to give priority to my tasks, I mean, in case the user pushes a button,
        the program finishes processing and graphing the data and then performs the
        action of that button.
        Currently, I don't think you can do two task simultaneously. You can't perform
        a task such as processing and graphing data while simultaneously showing
        another form with its own graph. This feature is not yet available as of now.
        What you can do however, is make sure that as much as possible you never use
        a blocking function.

        Lastly, our products doesn't have real-time operating system capabilities yet.
        So, you can't do multitasking, or prioritize any events you want right now.

        Have you tried storing your data into a text file?

        I hope this satisfies your inquiry.

        Good luck and best regards,
        Sherwin

        Comment

        Working...
        X