Need Strange Character to output in Serial Monitor

I need this symbol:

˅

to output in Serial monitor, as I am using a keypad mapped to this:

<>^˅

All I'm getting however, is this:

What would be your suggestion? A lowercase v doesn't look right as it's different from the other arrows

The Serial monitor is limited to outputting standard ASCII characters in the range 0x20 to 0x126. You cannot use the extended ACII codes above that

1 Like

Well that's a real shame. Phooey. Oh well, I shall use a lowercase v

You can print the ˅ character to the Serial monitor, but you cannot map it directly to a keypad key using the Keypad library. The Serial monitor supports the UTF8 encoding for ˅, which is two bytes 0xCB 0x85, but the keypad key map is limited to single bytes for each key. You could map some unused character to the keypad key, then convert it to the UTF8 character in your code.

1 Like

Could you consider using a different type of display or a terminal emulator that can display the extended ASCII characters ?

It's no that big of a deal. At some point I'll be displaying it on a 1602 LCD, then the Serial Monitor won't be used anymore

Then you can use a custom character and map that directly to a keypad key.

No, it's capable of printing UTF8 characters:

void setup() {
  Serial.begin(115200);
  Serial.print("UTF8(v):");  
  Serial.write(0xcb); Serial.write(0x85);
  Serial.println();
}

void loop() {

}
1 Like

You can also have the UTF8 character directly in the text":

  Serial.print("UTF8(v):˅");

< edit > odd that the website does not show the ˅ character properly in a code block.

1 Like

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.