.TH od "" "" Command
.PC "Print an octal dump of a file"
\fBod [\-bcdox] [\fIfile\^\fB] [ [+] \fIoffset\fB[.][b] ]\fR
.PP
.HS
.SH Options:
.IC \fB\-b\fR
Dump bytes in the default base
.IC \fB\-c\fR
Dump bytes as ASCII characters
.IC \fB\-d\fR
Dump words in decimal
.IC \fB\-o\fR
Dump words in octal
.IC \fB\-x\fR
Dump words in hexadecimal
.Pp
Default base is octal on the PDP-11; hexadecimal on the i80286,
Z-8001, and M68000.
\fIoffset\fR must be preceded by `+' if \fIfile\fR is omitted.
\fIoffset\fR is decimal if `.' is present;
`b' implies 512-byte blocks instead of bytes.
.HE
.B od
prints the specified
.I file
as a sequence of octal numbers, or machine words.
If no
.I file
is specified,
.B od
dumps the standard input.
.PP
The following options set the format of \fBod\fR's output:
.DS
	\fB\-b\fR	Bytes in default base
	\fB\-c\fR	Bytes in ASCII characters
	\fB\-d\fR	Words in decimal
	\fB\-o\fR	Words in octal
	\fB\-x\fR	Words in hexadecimal
.DE
.PP
The default base is octal on the PDP-11 and hexadecimal on the i80286,
Z-8001, and M68000 families of microprocessors.
.PP
Dumping can start at position
.I offset
into the file.
The specified
.I offset
is octal unless the `.' suffix is present to signify decimal.
.I offset
is in bytes unless the
.B b
suffix is present to signify 512-byte blocks.
.SH "See Also"
.Xr "ASCII," ascii
.Xr "commands," commands
.Xr "conv," conv
.Xr "db," db
.Xr "strings" strings
