thobach / MMM-Gestures

MMM-Gestures is a head-less 3rd party module for MagicMirror that allows to control the Magic Mirror via gestures of two types of infrared sensors. Use cases include presence awareness to trigger compliments or go into sleep mode and scrolling through news tickers or view news details.
http://blog.thomas-bachmann.com/2016/02/magic-mirror-2-0-mit-gestensteuerung.html
41 stars 12 forks source link

connection error #11

Closed JeongGiKim6 closed 2 years ago

JeongGiKim6 commented 2 years ago

I’m trying to use the MMM-Gesture module, but the following errors continue to occur. I need everyone’s help. If you need any information, please ask me

[07.12.2021 10:25.35.854] [LOG] Connecting socket for: MMM-Gestures [07.12.2021 10:25.35.880] [LOG] Sockets connected & modules started … Tue Dec 07 2021 10:25:36 GMT+0900 (Japan Standard Time): Using USB: /dev/ttyACM0. [07.12.2021 10:25.36.221] [LOG] serial port opened Tue Dec 07 2021 10:25:36 GMT+0900 (Japan Standard Time): Using USB: /dev/ttyACM0. [07.12.2021 10:25.36.225] [LOG] serial port opened [07.12.2021 10:25.36.254] [LOG] Launching application. [07.12.2021 10:25.36.358] [WARN] (electron) Security Warning: A WebContents was just created with both webviewTag and contextIsolation enabled. This combination is fundamentally less secure and effectively bypasses the protections of contextIsolation. We strongly recommend you move away from webviews to OOPIF or BrowserView in order for your app to be more secure [07.12.2021 10:25.36.694] [ERROR] (node:11085) UnhandledPromiseRejectionWarning: Error: Error Resource temporarily unavailable Cannot lock port (Use electron --trace-warnings ... to show where the warning was created) [07.12.2021 10:25.36.695] [ERROR] (node:11085) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag --unhandled-rejections=strict (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 1) [07.12.2021 10:25.36.696] [ERROR] (node:11085) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.

JeongGiKim6 commented 2 years ago

I uploaded the .ino file in the Arduino folder and modified it to /dev/ttyACM0 instead of /dev/ttyACM0* in the 104th line of the Node_helper.js file. And when I ran the magic mirror, there was another error. I don’t know what the problem is yet.

[07.12.2021 10:56.34.939] [LOG] Connecting socket for: MMM-Gestures [07.12.2021 10:56.34.962] [LOG] Sockets connected & modules started … Tue Dec 07 2021 10:56:35 GMT+0900 (Japan Standard Time): Using USB: /dev/ttyACM0. [07.12.2021 10:56.35.302] [LOG] serial port opened Tue Dec 07 2021 10:56:35 GMT+0900 (Japan Standard Time): Using USB: /dev/ttyACM0. [07.12.2021 10:56.35.306] [LOG] serial port opened [07.12.2021 10:56.35.337] [LOG] Launching application. [07.12.2021 10:56.35.467] [WARN] (electron) Security Warning: A WebContents was just created with both webviewTag and contextIsolation enabled. This combination is fundamentally less secure and effectively bypasses the protections of contextIsolation. We strongly recommend you move away from webviews to OOPIF or BrowserView in order for your app to be more secure [07.12.2021 10:56.35.747] [ERROR] (node:12377) UnhandledPromiseRejectionWarning: Error: Error: Device or resource busy, cannot open /dev/ttyACM0 (Use electron --trace-warnings … to show where the warning was created) [07.12.2021 10:56.35.749] [ERROR] (node:12377) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag --unhandled-rejections=strict (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 1) [07.12.2021 10:56.35.750] [ERROR] (node:12377) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code. [07.12.2021 10:56.35.752] [ERROR] (node:12377) UnhandledPromiseRejectionWarning: Error: Error: Device or resource busy, cannot open /dev/ttyACM0 [07.12.2021 10:56.35.754] [ERROR] (node:12377) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag --unhandled-rejections=strict (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 2) I don't know what the problem is yet.

[07.12.2021 10:56.34.939] [LOG] Connecting socket for: MMM-Gestures [07.12.2021 10:56.34.962] [LOG] Sockets connected & modules started ... Tue Dec 07 2021 10:56:35 GMT+0900 (Japan Standard Time): Using USB: /dev/ttyACM0. [07.12.2021 10:56.35.302] [LOG] serial port opened Tue Dec 07 2021 10:56:35 GMT+0900 (Japan Standard Time): Using USB: /dev/ttyACM0. [07.12.2021 10:56.35.306] [LOG] serial port opened [07.12.2021 10:56.35.337] [LOG] Launching application. [07.12.2021 10:56.35.467] [WARN] (electron) Security Warning: A WebContents was just created with both webviewTag and contextIsolation enabled. This combination is fundamentally less secure and effectively bypasses the protections of contextIsolation. We strongly recommend you move away from webviews to OOPIF or BrowserView in order for your app to be more secure [07.12.2021 10:56.35.747] [ERROR] (node:12377) UnhandledPromiseRejectionWarning: Error: Error: Device or resource busy, cannot open /dev/ttyACM0 (Use electron --trace-warnings ... to show where the warning was created) [07.12.2021 10:56.35.749] [ERROR] (node:12377) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag --unhandled-rejections=strict (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 1) [07.12.2021 10:56.35.750] [ERROR] (node:12377) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code. [07.12.2021 10:56.35.752] [ERROR] (node:12377) UnhandledPromiseRejectionWarning: Error: Error: Device or resource busy, cannot open /dev/ttyACM0 [07.12.2021 10:56.35.754] [ERROR] (node:12377) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag --unhandled-rejections=strict (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 2)

JeongGiKim6 commented 2 years ago

Arduino's serial window was open, so this created an error. In conclusion, it was an error that was resolved by uploading the .ino file in the Arduino folder. I hope this documentation will help others.