Logic Machine Forum
Multitouch Problem - Printable Version

+- Logic Machine Forum (https://forum.logicmachine.net)
+-- Forum: LogicMachine eco-system (https://forum.logicmachine.net/forumdisplay.php?fid=1)
+--- Forum: Visualization (https://forum.logicmachine.net/forumdisplay.php?fid=9)
+--- Thread: Multitouch Problem (/showthread.php?tid=1377)



Multitouch Problem - savaskorkmaz - 03.05.2018

Hi,
We are using visualation page in our touch panels for control (Via an application which includes chromium , html5 viewer).

When we touch to screen with two fingers, it's acting very strange. Sometimes , it acts to go back , sometimes page goes irrevelant pages.

Is it a function that Logic Machine trigger or support ?

Can we cancel somehow ?


RE: Multitouch Problem - Erwin van der Zwart - 03.05.2018

Hi,

User input / multi input / gestures are done by the driver of the panel, that has nothing to do with the controller. You can add some custom JS functions to block client side input, but that also has nothing to do with the controller, they will only be pushed to the client on load.

I would check the panel options to disable the multi touch functions..

BR,

Erwin


RE: Multitouch Problem - tassiebean - 29.12.2019

Hi Erwin,

You said - "You can add some custom JS functions to block client side input".

Can you help with this? I have a sequence of interacting scripts that takes a few seconds to complete (I have a UserParameter that tells me when they are busy: 0/250/59 Boolean), and I don't want the user to be able to touch away on the screen (operate sliders, close widgets, etc), until my script completes. I am currently displaying "Please wait" but that is not terribly foolproof - it is easily ignored.

Can you help with that code? Thanks for all your help on this forum.

Thanks, Phil


RE: Multitouch Problem - Erwin van der Zwart - 29.12.2019

Hi,

See this topic: https://forum.logicmachine.net/showthread.php?tid=702&pid=3962#pid3962

Or use this custom JS as a starting point, i created this for screen cleaning

Code:
$(function(){
 
  // Set your listener address and value here
  var grpaddress = '1/1/4';
  var objvalue = true;
 
  // Set your screenclean time here
  var screencleantime = 30;
 
  // Set your text here
  var screenclean_message = 'Screen cleaning mode is now active';
  var screenclean_remaining_prefix = 'remaining time';
  var screenclean_remaining_suffix = 'seconds';
 
  // Add screencleaner and listener to your visu
  if (typeof grp != 'undefined') {
    grp.listen(grpaddress, function(object, state) {
      var value = object.value;
      if(value == objvalue && state === 'value'){
        // Set start time
        var counter = screencleantime;
       
        // Function to count down the timer
        function countdown() {
          var el = document.getElementById('countertext');
          var intervalId = setInterval(function() {
            counter = counter - 1;
            $('#screencleantime').text(screenclean_remaining_prefix + ' ' + counter + ' ' + screenclean_remaining_suffix);
            if (counter === 5 || counter === 3 || counter === 1) {
                $('#screencleantime').css("color", "#ff0000");
            } else {
                $('#screencleantime').css("color", "#ffffff");
            }
            if (counter === 0 || counter < 0) {
               clearInterval(intervalId);  
              // Remove overlay from visu
                  $('#screenclean').remove();
            }
          }, 1000);
        };

        // Add dynamicly the overlay to visu
        $('body').append('<div id="screenclean" style="position:absolute;width:100%;height:100%;opacity:0.3;z-index:100;background:#000;"><div id="screenmessage" style="text-align:center;position:absolute;left:calc(50% - 200px);top:calc(50% - 100px);color:#ffffff;opacity:1;z-index:0;"><div><h4 id="screencleanmessage" style="min-width:100px;"></h4></div><div><h4 id="screencleantime" style="min-width:100px;"></h4></div></div>');
        $('#screencleanmessage').text(screenclean_message);
        $('#screencleantime').text(screenclean_remaining_prefix + ' ' + counter + ' ' + screenclean_remaining_suffix);
        // Start Countdown
        countdown();
       
      } else {
           // Remove overlay from visu on any other value
        $('#screenclean').remove();
      }
    }, true); // Set to true if you want to trigger again on same object value
  }
});

PS: I don’t think address 0/250/59 is possible (:

BR,

Erwin


RE: Multitouch Problem - tassiebean - 30.12.2019

Thanks, Erwin!

I used your first suggestion - See this topic: https://forum.logicmachine.net/showthrea...62#pid3962
and it works very well (except for opacity of sliders but I can live with that).
As for my address, well, it works on the 5500SHAC!  Wink

Also, what did you mean by 'screencleaning'? Do you mean 'screensaver'?


RE: Multitouch Problem - Erwin van der Zwart - 30.12.2019

Hi,

Aah, you have a clipsal c-bus version, that explains the non KNX standard address (:

Screen cleaner is used for (build-in) touch screens, when cleaning the screen you can block user input to avoid unintended user input during cleaning.

BR,

Erwin