Code Monkey home page Code Monkey logo

Comments (4)

omriharel avatar omriharel commented on May 22, 2024 9

Hi there @ryanaukes, thank you for the kind words!

This is an understandable need, and I intend to do a connection stability pass in the near future that'll hopefully also include this. It will need to be accompanied by better signaling for deej's current connection state, which is challenging to do without a UI - but I'll come up with a solution. I'm leaving the issue open and will update here when this is released.

from deej.

wildxmxtt avatar wildxmxtt commented on May 22, 2024 2

Comment edited by @omriharel: The following suggestion is an untested workaround. Its impact on system performance, stability and security has not been measured. As such, use it at your own risk.

Original content below:

I was able to write a file called on_connect.ps1 that fixes this issue through task scheduler: (fork here: master...wildxmxtt:deej:patch-1 )

Steps to do this on WINDOWS:

  1. Place on_connection.ps1 in the same folder as deej.exe
  2. Open the on_connection.ps1 ; here you will specify your Arduino Port & path to your deej.exe
  3. Create a basic task on task scheduler

For the variables in task scheduler use the following:

  1. Program/Script: Path to powershell.exe (C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe)
  2. Add arguments: -windowstyle hidden .\on_connection.ps1
  3. Start in: full path to your folder where deej.exe and on_connection.ps1 is stored (C:\Users\UserName\Documents\Deej)

Hope this helps!

Also if your com port tends to change often please change all 3 lines in on_connection.ps1 where it says:

$device = Get-WmiObject Win32_SerialPort | Where-Object { $_.DeviceID -eq $arduinoPort } 

To

$ArdunioName = "Arduino NANO Every"
$device = Get-WmiObject Win32_SerialPort | Where-Object { $_.Description -eq $ArdunioName } 

from deej.

N0P1NG avatar N0P1NG commented on May 22, 2024 2

What about "reconnect" button in tray? That would restart the app or a menu with port selection and reload COM button or change the comport in config and back which sort of works as slow workaround.

from deej.

ThreepE0 avatar ThreepE0 commented on May 22, 2024

Hello @omriharel, please take a look at a comment that I posted on a related but separate issue; I'm wondering if the "can't read line from serial" function might simply be broken, as editing the config while Deej.exe is running recovers from both plug/unplug as well as from loss due to sleep/wake of the computer. The config reload seems to be using similar functions, so I'd think that if the "can't read line" function were to be edited, that'd fix the main issue for both of these. Maybe I'm missing something though. I hope this helps narrow things down.

from deej.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.