mutli-key keypad and modifier keys

newb here, I cant seem to get modifier or function keys to work inside of a multi-key keypad (using a teensy 3.0), any advice/ solutions?

here is what i have so far

#include <Keypad.h>

const byte ROWS = 4;
const byte COLS = 3; 
char keys[ROWS][COLS] = {
  {'1','2',MODIFIERKEY_CTRL},
  {'4','5','6'},
  {'7','8','9'},
  {'*','0','#'}
};
byte rowPins[ROWS] = {4, 3, 2, 1};
byte colPins[COLS] = {18, 17, 16};

Keypad kpd = Keypad( makeKeymap(keys), rowPins, colPins, ROWS, COLS );



void setup() {
Keyboard.begin();
  kpd.setDebounceTime(1);
}

void loop() {

  if (kpd.getKeys())
  {

    for (int i=0; i<LIST_MAX; i++)   // Scan the entire list.
    {
      if (kpd.key[i].kchar != NO_KEY)    // Test for an active key.
      {
        switch (kpd.key[i].kstate) {
        case PRESSED:
          Keyboard.press(kpd.key[i].kchar);
          if (!kpd.key[i].stateChanged)
          case RELEASED:
            Keyboard.release(kpd.key[i].kchar);
          if (!kpd.key[i].stateChanged)
            break;
        }
      }
    }
  }
}

I cant seem to get modifier or function keys to work inside of a multi-key keypad

Where do you try?

String msg = "";

Why?

,< corrected the code on the op to represent what i am using better, a few things are not in there now.

char keys[ROWS][COLS] = {
  {'1','2',MODIFIERKEY_CTRL},
  {'4','5','6'},
  {'7','8','9'},
  {'*','0','#'}

MODIFIERKEY_CTRL is not working in the matrix any printable character work fine but none printable characters such as F1 or PgUP ect. dont seem to work

Durz_o:
newb here, I cant seem to get modifier or function keys to work inside of a multi-key keypad (using a teensy 3.0), any advice/ solutions?

here is what i have so far

#include <Keypad.h>

const byte ROWS = 4;
const byte COLS = 3;
char keys[ROWS][COLS] = {
 {‘1’,‘2’,MODIFIERKEY_CTRL},
 {‘4’,‘5’,‘6’},
 {‘7’,‘8’,‘9’},
 {’*’,‘0’,’#’}
};
byte rowPins[ROWS] = {4, 3, 2, 1};
byte colPins[COLS] = {18, 17, 16};
Keypad kpd = Keypad( makeKeymap(keys), rowPins, colPins, ROWS, COLS );

void setup() {
Keyboard.begin();
 kpd.setDebounceTime(1);
}

void loop() {
 if (kpd.getKeys())
  {
    for (int i=0; i<LIST_MAX; i++)   // Scan the entire list.
    {
      if (kpd.key[i].kchar != NO_KEY)    // Test for an active key.
      {
        switch (kpd.key[i].kstate) {
        case PRESSED:
          Keyboard.press(kpd.key[i].kchar);
          if (!kpd.key[i].stateChanged)

You need a break; statement here.

          case RELEASED:

Keyboard.release(kpd.key[i].kchar);
          if (!kpd.key[i].stateChanged)
            break;

You may need a default:
break; here to trap any odd events.

        }

}
   }
 }
}

Where are you using MODIFIERKEY_CTRL to modify the output?