Skip to content

About

MacOS app to make function keys default on Logitech k380 bluetooth keyboard

Resources

Stars

3 stars

Watchers

0 watching

Forks

 
 

Repository files navigation

k380-function-keys-conf

MacOS app to make function keys default on Logitech k380 bluetooth keyboard

Instalation

  1. Install hidapi library
brew install hidapi
  1. Build this app
# suitable for intel chip mac
./build_Intel.sh

# suitable for apple silicon mac
./build_Apple_Silicon.sh
  1. Run it as root (Note that you might be asked to give permissions for terminal app to access input device)
sudo ./k380 -f on

Linux

Build a native Linux binary with the hidapi-hidraw backend:

# Arch: sudo pacman -S hidapi
# Debian/Ubuntu: sudo apt install libhidapi-dev
# Fedora: sudo dnf install hidapi-devel
./build_Linux.sh
sudo ./k380-linux -f on

build_Linux.sh writes ./k380-linux (ELF) and never overwrites the tracked macOS ./k380 binary, so one checkout can serve both systems. To expose the same k380 command as on macOS, see TROUBLESHOOTING.md.

Troubleshooting

k380 links against the Homebrew hidapi dylib at runtime, so hidapi must stay installed after building. Homebrew does not know this hand-built binary depends on it, so brew autoremove / cleanup may remove it as an orphan.

If running k380 aborts with:

dyld[...]: Library not loaded: /opt/homebrew/opt/hidapi/lib/libhidapi.0.dylib
  Referenced from: .../k380
  Reason: tried: '/opt/homebrew/opt/hidapi/lib/libhidapi.0.dylib' (no such file)

just reinstall it:

brew install hidapi

To prevent it from being removed again, either pin it (brew pin hidapi) or make the binary self-contained by copying the dylib next to it and rewriting the load path with install_name_tool. See AGENTS.md for the full details.

Based on

https://github.com/jergusg/k380-function-keys-conf

About

MacOS app to make function keys default on Logitech k380 bluetooth keyboard

Resources

Stars

3 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages