
GR716-DS-UM, May 2019, Version 1.29
264
www.cobham.com/gaisler
GR716
29.1
Overview
All 64 external pins can be configured as general purpose I/O. Each external pin in the general pur-
pose mode can be individually set to input or output, and can optionally generate an interrupt. For
interrupt generation, the input can be filtered for polarity and level/edge detection.
The GR716 microcontroller implements sequencer and sampler support for up to 8 individual general
purpose I/O. Each sequencer/sampler supports a input/output sequence up to 32 bits. Longer
sequences can be supported by cascading multiple general purpose I/O sequencer. By cascading the
maximum sequence length is 4x32 bits.
The GR716 microcontroller comprises two GPIO units with support of 32 general purpose I/O each.
Each separate GPIO unit has 4 sequencers. The split of the GPIOs into 2 units also separates the
sequencers into 2 groups of 4 individual sequencers. Hence it is only possible to cascade sequencers
within the same GPIO unit. Sequencer units 0, 1, 2 and 3 are connected and controlled via GPIO unit
0 while sequencer units 4, 5, 6 and 7 are connected and controlled via GPIO unit 1.
This chapter describes one GPIO unit. The two GPIO units in the GR716 are identical except for the
physical external pin connected to GPIO unit 1 and GPIO unit 2. For separation in this document
GPIO unit 1 are connected to external pins 0 to 31 and includes sequencer 0, 1, 2 and 3. GPIO unit 2
are connected to external pins 32 to 64 and includes sequencer 4, 5, 6 and 7. Each GPIO unit have a
unique AMBA address described in chapter 2.11.
Note sequencer pins included in a cascaded chain doesn’t occupy a physical pin or pad
29.2
Operation
All external I/Os have bi-directional buffers with programmable output enable. The input from each
buffer is synchronized by two flip-flops in series to remove potential meta-stability. The synchronized
values can be read-out from the I/O port data register. The output enable is controlled by the I/O port
direction register. A ‘1’ in a bit position will enable the output buffer for the corresponding I/O line.
The output value driven is taken from the I/O port output register.
The GPIO interrupts has been implemented to support dynamic mapping of interrupts, each I/O line
can be mapped using the Interrupt map register(s) to an interrupt line.
Interrupt generation is controlled by three registers: interrupt mask, polarity and edge registers. To
enable an interrupt, the corresponding bit in the interrupt mask register must be set. If the edge regis-
ter is ‘0’, the interrupt is treated as level sensitive. If the polarity register is ‘0’, the interrupt is active
low. If the polarity register is ‘1’, the interrupt is active high. If the edge register is ‘1’, the interrupt is
edge-triggered. The polarity register then selects between rising edge (‘1’) or falling edge (‘0’).
The GPIO core includes an Interrupt flag register that can be used to determine if, and which, GPIO
pin that caused an interrupt to be asserted.
29.3
Pulse command
The pulse command outputs use one of the GR716 microcontroller common counter for establishing
the pulse command start and length. The pulse command length defines the logical active part of the
pulse. It is possible to select which of the channels shall generate a pulse command. The pulse com-
mand outputs are generated in phase with a selected trigger source. To send synchronized pulse com-
mands on multiple outputs simultaneously the same trigger source shall be enabled for the selected
outputs.
29.4
Pulse sequencer
GPIO output pin can be programmed to output a predefined sequence. The sequence is defined in the
sequence memory and have the following configuration options: