Announcement

Collapse
No announcement yet.

Can't get OnActivate to work with forms

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

  • Can't get OnActivate to work with forms

    I have the attached code (eventhandler) but nothing seems to get written to Form. Can anyone help me please?

    If there is an appnote that I haven't seen on the event handler that'd be great but I can't seem to find what I'm looking for.

    Thanks


    Code:
    void myGenieEventHandler(void)
    {
      genieFrame Event;
      genie.DequeueEvent(&Event);
    
      if (Event.reportObject.cmd == GENIE_REPORT_EVENT)
      {
        if (Event.reportObject.object == GENIE_OBJ_FORM)
        {
          if (Event.reportObject.index == 0)
          {
            Form = 0;
          }
          else if (Event.reportObject.index == 1)
          {
            Form = 1;
          }
          else if (Event.reportObject.index == 3)
          {
            Form = 3;
          }
          else if (Event.reportObject.index == 4)
          {
            Form = 4;
          }
          else if (Event.reportObject.index == 5)
          {
            Form = 5;
          }
          else if (Event.reportObject.index == 6)
          {
            Form = 6;
          }
          else if (Event.reportObject.index == 7)
          {
            Form = 7;
          }
        }
      }
    }

  • #2
    Hello Cam,

    I've tried your code snippet and it seems to be working just fine.

    Please ensure that your forms are set to report message on activate as stated on this application note.

    Click image for larger version

Name:	Capture.PNG
Views:	108
Size:	6.8 KB
ID:	66662

    Please also ensure that proper communication between the Arduino and display module is established.(i.e they have the same baud rate, the rx and tx lines are connected properly, etc...)

    Best regards,
    Michael

    Comment

    Working...
    X