I would like to generate pages of memory from a script and I think LaTeX is the perfect tool to build a nice PDF. However, I am struggling with the table environment and I don't know how to design the following model (drawn with Illustrator).
The difficulties are:
- Fixed width columns and rows (array of 32 x 32 cells on a 163 x 260 mm table)
- Rotated top headers with no lines
- Bold headers with no lines
- Table border bolder than the internal lines
What I currently did is the following:
\documentclass[a4paper]{article}
\usepackage{array,graphicx}
\usepackage{calc}
\usepackage{booktabs}
\usepackage{geometry}
\usepackage{ifxetex}
\usepackage{booktabs}
\usepackage{pifont}
\usepackage{multirow}
\usepackage{helvet}
\newcommand*\rot{\rotatebox{90}}
\ifxetex
\usepackage{fontspec}
\setmonofont{Latin Modern Mono}
\else
\usepackage{lmodern}
\fi
\renewcommand{\familydefault}{\sfdefault}
\geometry{
a4paper,
total={170mm,240mm},
left=20mm,
top=10mm,
}
\newcolumntype{C}[1]{@{}>{\centering\let\newline\\\arraybackslash\hspace{0pt}}m{#1}}
\newcommand\Tstrut{\rule[0pt]{0pt}{0pt}}
\newcommand\Bstrut{\rule[0pt]{0pt}{0pt}}
\newcommand{\TBstrut}{}
\setlength\extrarowheight{0pt}
\begin{document}
\section*{PAGE 0x01000}
\newcommand\w{0.3cm}
\begin{tabular}{r|C{\w}|C{\w}|C{\w}|C{\w}|C{\w}|C{\w}|C{\w}|C{\w}|C{\w}|C{\w}|C{\w}|C{\w}|C{\w}|C{\w}|C{\w}|C{\w}|C{\w}|C{\w}|C{\w}|C{\w}|C{\w}|C{\w}|C{\w}|C{\w}|C{\w}|C{\w}|C{\w}|C{\w}|C{\w}|C{\w}|C{\w}|C{\w}|}
& \rot{\textbf{0x00}} & \rot{\textbf{0x00}} & \rot{\textbf{0x00}} & \rot{\textbf{0x00}} & \rot{\textbf{0x00}} & \rot{\textbf{0x00}} & \rot{\textbf{0x00}} & \rot{\textbf{0x00}}& \rot{\textbf{0x00}} & \rot{\textbf{0x00}} & \rot{\textbf{0x00}} & \rot{\textbf{0x00}} & \rot{\textbf{0x00}} & \rot{\textbf{0x00}} & \rot{\textbf{0x00}} & \rot{\textbf{0x00}}& \rot{\textbf{0x00}} & \rot{\textbf{0x00}} & \rot{\textbf{0x00}} & \rot{\textbf{0x00}} & \rot{\textbf{0x00}} & \rot{\textbf{0x00}} & \rot{\textbf{0x00}} & \rot{\textbf{0x00}}& \rot{\textbf{0x00}} & \rot{\textbf{0x00}} & \rot{\textbf{0x00}} & \rot{\textbf{0x00}} & \rot{\textbf{0x00}} & \rot{\textbf{0x00}} & \rot{\textbf{0x00}} & \rot{\textbf{0x00}}\\
\hline
\multirow{2}{*}{\textbf{0x00000}} & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 \TBstrut\\
& 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 \TBstrut\\
\hline
\textbf{0x00000} & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 \TBstrut\\
\hline
\textbf{0x00000} & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 \TBstrut\\
\hline
\textbf{0x00000} & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 \TBstrut\\
\hline
\textbf{0x00000} & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 \TBstrut\\
\hline
\textbf{0x00000} & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 \TBstrut\\
\hline
\textbf{0x00000} & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 \TBstrut\\
\hline
\textbf{0x00000} & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 \TBstrut\\
\hline
\textbf{0x00000} & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 \TBstrut\\
\hline
\textbf{0x00000} & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 \TBstrut\\
\hline
\textbf{0x00000} & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 \TBstrut\\
\hline
\textbf{0x00000} & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 \TBstrut\\
\hline
\textbf{0x00000} & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 \TBstrut\\
\hline
\textbf{0x00000} & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 \TBstrut\\
\hline
\textbf{0x00000} & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 \TBstrut\\
\hline
\textbf{0x00000} & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 \TBstrut\\
\hline
\textbf{0x00000} & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 \TBstrut\\
\hline
\textbf{0x00000} & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 \TBstrut\\
\hline
\textbf{0x00000} & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 \TBstrut\\
\hline
\textbf{0x00000} & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 \TBstrut\\
\hline
\textbf{0x00000} & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 \TBstrut\\
\hline
\textbf{0x00000} & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 \TBstrut\\
\hline
\textbf{0x00000} & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 \TBstrut\\
\hline
\textbf{0x00000} & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 \TBstrut\\
\hline
\textbf{0x00000} & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 \TBstrut\\
\hline
\textbf{0x00000} & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 \TBstrut\\
\hline
\textbf{0x00000} & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 \TBstrut\\
\hline
\textbf{0x00000} & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 & 00 & 01 & 02 & 03 \TBstrut\\
\hline
\end{tabular}
\end{document}
Is there a simple way to achieve that I would like?