RP.PIO.Encoding

Entities

Simple Types

Record Types

Generic Instantiations

Description

Encode

function Encode is new Ada.Unchecked_Conversion (IRQ, PIO_Instruction);

Encode

function Encode is new Ada.Unchecked_Conversion (JMP, PIO_Instruction);

Encode

function Encode is new Ada.Unchecked_Conversion (MOV, PIO_Instruction);

Encode

function Encode is new Ada.Unchecked_Conversion (PULL, PIO_Instruction);

Encode

function Encode is new Ada.Unchecked_Conversion (PUSH, PIO_Instruction);

Encode

function Encode is new Ada.Unchecked_Conversion (SET, PIO_Instruction);

Encode

function Encode is new Ada.Unchecked_Conversion (SHIFT_IN, PIO_Instruction);

Encode

function Encode is new Ada.Unchecked_Conversion (SHIFT_OUT, PIO_Instruction);

Encode

function Encode is new Ada.Unchecked_Conversion (WAIT, PIO_Instruction);

IRQ

type IRQ is record
   Opcode         : HAL.UInt3 := 2#110#;
   Delay_Sideset  : HAL.UInt5 := 0;
   Opcode_2       : Boolean := False;
   Clear          : Boolean := False;
   Wait           : Boolean := False;
   Index          : HAL.UInt5;
end record
   with Size => 16;
Record fields
Opcode
Delay_Sideset
Opcode_2
Clear
Wait
Index

JMP

type JMP is record
   Opcode         : HAL.UInt3 := 2#000#;
   Delay_Sideset  : HAL.UInt5 := 0;
   Condition      : JMP_Condition := Always;
   Address        : HAL.UInt5 := 0;
end record
   with Size => 16;
Record fields
Opcode
Delay_Sideset
Condition
Address

JMP_Condition

type JMP_Condition is
   (Always,
    Scratch_X_Zero,
    Scratch_X_Nonzero_Decrement,
    Scratch_Y_Zero,
    Scratch_Y_Nonzero_Decrement,
    X_Notequal_Y,
    Input_Pin,
    OSRE_Not_Empty)
with Size => 3;
Enumeration Literal
Always
Scratch_X_Zero

!X

Scratch_X_Nonzero_Decrement

X--

Scratch_Y_Zero

!Y

Scratch_Y_Nonzero_Decrement

Y--

X_Notequal_Y

X!=Y

Input_Pin

PIN

OSRE_Not_Empty

!OSRE

MOV

type MOV is record
   Opcode         : HAL.UInt3 := 2#101#;
   Delay_Sideset  : HAL.UInt5 := 0;
   Destination    : MOV_Target := PINS;
   Operation      : MOV_Operation := None;
   Source         : MOV_Target := PINS;
end record
   with Size => 16;
Record fields
Opcode
Delay_Sideset
Destination
Operation
Source

MOV_Operation

type MOV_Operation is
   (None, Invert, Bit_Reverse)
with Size => 2;
Enumeration Literal
None
Invert
Bit_Reverse

MOV_Target

type MOV_Target is
   (PINS, X, Y, EXEC, PC, ISR, OSR)
with Size => 3;
Enumeration Literal
PINS
X
Y
EXEC
PC
ISR
OSR

PULL

type PULL is record
   Opcode         : HAL.UInt3 := 2#100#;
   Delay_Sideset  : HAL.UInt5 := 0;
   Opcode_2       : Boolean := True;
   If_Empty       : Boolean := False;
   Block          : Boolean := False;
   Opcode_3       : HAL.UInt5 := 0;
end record
   with Size => 16;
Record fields
Opcode
Delay_Sideset
Opcode_2
If_Empty
Block
Opcode_3

PUSH

type PUSH is record
   Opcode         : HAL.UInt3 := 2#100#;
   Delay_Sideset  : HAL.UInt5 := 0;
   Opcode_2       : Boolean := False;
   If_Full        : Boolean := False;
   Block          : Boolean := False;
   Opcode_3       : HAL.UInt5 := 0;
end record
   with Size => 16;
Record fields
Opcode
Delay_Sideset
Opcode_2
If_Full
Block
Opcode_3

SET

type SET is record
   Opcode         : HAL.UInt3 := 2#111#;
   Delay_Sideset  : HAL.UInt5 := 0;
   Destination    : SET_Destination := PINS;
   Data           : HAL.UInt5 := 0;
end record
   with Size => 16;
Record fields
Opcode
Delay_Sideset
Destination
Data

SET_Destination

type SET_Destination is
   (PINS, X, Y, PINDIRS)
with Size => 3;
Enumeration Literal
PINS
X
Y
PINDIRS

SHIFT_IN

type SHIFT_IN is record
   Opcode         : HAL.UInt3 := 2#010#;
   Delay_Sideset  : HAL.UInt5 := 0;
   Source         : SHIFT_IN_Source := PINS;
   Bit_Count      : HAL.UInt5;
end record
   with Size => 16;
Record fields
Opcode
Delay_Sideset
Source
Bit_Count

0 = 32

SHIFT_IN_Source

type SHIFT_IN_Source is
   (PINS, X, Y, ZERO, ISR, OSR)
with Size => 3;
Enumeration Literal
PINS
X
Y
ZERO
ISR
OSR

SHIFT_OUT

type SHIFT_OUT is record
   Opcode         : HAL.UInt3 := 2#011#;
   Delay_Sideset  : HAL.UInt5 := 0;
   Destination    : SHIFT_OUT_Destination := PINS;
   Bit_Count      : HAL.UInt5;
end record
   with Size => 16;
Record fields
Opcode
Delay_Sideset
Destination
Bit_Count

0 = 32

SHIFT_OUT_Destination

type SHIFT_OUT_Destination is
   (PINS, X, Y, DISCARD, PINDIRS, PC, ISR, EXEC)
with Size => 3;
Enumeration Literal
PINS
X
Y
DISCARD
PINDIRS
PC
ISR
EXEC

WAIT

type WAIT is record
   Opcode         : HAL.UInt3 := 2#001#;
   Delay_Sideset  : HAL.UInt5 := 0;
   Polarity       : Boolean := False;
   Source         : WAIT_Source := GPIO;
   Index          : HAL.UInt5 := 0;
end record
   with Size => 16;
Record fields
Opcode
Delay_Sideset
Polarity
Source
Index

WAIT_Source

type WAIT_Source is
   (GPIO, PIN, WAIT_IRQ)
with Size => 2;
Enumeration Literal
GPIO
PIN
WAIT_IRQ