GEX thesis source code, full text, references
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

52 lines
1.4 KiB

\section{Digital Output}
The digital output unit provides a write access to one or more pins of a \gls{GPIO} port. This unit additionally supports pulse generation on any of its pins; this is implemented in software, with timing derived from the system timebase, in order to support pulses on all pins regardless of hardware \gls{PWM} support. Pins in commands are expressed in the packed format (\cref{sec:packedpins}).
\subsection{Digital Output Configuration}
# Port name
# Pins (comma separated, supports ranges)
# Initially high pins
# Open-drain pins
\subsection{Digital Output Commands}
0 & \cname{WRITE} Write to all pins
& \begin{cmdreq}
\cfield{u16} new value
\end{cmdreq} \\
1 & \cname{SET} Set selected pins to 1
& \begin{cmdreq}
\cfield{u16} pins to set
\end{cmdreq} \\
2 & \cname{CLEAR} Set selected pins to 0
& \begin{cmdreq}
\cfield{u16} pins to clear
\end{cmdreq} \\
3 & \cname{TOGGLE} Toggle selected pins
& \begin{cmdreq}
\cfield{u16} pins to toggle
\end{cmdreq} \\
4 & \cname{PULSE}
Generate a pulse on the selected pins. The microsecond scale may be used only for 0--999\,$\mu$s.
& \begin{cmdreq}
\cfield{u16} pins to pulse
\cfield{bool} active level
\cfield{u8} scale: 0--ms, 1--$\mu$s
\cfield{u16} duration