temp0

The beetle dev-board used for wiggl3r.

Summary

I've worked for companies and departments that severely lock down their IT infrastructure, even for those of us in technical roles. A lot of the limitations forced onto the company-issued PCs make sense for the majority, but there are plenty of exceptions and unfortunately bureaucracy prevents flexibilty. You generally get used to the delays and difficulties this causes, or alternatively you find workarounds.

This project is a workaround for the frustration of windows PCs automatically locking after a non-configurable duration.

A small USB device remains connected to an otherwise un-used port. It identifies as a mouse and every sixty seconds it will move the cursor a single pixel (alternating up/down). This is unobtrusive and goes un-noticed by the user, but causes PC to "believe" there is a user present and thus prevents auto-locking.

Further details including the open firmware are available on the gitlab repository.



hardware

wiggl3r running..

This firmware has been tested on two ATmega32U4-based development boards:

The beetle is a cheap ATmega32U4 dev-board with card-edge contacts for directly plugging into a USB type-A port. Because it is firmware-compatible with the Arduino Leonardo, it is safe to assume that this firmware will work with the leonardo itself, as well as other leonardo-compatible boards.

The Pololu A-Star 32U4 Micro uses a different bootloader, but no changes are required to the code. Even the on-board LED is connected to the same pin. The only change needed is to the platformio.ini file if you're using PlatformIO to program the board. Un-changed the file is configured for leonardo-compatible boards. Commenting out the leonardo section and un-commenting the a-star section is all that is required to program the a-star.

In either case, there is an on-board LED that provides a pulsing heart-beat, and briefly switches to full-brightness when it moves the cursor.


firmware

Thanks to the Arduino framework, the firmware was slapped together very quickly. However, the Arduino IDE was not used. Instead the firmware was developed in VSCode using the PlatformIO extension.

A few Arduino functions were used, as well as an Arduino library:

  1. Arduino digital I/O funcions - pinMode(), digitalWrite(). Used for setting the LED as an output and swithcing it on/off.
  2. Arduino analog I/O funcion - analogWrite(). Used to control a PWM signal for varying the LED brightness.
  3. Arduino Mouse library - Mouse.begin() and Mouse.move() functions. Used to emulate a USB mouse.

Arduino doesn't seem to maintain any timer/counter interrupt libraries/functions. Third-party options are available, but instead the timers used were configured by setting the corresponding registers directly and writing specific functions and interrupt sub-routines.

  1. Timer/Counter 1 - configured to trigger an interrupt every second. This interrupt was used to track seconds elapsed since last moving the mouse cursor.
  2. Timer/Counter 3 - configured to update the LED brightness to create the pulsing effect.

wiggl3r logo.