Announcement

Collapse
No announcement yet.

Problem with Win buttons

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

  • Problem with Win buttons

    First I would like to say Merry Christmas to Doff, James, Sysmon and the rest of the crew at 4D and all of the users on the forum.


    I have created a program that uses a 43 touch screen and an Arduino Mega 2560 microprocessor. The display is mounted in the landscape position. On one frame of the display I have 6 Win buttons that are in a 2 column by 3 rows. Filling the screen left to right with a little space left at the top and bottom. My problem at first was real bad for both the Win button and just standard butttons. I had to take some foil tape (faraday tape) and wrap the wires from the display to the Arduino (5 wire ribbon) and chassis ground the foil. Now the problem is just the Win buttons.
    Example: If I tap the right side top button I can see the left middle button go from a white to light gray (this is the visual feedback that the button was pressed). This also happens when I press the right side middle button, the left middle acts like it was pressed. Now one more example: when I press the right side bottom, the left side bottom reacts like it was pressed. In the program, depending on which button was pressed. Certain data is loaded depending on which button was pressed. And the data is being loaded for the left side buttons.

    Could this be a programming error on my part? Reason I ask is that when the button is pressed, Genie data is passed to the Ardiuno and then the Arduino sends a command to the display to get a txt file that contains parameters from the uSD card. And that is sent back down to the Arduino. I am wondering if I need to add some delay between the Arduino receiving which button was pressed. And when the Arduino sends up the command to get the file on the uSD card?

    May Santa leave Makers supplies in your stocking.

  • #2
    How long is the cable between the Arduino and the display? What baud rate are you using?

    Run the Touch calibration tool from the tools menu, I suspect that will fix your touch issue.
    Mark

    Comment


    • #3
      Hi Mark,

      I did not measure the actual length but its about 14" long. I have kept the baud rate low to help reduce noise problems. So, it is the default 9600 still.

      Ok, well I didnt mention that other buttons even small like the size of a finger tip work just fine. Just not as much activity during those button presses. Like one is next frame when pressed. I was having problems with that prior to the shielding of the wire. Now they work every time. Long story, but will give your calibration suggestion a try but will take a few weeks before I can do that.

      Thanks Mark

      Comment


      • #4
        Hi Mark,

        My day to day work has kept me away from the project for a few days. I was so sure that it was some form of RFI or EMI that was putting noise on the wires. Even after doing some more shielding it was acting up. OK, give the trouch screen calibration a try. First try was a real pain getting the cross hairs to see me touch it. Ran second time and like every touch was boom dead on. Drawing I was able to draw a circle with end off by one pixel. Now I got to tell you that this is all mounted in a box about head height. To work on the guts, I have to take the cover off of the box and align the bottom holes with the top holes on the box. After the calibration project and buttons work fine several test and dead on each time.

        Now I remount the cover to the box. This is a project that someone else started and the cover is a scrap sheet of metal with a ever so slight twist. Like 8mm over 300mm. And I lost the one screw that helps remove that slight twist. Ya and I have been to lazy to worry about it at this time (going to put it in when done working with the project). Well it appears that maybe it has been causing the benzel to press on the display (got that from another thread in the forum). So got the 4th screw and pulled the cover flat. So far that seems to have fixed my problem.

        The problem was when pressing on the screen lets say lower right corner. I would see a button about 10mm higher get pressed. Or higher and at least half way across the screen to the left if not further. After the light bulb came on (ah ha). I am about to trash the other guys cover and build mine on flat stock. His cheap cover has caused me a lot of grief.

        Thanks between your suggestion and reading those other post. I think I have a fairly good idea what has been causing me so much grief.

        Paul

        Comment

        Working...
        X