1

I am looking for an app just like Enjoyable, Enjoy 2, Controllers, etc on Mac (non-silicon if that matters) provides a way to send keyboard combinations (e.g Cmd+Shift+A) from a JoyStick controller.

The aforementioned apps only send single keys/buttons, e.g. Enjoyable is pictured below showing a single key input.

enter image description here

2 Answers 2

0

It looks like Enjoyable can be modified since it is open source: https://git.yukkurigames.com/?p=enjoyable.git;a=tree

Run git clone http://git.yukkurigames.com/enjoyable.git

I know this isn't an easy answer, but I'm not sure there is one.

0

Actually, I just got BetterTouchTool to accept input from a game controller. It takes a bit of scripting, but can be very powerful. I now have like a remote to do certain things or a control box using my switch wired game controller.

https://docs.folivora.ai/docs/1500_generic_devices.html

BetterTouchTool Game Controller Inputs

My script when clicking Parse Device Input/Output looks like this:

// Enter your input analyzer script here. 
// Do not change the function signatures
function analyzeDeviceInput(targetDevice, reportID, reportDataHex) {
      
    let reportBuffer = buffer.Buffer.from(reportDataHex, 'hex');
    // the values you see above are in hex format. To read such a byte
    // use readUInt8(index).
    if(reportBuffer.readUInt8(0) === 0x04) {
        log('a trigger!');
        bttTriggerDeviceTrigger(targetDevice, 'Abutton');
    }
    if(reportBuffer.readUInt8(0) === 0x02) {
        log('b trigger!');
        bttTriggerDeviceTrigger(targetDevice, 'Bbutton');
    }
    if(reportBuffer.readUInt8(0) === 0x08) {
        log('x trigger!');
        bttTriggerDeviceTrigger(targetDevice, 'Xbutton');
    }
    if(reportBuffer.readUInt8(0) === 0x01) {
        log('y trigger!');
        bttTriggerDeviceTrigger(targetDevice, 'Ybutton');
    }
    // If you want to get the next report even though,
    // the data has not changed, call this function:
    // bttGetNextEvenWithoutChange(targetDevice, reportID)
}

// Advanced, optional. Use if you want to trigger commands that send data to
// the device, from a BTT predefined action.
// See https://docs.folivora.ai/1500_generic_devices.html
async function executeBTTCommand(targetDevice, commandName, commandInput) {
    log("execute command: " + commandName)
    switch(commandName) {
        case "exampleCommand": {
            // send any hex string to the device
            let deviceResponse = await bttSendDataToDevice({
              BTTActionSendDataTargetDevice: targetDevice,
              BTTActionSendDataData: 'FEEDC0DE',
              BTTActionSendDataReportType: 1,
              BTTActionSendDataResponseType: -1,
              BTTActionSendDataResponsePrefix: ''
            }); 
            break;
        }
    }
    return 'done executing ' + commandName
}

This is the controller I used: Nintendo Switch Controller (wired)

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.