• With the below skeleton code I'm trying to send a TAB character (or should it be keypress?) instead of the letter A's. The intention is to control a program which is using the TAB-key to navigate forward, and SHIFT-TAB backward.

    If I intepreted the reference at https://www.espruino.com/modules/ble_hid_keyboard.js correctly, "\t" might be TAB, but have not succeeded in replacing the ..KEY.A.. with ..KEY."\t".. or with some other variations.
    Can this be done, if so, how?

    var kb = require("ble_hid_keyboard");
    NRF.setServices(undefined, { hid : kb.report });
    
    function btnPressed() {
      // Send 'a'
      kb.tap(kb.KEY.A, 0, function() {
        // Followed by capital 'A'
        kb.tap(kb.KEY.A, kb.MODIFY.SHIFT);
      });
    }
    
    // trigger btnPressed whenever the button is pressed
    setWatch(btnPressed, BTN, {edge:"rising",repeat:true,debounce:50});
    
About