No announcement yet.

LCD-32PT(GFX) refresh

  • Filter
  • Time
  • Show
Clear All
new posts

  • LCD-32PT(GFX) refresh


    I am looking for some help. I have LCD-32PT(GFX) with a DMX backpack from Milford Instrument which I bought over a year ago. I had to put this project on the back burner and I only dug it out the other day and getting back in to finishing this project.

    I have a small problem with the screen refreshing when I touch it. I have a screen with about 18 buttons on it and if I touch it redraws it and I can see it do it is there any way to stop this. ie set the refresh rate to fast. I have nearly the software side complete and will be working on sorting out a case for the screen and backpack with a 9v battery compartment.

    If anyone can recamend a case for the screen or know of any cases that are ready made for the screen and have a good bit of space ie if the case was about the size of 2 screen in landscape on top of each other. please let me know

  • #2

    You haven't said what environment you are using, but most of the 'supplied' ways only refresh the things that need refreshing.

    Can you give us a bit more information about what is going on?


    • #3

      I am using 4D workshop 3 IDE. I have 12 buttons the the screen and very time I touch the screen it refresh and it also does it when I lift my finger off the screen. Its like if it is redrawing the buttons even I have set the buttons that there is no movement in them.

      Here is the code to the main screen.

      // button states
      var vButtonState[12], vOldButtonState[12]; // allows up to 16 scene select buttons

      // button area for touch calcs
      #constant BUTTONWIDTH 60
      #constant BUTTONHEIGHT 60

      // button legends
      byte dL '1',0,'2',0,'3',0,'4',0,'5',0,'6',0,'7',0,'8',0,'9',0,'A',0,'B',0,'C',0//,'D',0,'E',0,'F',0

      // button X positions
      byte dX 30,100,170,240,30,100,170,240,30,100,170,240//,30,100,1

      // button Y positions
      byte dY 50,50,50,50,110,110,110,110,170,170,170,170//,217,217,217

      // hex lookup
      byte hexval "0123456789ABCDEF"


      // if any buttons have changed state, redraw them
      func redraw()
      var n,x,y;
      x:=0; // initial position
      if ( vButtonState[n] == vButtonState[n] )

      gfx_Button(BUTTON_UP, dX[n], dY[n], BUTTONCOLOUR, TEXTCOLOUR, 2, 4, 3, &dL[n


      • #4

        Gee, seems like the way redraw() is written it is guaranteeing everything is redrawn.

        It starts by drawing a panel that will erase the entire screen and then it has code like

        if ( vButtonState[n] == vButtonState[n] )

        gfx_Button(BUTTON_UP, dX[n], dY[n], BUTTONCOLOUR, TEXTCOLOUR, 2, 4, 3, &dL[n


        • #5

          I don't need any thing fancy. I have the main backround black and the buttons are gray with black text. some of the code I have used is from samples I have found on the net and got with the screen and dmx backboard that was made by Milford in the UK.

          I think I mite redo the buttons myself and if it fails will look in redoing it in ViSi to see what happens.