Full Screen Demo Mode Visualization.

ais
2016-04-06
2016-09-22
  • ais

    ais - 2016-04-06

    I have written a simple stop start piece of code and added a lamp and 2 pushbuttons as visualization elements.

    To run the application I do the following:
    1. Start the PLC from the systray.
    2. Under "Device" - Scan the network to create a connection.
    3. Login.

    At this point the visualization window displays a message "The online visualization is waiting for a connection. Please start the application."

    1. Under Debug - Start execution of the application.

    Visualization then runs as a separate application and the visualization window the switches to full screen mode (with no available options) and after a while "Demo Mode" is displayed in the top right hand corner.

    The only way I can get out of the full screen mode is to via Windows Task Manager (Control+Alt+Delete) and stop the application.
    When I then restart the application this full screen mode behaviour is not repeated.
    If I save the project at this point, the full screen mode behaviour is not repeated when I reopen the project.

    Any insights on the above?

    One point to mention - I do not select simulation.
    When I have selected simulation - I get a Program Exception Error.
    Can some list a blow by blow account of how to run the code with "simulation" selected please.

    Edit: Using CodeSys V3.5 SP8 Patch 2

     
  • eschwellinger

    eschwellinger - 2016-04-06

    Hi,

    everything work like expected. (except the exception in the Simulation which is a bug)

    Some remarks on this.
    If you add the a visualisation by default 'TargetVisu' and 'Webvisu' will be added.
    This is the reason for if you go online to the plc you will get then a fullscreen visu hmi Screen (this is what you expect on a machine for example with touchscreen)
    To prevent this you could simply delete the targetVisu "connector" below the Visumanager after doing this you have only the internal visu in CODESYS (this is what you probably expect)
    Sure you could configure the behavior to have a Windows with scrollbar
    you find these settings in:
    "c:\Program Files (x86)\3S CODESYS\GatewayPLC\targetvisuextern.cfg"

    [ComponentManager]

    [CmpTargetVisu]
    ; The Window... settings can be used for displaying the targetvisualization in a window instead of fullscreen
    ;WindowType=2
    ;WindowPositionX=0
    ;WindowPositionY=0
    ;WindowSizeWidth=1024
    ;WindowSizeHeight=768
    ;HideCursorCompletely=1

    [CmpTargetVisu]
    WindowPositionX=320
    WindowPositionY=272
    WindowSizeWidth=640
    WindowSizeHeight=480

    [SysFile]
    PlcLogicPrefix=1

    [SysWindow]
    ;Windows.CloseOnAltF4=0
    ;Windows.CloseOnWM_CLOSE=0

    The only way I can get out of the full screen mode is to via Windows Task Manager (Control+Alt+Delete) and stop the application.
    Alt-F4 Close the Targetvisu Window

    So you have two choices:
    - either you work with the Control Win and remove TargetVisu in the Device tree in the Project
    - you set VISU_NO_EXCEPTION_HANDLING as compiler define under Application (rightclick - properties - Build -> compilerdefines)

    BR
    Edwin

    IMG: default.jpg

     
  • ais

    ais - 2016-04-06

    Visualization:
    Thanks for the explanation.
    Since it is the expected behaviour - I will leave it as it is and use Alt-F4.
    However, if it is the expected behaviour, why is the behaviour not persistent?
    i.e. Why does it not go to full screen after the initial launch or after saving?

    Simulation:
    I think I finally grasp the intention...
    Would it be fair to say that since I am using "CODESYS Control Win V3" I should NOT be trying to use "simulation" - given there is no hardware to "simulate"?
    i.e. Simulation is only relevant if "Device" is based on actual hardware, but no physical hardware has been connected.

     
  • eschwellinger

    eschwellinger - 2016-04-06

    Hi,

    i.e. Why does it not go to full screen after the initial launch or after saving?
    is it possible that you are connected by remote desktop? (This is a known bug which will be solved to 3.5SP9, June)
    If not i have no explanation.. should start every time. (check the plc logger for the case that it does not start)

    Simulation:
    yes - since switching the plc in the device tree is that easy, I would always prefer to use a real plc (Control WIN)

    BR
    Edwin

     
  • MassimoM

    MassimoM - 2016-04-26

    Hi to all and thanks for the helps.
    Due to a particular implementation, I need a button, in the desktop, to launch Visu in case the end user press alt+F4 and close the visu app.
    There is a way to obtain this?

    I've seen in the CoDeSysControl.cfg file this line:

    Zitat:
    [CmpTargetVisuStub]
    Program="CoDeSysControlStaticTV.exe"
    CommandLine=-r targetvisuextern.cfg

    Try to execute this command
    CoDeSysControlStaticTV.exe -r targetvisuextern.cfg
    but nothing...

    Any suggestion?

     
  • eschwellinger

    eschwellinger - 2016-04-26

    hi,

    no seach the online help for Targetvisu
    You will end in the following search result:
    .
    .
    Start or Stop of a target visualization from Windows command line
    By use of the command VisualClientController.exe --application=Application --flags=2 a target visualization can be stopped. With flags=1 the visualization can be restarted. The command VisualClientController.exe can be found in the CODESYS installation directory in the subdirectory "..\GatewayPLC\".

    BR
    Edwin

     
  • delphinis

    delphinis - 2016-09-22

    Hi everyone,
    I am wondering if it would be possible to have only a smaller Window (no Fullscreen) as visualization.
    In the visualization configuration (visualisazion right click - properties - visualisation) I found some configurations like visualistion size and so on.
    But this changes only the size of the visualization on the white fullscreen...

     

Log in to post a comment.