lostallmymoney / razer_mouse_linux Goto Github PK
View Code? Open in Web Editor NEWEnables macros with extra razer buttons. Also works with other devices.
License: Other
Enables macros with extra razer buttons. Also works with other devices.
License: Other
I have bound 1-12 to their respective numbers, and found that the keys 2,3, and 7 do not output anything regardless of what I bind them too. I am not seeing any errors. This is with the Naga Trinity. Worth noting that before trying this fork I tried the original Naga Keymapper project with the same error, was hoping this fork would solve it. Testing in evtest reveals these buttons are not outputting.
So I've been trying them all, 1-9
`config=defaultConfig
1 - key=6
2 - mouseClick=9
3 - key=8
4 - key=v
5 - mouseClick=8
6 - key=9
7 - key=F3
8 - key=i
9 - key=0
10 - key=F4
11 - key=ctrl+w
12 - key=end
13 - key=F5
14 - key=F1
configEnd`
This is the config I want to run, but everything except the mouceClicks seem to work.
I don't know if capitalization has an effect in this case, but your GUIDEKeymap has mouseclick while in the configuration section you have mouseClick. Doesn't really matter, neither works. Can't even simulate a normal '1' click.
In the other issue you mentioned trying to remove the xdotool dependency, so I guess this issue would leave that way too, but I'm still looking for a replacement. In the end I'm just trying to bind the "forwards" and "backwards" key to side-button 2 and 5
Naga Epic Chroma mouse, btw, on Manjaro
Hi,
I tried to install the keypadmapper but it seems not working. I've installed the openrazer with latest commit and it works but it doesn't support the keypad binding.
Thanks.
Hi lostallmymoney,
i have changed distro from Manjaro cinnamon to Garuda KDE, and yesterday i install on the new system your Raazer_mouse.
The first problem i have faced is about when the install script check for dns connection. In my particular case it fails because in my firewall i have block port 53 and it redirects all dns traffic on dns over lts, so i change the script with port 853 and the script finish the installation. I know its only my particular case, for 99% of the system the port 53 it's open.
The real problems i facing are:
The wayland doens't compile. In manjaro no problem, but in my new install maybe i haven't all the requirement, i have to check better. For me it's not a problem because i have nvidia and with kde and wayland it doesn't go well.
The second problem is that when i finish the installation the programm works, but when i reboot no. the naga debug says:
mar 02 09:55:28 garuda systemd[1]: naga.service: Scheduled restart job, restart counter is at 1.
mar 02 09:55:28 garuda systemd[1]: Started Custom key bindings for the side panel of razer mouses..
mar 02 09:55:28 garuda nagaServerCatcher.sh[7282]: Starting X11
mar 02 09:55:28 garuda nagaServerCatcher.sh[7292]: Stopping possible naga daemon
mar 02 09:55:28 garuda nagaServerCatcher.sh[7309]: Authorization required, but no authorization protocol specified
mar 02 09:55:28 garuda nagaServerCatcher.sh[7309]: Unable to connect to X server
mar 02 09:55:28 garuda nagaServerCatcher.sh[7317]: Authorization required, but no authorization protocol specified
mar 02 09:55:28 garuda nagaServerCatcher.sh[7317]: Unable to connect to X server
mar 02 09:55:28 garuda nagaServerCatcher.sh[7292]: Reading from: /dev/input/by-id/usb-Razer_Razer_Naga_Pro_000000000000-if02-event-kbd
mar 02 09:55:28 garuda nagaServerCatcher.sh[7292]: and /dev/input/by-id/usb-Razer_Razer_Naga_Pro_000000000000-event-mouse
If i remade the installation it starts to work.
The third problem is in kde XF86AudioRaiseVolume doesn't work, but Lower and Mute works. That's very stranghe, but i think is a kde problem.
Thanks again for your work and have a nice day.
Hey!
I have used your program for a little while now and found it quite useful. When I first installed it all my side buttons worked but after a while button 1, 2, 4 and 5 stopped working. They do not respond when I assign a key to them via the "keyMap.txt" file. I have tested the buttons on a Windows machine and have concluded that they are not broken.
I am running Manjaro
Operating System: Manjaro Linux Kernel: Linux 5.2.21-1-MANJARO Architecture: x86-64
This is my output from xinput -list
⎡ Virtual core pointer id=2 [master pointer (3)]
⎜ ↳ Razer Razer Naga Trinity id=14 [slave pointer (2)]
⎜ ↳ Razer Razer Naga Trinity Consumer Control id=16 [slave pointer (2)]
⎣ Virtual core keyboard id=3 [master keyboard (2)]
↳ Razer Razer Naga Trinity Keyboard id=15 [slave keyboard (3)]
↳ Razer Razer Naga Trinity System Control id=17 [slave keyboard (3)]
↳ Razer Razer Naga Trinity id=18 [slave keyboard (3)]
↳ Razer Razer Naga Trinity Consumer Control id=20 [slave keyboard (3)]
Any help would be appreciated!
Hey I just tried running this on a Naga Trinity. The default configs work, and binding to various keys like letters and numbers.
However I was not able to bind to numpad keys. This is the config I attempted to run.
config=defaultConfig
1 - key=KP_1
2 - key=KP_2
3 - key=KP_3
4 - key=KP_4
5 - key=KP_5
6 - key=KP_6
7 - key=KP_7
8 - key=KP_8
9 - key=KP_9
10 - key=KP_0
11 - key=KP_Add
12 - key=KP_Subtract
configEnd
Im using a Swedish keyboard layout if that might be affecting the issue. Result I get is
2,4,6,8 => down,left,right,up.
1,3,7,9 => End,PgDn,Home,PgUp
Hi there,
Your project is the closest I've come to getting my Naga Pro to work so thanks for that firstly.
I'm running Ubuntu 23 Wayland and during the install script, I chose to not install for X11 as I only use Wayland.
I can't get the naga service to start, after looking at the debug logs this is what I see. Is it a simple case of this project isn't Wayland ready yet or am I being silly and doing something wrong?
Happy to provide other logs etc
Jun 07 16:13:06 ubenbro systemd[1]: naga.service: Failed with result 'exit-code'.
Jun 07 16:13:59 ubenbro systemd[1]: Started naga.service - Custom key bindings for the side panel of razer mouses..
Jun 07 16:13:59 ubenbro nagaServerCatcher.sh[84906]: dotoold: no process found
Jun 07 16:13:59 ubenbro nagaServerCatcher.sh[84907]: bash: line 1: dotoold: command not found
Jun 07 16:13:59 ubenbro nagaServerCatcher.sh[84908]: Stopping possible naga daemon
Jun 07 16:13:59 ubenbro nagaServerCatcher.sh[84927]: WARNING: running xinput against an Xwayland server. See the xinput man page for details.
Jun 07 16:13:59 ubenbro nagaServerCatcher.sh[84935]: WARNING: running xinput against an Xwayland server. See the xinput man page for details.
Jun 07 16:13:59 ubenbro nagaServerCatcher.sh[84935]: unable to find device ''
Jun 07 16:13:59 ubenbro nagaServerCatcher.sh[84908]: Reading from: /dev/input/by-id/usb-Razer_Razer_Naga_Pro_000000000000-if02-event-kbd
Jun 07 16:13:59 ubenbro nagaServerCatcher.sh[84908]: and /dev/input/by-id/usb-Razer_Razer_Naga_Pro_000000000000-event-mouse
Jun 07 16:14:07 ubenbro nagaServerCatcher.sh[84908]: Error calling method: Object does not exist at path “/org/gnome/Shell/Extensions/WindowsExt”
Jun 07 16:14:07 ubenbro nagaServerCatcher.sh[84908]: WindowNameLog :
Jun 07 16:14:07 ubenbro nagaServerCatcher.sh[84899]: Segmentation fault (core dumped)
Jun 07 16:14:07 ubenbro systemd[1]: naga.service: Main process exited, code=exited, status=139/n/a
Jun 07 16:14:07 ubenbro systemd[1]: naga.service: Failed with result 'exit-code'.```
Issues related to X11 and xdotool might lead you to freezes when using the key* config type.
Reinstalling the whole X11 server might fix it.
If you still have issues I'd "simply" recommend reinstalling ubuntu fresh.
This issue has been running for a long time and since wayland is the successor i don't think we'll see an update very soon.
Hi! I love the ease of use of this tool, but I can't seem to figure out if there's a possible workaround to have it accept simple macros like copy and paste?
Hi,
there was an error while sh install.sh, in that script this line:
sudo cp -f ./src/nagakillroot.sh /usr/local/bin/
sudo chmod 755 /usr/local/bin/nagakillroot.sh
the file name nagakillroot.sh it's wrong because in the src folder the name of the file is:
killroot.sh
Have a nice day.
I'll work on this but we can't open GUI apps for now, I'll work on something but that would be a nice secure layer to leave.
Hi,
i've notice that if i asign a string like this:
5 - string=[email protected]
it prints only namegmail.com without "@"
I miss something?
Thanks
How do I get the remapping to work with numlock on?
I want my mouse's sidebuttons to simulate a keypress on the numpad.
1 on mouse = simulate 1 press on keypad
xdotool seems to be freezing when writing symbols. I'll try to remove the xdotool dependency tomorrow.
Any memleak hunter around ? I know the memory is leaking everytime it creates new FakeKey structs and doesn't fully deallocate them but I'm having a hard time deallocating everything for today.
I rebound the 2nd button to "o", but when I press it, it does this: 2o
This is a razer naga trinity in the 7-button configuration, and I'm using Debian 10.
If you are finding yourself running wayland, you will need to go back to x11 for now.
https://askubuntu.com/questions/1410256/how-do-i-use-x-instead-of-wayland-on-22-04
Followed by
sudo systemctl restart gdm3
!!! Found out the hard way that there's a bug which could make you boot in wayland even with X11 in the settings, or vice-versa.
Hi,
Triggering automatically a config change on window focus would be handy by removing the burden of switching back and forth with chmap.
For example by using xdotool getwindowfocus getwindowname
and adding a trigger
keyword (so not a button) taking a window name string/regex.
What do you think about it ?
when running sh install.sh getting
naga.cpp:125:75: error: cannot convert ‘std::__cxx11::basic_string::iterator’ to ‘const char*’
125 | commandType.erase(remove(commandType.begin(), commandType.end(), ' '), commandType.end());//Erase spaces inside 1st part of the line
| ~~~~~~~~~~~~~~~~~^~
| |
| std::__cxx11::basic_string::iterator
In file included from /usr/include/c++/12.1.0/cstdio:42,
from /usr/include/c++/12.1.0/ext/string_conversions.h:43,
from /usr/include/c++/12.1.0/bits/basic_string.h:3960,
from /usr/include/c++/12.1.0/string:53,
from /usr/include/c++/12.1.0/stdexcept:39,
from /usr/include/c++/12.1.0/system_error:41,
from /usr/include/c++/12.1.0/bits/std_mutex.h:39,
from /usr/include/c++/12.1.0/bits/atomic_wait.h:49,
from /usr/include/c++/12.1.0/bits/atomic_base.h:41,
from /usr/include/c++/12.1.0/atomic:41,
from /usr/include/c++/12.1.0/stop_token:34,
from /usr/include/c++/12.1.0/thread:40,
from fakeKeys.h:6:
/usr/include/stdio.h:152:32: note: initializing argument 1 of ‘int remove(const char*)’
152 | extern int remove (const char *__filename) __THROW;
| ~~~~~~~~~~~~^~~~~~~~~~
Error at compile! Ensure you have g++ installed. !!!Aborting!!!
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.