r/learnpython • u/DinnerFew9941 • Jan 16 '23
Any way to fake wireless mouse/emulate mouse so PC and programs cannot tell the difference between fake/real?
Ive thought of using a wireless usb dongle for mouse and keyboard but ideally I would like to avoid trying to buy something. Just need to emulate a real mouse so it doesnt look like im moving the mouse with software only.
1
Feb 10 '25
I need to emulate Synergy, i.e. get a networked raspberry to look like a usb mouse and a usb keyboard.
1
u/DinnerFew9941 Feb 10 '25
I never found a solution to my issue sadly. Ditched my project. Doing it with hardware should be easier. Some older versions of the logitech usb receiver (which are able to take input as a keyboard and mouse wirelessly) are vulnerable to wireless input from a signal emitter of your own, essentially you can hack your own dongle and control it with another device. Should work for your usage.
1
Feb 10 '25
Thank you. I can likely write it under a push but if I can buy it it's so much the better.
1
Jan 16 '23
IDK if there's difference but try pyautogui and see.
import pyautogui
pyautogui.move(40, 10) # dx, dy1
u/DinnerFew9941 Jan 16 '23
Im pretty sure there is a difference, that is my issue :(
Already know about pyautogui, just need a way to fake a HID. I was thinking bluetooth maybe?
1
u/no_Im_perfectly_sane Jul 26 '23
are you sure this doesnt work? anti cheat will probably look at the mouse trajectory, so if you can make it appear human like youll fool, I think
just a guess
2
u/DinnerFew9941 Jul 26 '23
Advanced anticheats such as valorant vanguard and others are able to detect when mouse input isnt being put through a USB device. Now that I come back to this post and think about it, i believe the only way to possibly do such a thing is with a virtual driver that pretends to be real. Only issue is idk how to code drivers for windows :(
1
u/saazYesill Mar 18 '24
I been looking for a solution to same problem and your answer gave me a good insight thank you
1
1
u/d_azmann Jan 17 '23
Atmega 32u4 like in an arduino Leonardo act as an HID. Knockoffs can be bought for under $2 USD (at least the last time I bought them).
1
u/DinnerFew9941 Jan 17 '23
My main goal is to avoid buying anything, ideally all in software but emulating a bluetooth device or something? Or if I do buy something I would prefer it be something with more uses than just spoofing HID like for example a bluetooth transmitter or something of the sort
0
4
u/Doormatty I get paid to write Python! Jan 16 '23
You'd first have to figure out what exactly
means. A lot will depend on what exactly you're trying to avoid.