Skip to content
/ HMI Public

HMI for the Showcase Mi5 tradefair demonstrator. It is based mainly on the following node-modules: Express, Socket.io, node-opcua

License

Notifications You must be signed in to change notification settings

ProjectMi5/HMI

Repository files navigation

HMI Master

The HMI for the Mi5 HMI Currently developing the Serviceskill Interface.

Installation

  1. Download and install Node.js (runs only with node v0.12.17)
  2. Download an clone the repository. Make sure you have the briefcase-branch
  3. In a command line window, browse in the repository and execute
  4. npm install // this installs the required node modules for the HMI
  5. npm intsall forever -g // this installs the forever module globally
  6. Run HMI_Start.cmd or HMI_Forever.cmd

Note: The forever module and file is kind of a dirty hack. Whenever the HMI crashes, it automatically gets restarted. Note: If you use the HMI_Forever.cmd and kill it, make sure you also end the node.exe process in the task manager. The process keeps running (thanks to forever), and then can lead to a PORT conflict, when restarting.

Additional information

You can also run the HMI using the node command line. Run then:

  • node app.js (this will use the live server configuration and Port 80)

It is possible to use different server confiugrations and ports from the command line. For example:

  • node app.js -server=hmitest -port=3000

  • node app.js -server=hmitest (this will use Port 80)

Automatic Output Module

The automatic output module connects to a camera via zeroMQ. Installing zeroMQ can be quite a challange. Have a look at the SVN for some installation files mentioned below.

  1. Install Python 2.7 (tested with v2.7.12), and update path in System control panel to match installation directory, the installer does not do this automatically.
  2. Use the zeroMQ installer for Windows downloadable here (tested: ZeroMQ-4.0.4~miru1.0-x64.exe)
  3. Install the Windows Software Development Kit (testet with Windows 10.0.14393.33)
  4. Make sure Visual Studo 2013 C++ is installed. (Not sure if this is necessary.)
  5. Restart your PC.
  6. In the command prompt, run node -v, npm -v, as well as python --version and make sure to use node version 0.12.17, npm version 4.0.2 and Python 2.7.12.
  7. In the command prompt, navigate to the HMI folder.
  8. Run npm install zmq. The zmq.node file binds zmq to the right version of node.js.

To use the Automatic Output Module, it is finally required, to add the following lines to the config.js file.

  config.AutomaticOutputModule        = "tcp://localhost:5555";
  config.EnableAutomaticOutputModule  = true;
  config.AutomaticOutputModuleAttempts  = 3;

If you want to test the Automatic Output Module, run the file ./examples/zeroMQserver.js while the HMI is running.

Revision

Last Update: 2016-11-08 Dominik Serve


Deprecated below.

Developing

  • Sapmleserver: ./misc/myTestSampleServerTriple.js This Server starts 3 instances with the same variable tree on the ports 4334, 4335, 4336

  • JSCS - Control Source: jscs .

  • Information Mocha Testing http://unitjs.com/guide/mocha.html

  • In the misc/ folder you can find a uaexpert file, that connects to this localhost server. Use this tool to check OPC UA variables. Also check with the tool, if the sample server is implemented correctly, if something fails. !!! See following point for Server-Issues in UAExpert

  • When the variable-architecture changes, OPC UA is not able to subscribe to a variable anymore. The Message is: BadDataEncodingUnsupported Therefore it is necessary to delete the sampleserver from the uaexpert client and then add it again.

Testing

  • For developing purposes, there is a folder called test/ in which all the unit-tests are stored.

  • Run: npm test This executes: "jscs ." and then "mocha"

  • Error Messages: Sometimes it throws error like certificate, or client.security. Then just restart both node.js applications some times, and it sould work.

Tools

Created with Nodeclipse (Eclipse Marketplace, site)

Nodeclipse is free open-source project that grows with your contributions.

About

HMI for the Showcase Mi5 tradefair demonstrator. It is based mainly on the following node-modules: Express, Socket.io, node-opcua

Resources

License

Stars

Watchers

Forks

Packages

No packages published