hexadecimal dump of ascii charaters
Control characters may be described as doing something when the user inputs them, such as code 3 (End-of-Text character, ETX, ^C) to interrupt the running process, or code 4 (End-of-Transmission character, EOT, ^D), used to end text input on Unix or to exit a Unix shell. These uses usually have little to do with their use when they are in text being output.
The control characters in ASCII still in common use include:
hex: 00 (decimal: 00, null, NUL, \0, ^@)
, originally
intended to be an ignored character, but now used by many programming
languages including C to mark the end of a string.hex: 07 (decimal: 07, bell, BEL, \a, ^G)
, which may
cause the device to emit a warning such as a bell or beep sound or the
screen flashing.hex: 08 (decimal: 08, backspace, BS, \b, ^H)
, may
overprint the previous character.hex: 09 (decimal: 09, horizontal tab, HT, \t, ^I)
,
moves the printing position right to the next tab stop.hex: 0A (decimal: 10, line feed, LF, \n, ^J)
, moves the
print head down one line, or to the left edge and down. Used as the end
of line marker in most UNIX systems and variants.hex: 0B (decimal: 11, vertical tab, VT, \v, ^K)
,
vertical tabulation.hex: 0C (decimal: 12 form feed, FF, \f, ^L)
, to cause a
printer to eject paper to the top of the next page, or a video terminal
to clear the screen.hex: 0D (decimal: 13, carriage return, CR, \r, ^M)
,
moves the printing position to the start of the line, allowing
overprinting. Used as the end of line marker in Classic Mac OS, OS-9,
FLEX (and variants). A CR+LF pair is used by CP/M-80 and its derivatives
including DOS and Windows, and by Application Layer protocols such as
FTP, SMTP, and HTTP.hex: 1A (decimal: 26, Control-Z, SUB, ^Z)
, Acts as an
end-of-file for the Windows text-mode file i/o.hex: 1B (decimal: 27, escape, ESC, \e (GCC only), ^[)
.
Introduces an escape sequence.from man ascii
od
to see the hex value for charactersod -t a -t x1 -t c
-t a
- prints in ascii format-t x1
- prints in hex format-t c
- prints in c escape formate.g.
> printf '\0\a\b\n\r\t\v ' | od -t a -t x1 -t c
0000000 nul bel bs nl cr ht vt sp
00 07 08 0a 0d 09 0b 20
\0 \a \b \n \r \t \v
0000010
https://www.soscisurvey.de/tools/view-chars.php