Initial version

Signed-off-by: Knut Ahlers <knut@ahlers.me>
This commit is contained in:
Knut Ahlers 2023-07-04 18:45:06 +02:00
commit b1808fda46
Signed by: luzifer
GPG key ID: D91C3E91E4CAD6F5
4 changed files with 63 additions and 0 deletions

1
.gitignore vendored Normal file
View file

@ -0,0 +1 @@
.pio

41
README.md Normal file
View file

@ -0,0 +1,41 @@
# Luzifer / attiny85-mouse
Using [Barrier](https://github.com/debauchee/barrier) and every time you disconnect the mouse from the gaming PC all the games start freaking out and drawing mouse cursors? Just let them think there still is a mouse attached by emulating a mouse doing exactly nothing!
## Requirements
- [AZDelivery Digispark Rev.3 Kickstarter](https://amzn.to/43g5WZk)
- [Platform.IO](https://platformio.org/) (in my case: [AUR/platformio](https://aur.archlinux.org/packages/platformio))
- [Micronucleus](https://github.com/micronucleus/micronucleus) (in my case: [AUR/micronucleus](https://aur.archlinux.org/packages/micronucleus))
## Build
```console
# platformio run -t upload
Processing attiny85 (platform: atmelavr; board: digispark-tiny; framework: arduino)
[...]
Linking .pio/build/attiny85/firmware.elf
Checking size .pio/build/attiny85/firmware.elf
Advanced Memory Usage is available via "PlatformIO Home > Project Inspect"
RAM: [== ] 18.0% (used 92 bytes from 512 bytes)
Flash: [==== ] 44.2% (used 2656 bytes from 6012 bytes)
Building .pio/build/attiny85/firmware.hex
Configuring upload protocol...
AVAILABLE: custom
CURRENT: upload_protocol = custom
Uploading .pio/build/attiny85/firmware.hex
> Please plug in the device (will time out in 60 seconds) ...
> Device is found!
connecting: 40% complete
> Device has firmware version 1.6
> Available space for user applications: 6012 bytes
> Suggested sleep time between sending pages: 8ms
> Whole page count: 94 page size: 64
> Erase function sleep duration: 752ms
parsing: 60% complete
> Erasing the memory ...
erasing: 80% complete
> Starting to upload ...
writing: 100% complete
>> Micronucleus done. Thank you!
```

10
platformio.ini Normal file
View file

@ -0,0 +1,10 @@
[env:attiny85]
board = digispark-tiny
framework = arduino
platform = atmelavr
board_build.f_cpu = 16500000L
board_build.mcu = attiny85
upload_command = micronucleus --timeout 60 $SOURCE
upload_protocol = custom

11
src/main.ino Normal file
View file

@ -0,0 +1,11 @@
#include <DigiMouse.h>
void setup(){
DigiMouse.begin();
}
void loop() {
for(;;) {
DigiMouse.delay(10000);
}
}