/actuator

Golang library that allows you to actuate your MacBook Force Touch trackpad

Primary LanguageObjective-CThe UnlicenseUnlicense

Actuate your Force Touch trackpad

go.dev reference

Warning! The code relies on private macOS APIs, so no guarantees.

Example

package main

import (
    "github.com/aprosvetova/actuator"
    "time"
)

func main() {
    for {
        actuator.Down(actuator.HapticFeedbackTypeStrong)
        time.Sleep(20 * time.Millisecond)
        actuator.Up(actuator.HapticFeedbackTypeStrong)
        time.Sleep(100 * time.Millisecond)
    }
}