Git Product home page Git Product logo

arctis-battery-percentage's Introduction

arctis-battery-percentage's People

Contributors

atagulalan avatar dependabot[bot] avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

arctis-battery-percentage's Issues

Feature request: Include SteelSeries Wireless Mouse

Hi man,

Great project! Cool to see people volunteer their time to adding features SteelSeries neglect.

Do you think it would be possible to expand on the functionality your project to also include wireless mice?
I have a Rival 650 Wireless, and apparently SteelSeries think using the scroll wheel as the only battery indicator was sufficient.

I would love to be able to display the battery level on the display of my Apex Pro keyboard.

issues with installing

im new to nodejs

i keep on getting this line in my code

prebuild-install WARN install No prebuilt binaries found (target=14.15.4 runtime=node arch=x64 libc= platform=win32)

then followed by this

warning c4290 c++ exception specification ignored

is there anyway to fix ?
could it be the reason that i have do not have the system in English ?

thank you.

Support for Arctis 9

Expected: script shows battery percentage for Arctis 9

Actual: script shows nothing, more info below after brief debugging

More context:

Hi,

I found this repo and it looks like a way to get missing feature for Arctis 9 of checking the battery state in some reasonable way.
(I don't consider gg app reasonable, way to bloated with unnecessary stuff :/)

I found issue:
#10
But it seems change didn't work. At lest for me script still fails to find the proper device.
(Win 10, PC variant of Arctis 9)

I'm more than happy to get script working on my device with some guidance on how this should work and how to debug it.
If there is a good fix I could contribute a PR.

Listing Devices I found:
7 copies of Razer Taipan, that seems to be my mouse, not sure why it appears 7 times...
5 copies of unnamed "{vendorId: 4617, productId: 8705,}" that seems to be my Rise Keyboard as it disappeared when i switched keyboards
4 copies of Arctis 9: https://pastebin.com/jwcaSsyv
Vendor is 4952 as expected, but productId are 3x 4802 and 4804 (in hex 0x12C2 and 0x12C4 )
0x12C2 would match the script spec, but usage is set to 1 whatever that means, so it gets filtered out.

PS I think I'll contribute a PR with "No matching Arctis device detected." as current lack of any message when all devices are not matching is confusing.

Thank you!

This is incredibly helpful - it took me 60 seconds from finding this result on Google to finally finding out what the battery percentage on my headset is. And the desktop notification is a great touch too. Thank you, that is all ๐Ÿ™‚

Support Node v14/16

There are a number of issues with running this on Node 14/16.

Are there any packages that break with that node version?

Open to contributing a PR if necessary

Support for Arctis 7P+

I tried adding [4152, 0x2212], // Arctis 7P+ to the series list but none of the d.usage !== 1 conditions pass, getting rid of that condition and trying all of them still doesn't work

Question

Hi, I'm looking to make a quick script to turn off the setting "blink LED when headset is off".

How did you know what data to write to the device in order to get back the battery percentage? Is there a way to output features that the headset has?

Add custom device

I just downloaded the cource code but I want to add my Steelseries Rival 650 mouse, where did you get all the device info that you have in the code?

Notification awesomeness

Hey,

i might say, quite a good job with this! one thing i though might be useful - a taskbar icon, e.g just like cpu/gpu temperature. I hope it's not hard to implement, some other people could find it useful as well ;)

Not recognising headset

Headset plugged and working but still getting "Your SteelSeries Arctis 7 device's battery percentage is 0" on cmd and "Please connect your SteelSeries Wireless Device first" on notifications panel.

Multiple issues using Arctis 1 Wireless

First of all, thanks for spending your free time to make up for Steelseries missing basic features. I was facing some issues while trying to use your project. My setup is the following:

  • Arctis 1 Wireless (Transmitter-Version 1.6.0.0, Headset-Version 1.6.0.0)
  • npm package: [email protected]
  • NodeJS: v14.15.5
  • Most recent master version of this repository

1. npm package not working

It's super convenient to have a npm package. Unfortunately it is not working for me. I installed it globally using npm i -g arctis-battery-percentage but when I call arctis-battery no output is shown on the command line.

C:\>arctis-battery

C:\>

2. Running the script locally

In issue #10 @ateee0907 was facing the same issue. You were asking him to execute the script locally, so I decided to do the same. When executing node ./percentage.js in the main directory, I get an error message, complaining that path module isn't defined.

C:\arctis-battery-percentage-master>node ./percentage.js
Initializing...
Your Arctis 1 Wireless device's battery percentage is 3
C:\arctis-battery-percentage-master\percentage.js:48
arctis-battery-percentage-master\percentage.js:48
    icon: path.join(__dirname, `./images/${percentage}.png`),
          ^

ReferenceError: path is not defined

So I went ahead and required the path module in the beginning of your script by adding const path = require('path').
After that the error vanishes. Is this error and behaviour expected?

3. Wrong percentage

After I was able to get the script going, the desired cli output and notification showed up. Unfortunately the returned value is wrong (see screenshot). I just fully loaded the headset which you can clearly see in SteelSeries Engine in the background.
grafik

4. Percentage is only found when SteelSeries Engine window is active

When executing the script nothing happens until I click on the SteelSeries Engine window. I guess the arctis-usb-finder module is only able to find the headset when SteelSeries Engine is active. Is this expected?

Sorry for reporting multiple issues within one GitHub issue, but I'm not sure if they are somehow connected, so I decided to put them all in one issue. And once again, I'm grateful for your efforts on this topic, I just can't quite get it to work. If you need further information on investigating this issue, just let me know ๐Ÿ‘

I can't get data when SSE 3 working on background

device.readSync() is waiting for response and when i open sse3 windowed (or focused) is working but i need this data immediately. My headphone is Actris 1 Wireless

Code :

// Act 1 w serie arr = [4152, 4787]
devices
		.filter((d) => {
			return series.some((s) => {
				return d.vendorId === s[0] && d.productId === s[1] && d.usage !== 1
			})
		})
		.forEach((deviceInfo) => {
			var device = new HID.HID(deviceInfo.path)
			//device.setNonBlocking(true)
			if (!device) {
				console.log('Could not find device :(')
				process.exit(1)
			}
			try {
				device.write([0x06, 0x18])
				device.resume()
				var report = device.readSync()
				console.log(report);
				callback(deviceInfo, report[3]) // i think my verisons percentage is 4th elem.
				
			} catch (error) {
				console.log(error)
				console.log('Error: Cannot write to Arctis Wireless device. Please replug the device.')
			}
			device.close()
		})

Is there way to get some kind of video tutorial for this?

I am kinda beginner with all this node stuff and while i took a while to research answers to install those modules right way i didnt get it to work. I would be really happy to learn how to do this with more depth on install tutorial and it would be good for other beginners that are trying to get this awesomeness to work.

NPM Install issue

npm ERR! code ENOENT
npm ERR! syscall spawn git
npm ERR! path git
npm ERR! errno -4058
npm ERR! enoent Error while executing:
npm ERR! enoent undefined ls-remote -h -t git://github.com/atagulalan/arctis-battery-percentage.git
npm ERR! enoent
npm ERR! enoent
npm ERR! enoent spawn git ENOENT
npm ERR! enoent This is related to npm not being able to find a file.
npm ERR! enoent

npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\lenovo\AppData\Roaming\npm-cache_logs\2021-10-22T11_07_24_403Z-debug.log

issues installing

hi there, so i am pretty new to this programs and i really have no idea on how to install it, can someone please guide me through the process step by step, i already installed node.js thanks

Arctis 7 - Help

It shows that cant locate the bindings file , what can i do?
Latest version of Nodejs
Note :
I already installed all succesfully in 2 computers before (like 3-4months ago) and it never throw me that error before

imagen

Arctis 9

Hey!

First of all thanks for this script.

I have brand new Arctis 9 headset.

Does this script support it ? Or only the older version of this headsets?

Thank you in advance.

Impossible Installation on Manjaro

Hi,

I would like to install your software on my Linux Manjaro distribution.

However, I run into an issue when I have tried to install it.
Look my terminal output.

npm WARN checkPermissions Missing write access to /usr/lib/node_modules
npm ERR! code EACCES
npm ERR! syscall access
npm ERR! path /usr/lib/node_modules
npm ERR! errno -13
npm ERR! Error: EACCES: permission denied, access '/usr/lib/node_modules'
npm ERR!  [Error: EACCES: permission denied, access '/usr/lib/node_modules'] {
npm ERR!   stack: "Error: EACCES: permission denied, access '/usr/lib/node_modules'",
npm ERR!   errno: -13,
npm ERR!   code: 'EACCES',
npm ERR!   syscall: 'access',
npm ERR!   path: '/usr/lib/node_modules'
npm ERR! }
npm ERR! 
npm ERR! The operation was rejected by your operating system.
npm ERR! It is likely you do not have the permissions to access this file as the current user
npm ERR! 
npm ERR! If you believe this might be a permissions issue, please double-check the
npm ERR! permissions of the file and its containing directories, or try running
npm ERR! the command again as root/Administrator.

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/olivier/.npm/_logs/2019-10-30T16_41_10_091Z-debug.log
$ sudo npm i -g arctis-battery-percentage
 
/usr/bin/arctis-battery -> /usr/lib/node_modules/arctis-battery-percentage/percentage.js

> [email protected] install /usr/lib/node_modules/arctis-battery-percentage/node_modules/node-hid
> prebuild-install || node-gyp rebuild

prebuild-install WARN install EACCES: permission denied, access '/root/.npm'
gyp WARN EACCES current user ("nobody") does not have permission to access the dev dir "/root/.cache/node-gyp/12.13.0"
gyp WARN EACCES attempting to reinstall using temporary dev dir "/usr/lib/node_modules/arctis-battery-percentage/node_modules/node-hid/.node-gyp"
gyp WARN install got an error, rolling back install
gyp WARN install got an error, rolling back install
gyp ERR! configure error 
gyp ERR! stack Error: EACCES: permission denied, mkdir '/usr/lib/node_modules/arctis-battery-percentage/node_modules/node-hid/.node-gyp'
gyp ERR! System Linux 5.3.7-2-MANJARO
gyp ERR! command "/usr/bin/node" "/usr/lib/node_modules/node-gyp/bin/node-gyp.js" "rebuild"
gyp ERR! cwd /usr/lib/node_modules/arctis-battery-percentage/node_modules/node-hid
gyp ERR! node -v v12.13.0
gyp ERR! node-gyp -v v6.0.0
gyp ERR! not ok 
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! [email protected] install: `prebuild-install || node-gyp rebuild`
npm ERR! Exit status 1
npm ERR! 
npm ERR! Failed at the [email protected] install script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /root/.npm/_logs/2019-10-30T16_41_40_858Z-debug.log

I don't think that your sofware is only for Windows but for Linux too.

Could you help me for resolving this issue.
You should make a PKBUILD and done an ask for getting it in AUR Package.

BTW. I have a Steelseries Artic Silver 7 Edition 2019.
By advance, thanks a lot.

Python needed?

gyp ERR! find Python You need to install the latest version of Python.
gyp ERR! find Python Node-gyp should be able to find and use Python. If not,
gyp ERR! find Python you can try one of the following options:

Is it possible that python is needed? Or what am i doing wrong?

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.