After mapping F12 to O+P with Karabiner elements, maestro cann't simulate the F12 keystroke

All I want to do is pressing O+P simultaneously which cann't be done by maestro alone. After mapping F12 to O+P with Karabiner elements, although maestro has been told to simulate the F12 keystroke, it does not activate O+P keystrokes.

When I press F12 keystroke with my hand, it does activate O+P.

Is there any solution for this problem? Thanks.

Karabiner only captures keyboard presses from the specified device. You can see by going to Karabiner Elements => Devices to see which physical keyboard is being processed through karabiner.

If you run a keyboard maestro macro which simulates a f12 press, it sends... f12 key press to the OS. I can't think of a way that Karabiner can intercept a simulated key press. Maybe applescript key event can be your best bet to mimic a near simultaneous press.

Hi, selina, thanks for the help.

I've been try applescript like this:

tell application "System Events" to keystroke "op"

But it is still not what I want, in my case, these two keystrokes have to be pressed at exactly the same time, or it won't work.

Are you talking about true simultaneous press? or the keys o and p in rapid succession?

You can try fiddling with key down, key up with a delay of whatever ms you define in your applescript. I'm curious how you defined simultaneous key press in your karabiner. Can you show me your json snippet or edn?

Sure, here is the json.

{
  "title": "Mode",
  "rules": [
    {
      "description": "F12",
      "manipulators": [
        {
          "type": "basic",
          "from": {
            "key_code": "f12"
          },
          "to": [
            {
              "repeat": true,
              "key_code": "o"
            },
            {
              "repeat": true,
              "key_code": "p"
            }
          ]
        }
      ]
    }
  ]

It seems to me you need to abstract the UI (o/p “chord”) from the action. And then set up a Keyboard Maestro invocation direct to that action. Rather than ask KM to simulate chorded o/p.

I've define that action in Karabiner elements, the problem is I cann't find a way to implement that action in maestro.