Software zum Installieren eines Smart-Mirror Frameworks , zum Nutzen von hochschulrelevanten Informationen, auf einem Raspberry-Pi.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

MMM-flick-gestures.js 883B

1234567891011121314151617181920212223242526272829303132333435
  1. /*var myPythonScriptPath = '/home/pi/MagicMirror/modules/MMM-flick-gestures/monitor.py';
  2. const {PythonShell} = require("python-shell");
  3. let options = {
  4. mode: 'text',
  5. pythonPath: '/usr/bin/python',
  6. pythonOptions: ['-u'], // get print results in real-time
  7. // scriptPath: '',
  8. args: []
  9. };
  10. var pyshell = new PythonShell(myPythonScriptPath, options);
  11. */
  12. Module.register("MMM-flick-gestures",{
  13. // Default module config.
  14. requiresVersion: '2.1.0',
  15. defaults: {
  16. },
  17. // Override dom generator.
  18. getDom: function() {
  19. var wrapper = document.createElement("div");
  20. return wrapper;
  21. },
  22. start: function() {
  23. this.sendSocketNotification("INIT", this.config)
  24. },
  25. socketNotificationReceived: function(notification, payload) {
  26. Log.log(this.name + " received a socket notification: " + notification + " - Payload: " + payload);
  27. this.sendNotification(notification);
  28. }
  29. });