I am on Sonoma 14.4.1 w. BTT 4.465 and I cannot get the Generic Configuration to work reliably. I am using Heavy's script and everything looks straight forward.
But following the tutorial flow the configured Griffin Powermate does not show on the subsequent triggers. I have tried pushing the save button after the first selection of the HID device and also waiting until completing the analyzer and script entry.
I have tried restarting.
In addition, the selected action worked occasionally. I had volume up and down working on rotation, but mute did not work. After deleting everything and starting over, nothing worked.
What am I missing?
maybe post the full script your are using, then I might be able to see what’s wrong
I just tried again. The configured option disappears even on the item on which it is configured.
It is the script posted on Heavy's site.
// Input Analyser script for Griffin PowerMate
// Select index 0 and 1 in report 0 for monitoring
function analyzeDeviceInput(targetDevice, reportID, reportDataHex) {
let reportBuffer = buffer.Buffer.from(reportDataHex, 'hex'),
// Index 0 is button state. 1 = press, 0 = release.
button = reportBuffer.readUInt8(0),
// Index 1 is amount of movement since last report.
// Signed value, positive for right, negative for left.
// Spinning really fast I have observed a value up to +/- 7,
// lets assume it will never be larger than 9.
movement = reportBuffer.readInt8(1);
if ( movement < 0 ) {
if ( button == 0 ) {
log('left ' + movement);
// We should probably repeat the trigger "movement" times ...
// but that would be too many triggers :)
bttTriggerDeviceTrigger(targetDevice, 'left');
} else {
log('left ' + movement + ' pressed');
bttTriggerDeviceTrigger(targetDevice, 'leftpressed');
}
// If we are spinning we want the next report even if it's the same
bttGetNextEvenWithoutChange(targetDevice, reportID);
}
else if( movement > 0) {
if ( button == 0 ) {
log('right ' + movement);
bttTriggerDeviceTrigger(targetDevice, 'right');
} else {
log('right ' + movement + ' pressed');
bttTriggerDeviceTrigger(targetDevice, 'rightpressed');
}
bttGetNextEvenWithoutChange(targetDevice, reportID);
}
// When button state change index 1 is always 0, even if knob is spinning.
else if ( button === 1 && movement === 0 ) {
log('button press');
bttTriggerDeviceTrigger(targetDevice, 'buttonpress');
}
else if ( button === 0 && movement === 0 ) {
log('button release');
bttTriggerDeviceTrigger(targetDevice, 'buttonrelease');
}
}
The Poweremate registers in the analyzer. I provided the list triggers:
buttonpressed
buttonreleased
left
leftpressed
right
rightpressed
It all looks straight forward. But it does not stick except that it worked for left and right once!
I do not think, it's a script issue. After a device has been configured, ti should show up reliably. It does not. It is even "lost" on the line where it was configured, when I open it again.
Mh yes, the script looks good. You mean the device is not showing in the BTT UI anymore?
I got it to work.
- Deleted everything to start over.
- This time I fully set up the first Top Level Trigger.
- When clicked on the right pane Trigger preset again, the Griffin option had disappeared again.
- I reselected the Generic and Griffin showed up. The Trigger options were still set. When I opened the Analyzer, the custom script was still there. I turned and pressed the button and the events showed up.
- I closed the Window.
- Now Griffin Powermate was available for subsequent additions.
It looks to me like there is a bug in the way settings are saved.