libpruio  0.6.8
Fast and easy Digital/Analog Input/Output for Beaglebones
pruio_intc.bi File Reference

FreeBASIC header file for interrupt controller defines. More...

This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  __Sysevt_to_Channel_map
 Mapping from system event to interrupt channel. More...
 
class  __Channel_to_Host_map
 Mapping from interrupt channel to host event. More...
 
class  __Pruss_intc_Initdata
 Init data structure for the interrupt controller setting. More...
 

Macros

#define PRUIO_CHAN   /* CHANNEL5 */
 The channel for PRU messages (must match PRUIO_IRPT).
 
#define PRUIO_MASK   /* PRU_EVTOUT5_HOSTEN_MASK */
 The mask to enable PRU interrupts (must match PRUIO_IRPT).
 
#define PRUIO_EMAP   /* PRU_EVTOUT5 */
 The event for PRU messages (mapping, must match PRUIO_IRPT).
 
#define PRUIO_EVNT   /* PRU_EVTOUT_5 */
 The event for PRU messages (must match PRUIO_IRPT).
 
#define PRU0_PRU1_INTERRUPT   /* 17 */
 System event PRU-0 -> PRU-1.
 
#define PRU1_PRU0_INTERRUPT   /* 18 */
 System event PRU-1 -> PRU-0.
 
#define PRU0_ARM_INTERRUPT   /* 19 */
 System event PRU-0 -> ARM.
 
#define PRU1_ARM_INTERRUPT   /* 20 */
 System event PRU-1 -> ARM.
 
#define ARM_PRU0_INTERRUPT   /* 21 */
 System event ARM -> PRU (R31.t30)
 
#define ARM_PRU1_INTERRUPT   /* 22 */
 System event ARM -> PRU (R31.t31)
 
#define CHANNEL0   /* 0 */
 ID for channel 0.
 
#define CHANNEL1   /* 1 */
 ID for channel 1.
 
#define CHANNEL2   /* 2 */
 ID for channel 2.
 
#define CHANNEL3   /* 3 */
 ID for channel 3.
 
#define CHANNEL4   /* 4 */
 ID for channel 4.
 
#define CHANNEL5   /* 5 */
 ID for channel 5.
 
#define CHANNEL6   /* 6 */
 ID for channel 6.
 
#define CHANNEL7   /* 7 */
 ID for channel 7.
 
#define CHANNEL8   /* 8 */
 ID for channel 8.
 
#define CHANNEL9   /* 9 */
 ID for channel 9.
 
#define PRU0   /* 0 */
 ID for PRU-0.
 
#define PRU1   /* 1 */
 ID for PRU-1.
 
#define PRU_EVTOUT0   /* 2 */
 ID for event 0.
 
#define PRU_EVTOUT1   /* 3 */
 ID for event 1.
 
#define PRU_EVTOUT2   /* 4 */
 ID for event 2.
 
#define PRU_EVTOUT3   /* 5 */
 ID for event 3.
 
#define PRU_EVTOUT4   /* 6 */
 ID for event 4.
 
#define PRU_EVTOUT5   /* 7 */
 ID for event 5.
 
#define PRU_EVTOUT6   /* 8 */
 ID for event 6.
 
#define PRU_EVTOUT7   /* 9 */
 ID for event 7.
 
#define PRU0_HOSTEN_MASK   /* &h0001 */
 Interrupt host enable mask for PRU-0.
 
#define PRU1_HOSTEN_MASK   /* &h0002 */
 Interrupt host enable mask for PRU-1.
 
#define PRU_EVTOUT0_HOSTEN_MASK   /* &h0004 */
 Event 0 host enable mask.
 
#define PRU_EVTOUT1_HOSTEN_MASK   /* &h0008 */
 Event 1 host enable mask.
 
#define PRU_EVTOUT2_HOSTEN_MASK   /* &h0010 */
 Event 2 host enable mask.
 
#define PRU_EVTOUT3_HOSTEN_MASK   /* &h0020 */
 Event 3 host enable mask.
 
#define PRU_EVTOUT4_HOSTEN_MASK   /* &h0040 */
 Event 4 host enable mask.
 
#define PRU_EVTOUT5_HOSTEN_MASK   /* &h0080 */
 Event 5 host enable mask.
 
#define PRU_EVTOUT6_HOSTEN_MASK   /* &h0100 */
 Event 6 host enable mask.
 
#define PRU_EVTOUT7_HOSTEN_MASK   /* &h0200 */
 Event 7 host enable mask.
 
#define NUM_PRU_HOSTIRQS   /* 8 */
 Number of PRU host interrupts.
 
#define NUM_PRU_HOSTS   /* 10 */
 Number of hosts mapping channels.
 
#define NUM_PRU_CHANNELS   /* 10 */
 Number of PRU interrupt channels.
 
#define NUM_PRU_SYS_EVTS   /* 64 */
 Number of PRU system events.
 
#define PRUSS0_PRU0_DRAM   /* 0 */
 ID for PRU-0 data ram.
 
#define PRUSS0_PRU1_DRAM   /* 1 */
 ID for PRU-1 data ram.
 
#define PRUSS0_PRU0_IRAM   /* 2 */
 ID for PRU-0 instruction ram.
 
#define PRUSS0_PRU1_IRAM   /* 3 */
 ID for PRU-1 instruction ram.
 
#define PRUSS0_SRAM   /* 4 */
 ID for PRUSS shared ram.
 
#define PRU_EVTOUT_0   /* 0 */
 ID for host interrupt 0.
 
#define PRU_EVTOUT_1   /* 1 */
 ID for host interrupt 1.
 
#define PRU_EVTOUT_2   /* 2 */
 ID for host interrupt 2.
 
#define PRU_EVTOUT_3   /* 3 */
 ID for host interrupt 3.
 
#define PRU_EVTOUT_4   /* 4 */
 ID for host interrupt 4.
 
#define PRU_EVTOUT_5   /* 5 */
 ID for host interrupt 5.
 
#define PRU_EVTOUT_6   /* 6 */
 ID for host interrupt 6.
 
#define PRU_EVTOUT_7   /* 7 */
 ID for host interrupt 7.
 

Typedefs

typedef struct __Sysevt_to_Channel_map tsysevt_to_channel_map
 Forward declaration for event -> channel mapping type.
 
typedef struct __Channel_to_Host_map tchannel_to_host_map
 Forward declaration for mapping type.
 
typedef struct __Pruss_intc_Initdata tpruss_intc_initdata
 Forward declaration for interrupt controler data type.
 

Variables

tpruss_intc_initdata DEF_INTC_INIT
 Default interrupt controller init (we also set default interrupts, so that the other PRUSS can be used in parallel) More...
 

Detailed Description

FreeBASIC header file for interrupt controller defines.

Header file containing the defines and data types used for the interrupt controller setting.

Since
0.6

Definition in file pruio_intc.bi.

Variable Documentation

◆ DEF_INTC_INIT

tpruss_intc_initdata DEF_INTC_INIT
Initial value:
=
TYPE<tpruss_intc_initdata>(
, CAST(BYTE, -1) },
{ TYPE<tsysevt_to_channel_map>(PRU0_PRU1_INTERRUPT, CHANNEL1)
, TYPE<tsysevt_to_channel_map>(PRU1_PRU0_INTERRUPT, CHANNEL0)
, TYPE<tsysevt_to_channel_map>(PRU0_ARM_INTERRUPT, CHANNEL2)
, TYPE<tsysevt_to_channel_map>(PRU1_ARM_INTERRUPT, CHANNEL3)
, TYPE<tsysevt_to_channel_map>(ARM_PRU0_INTERRUPT, CHANNEL0)
, TYPE<tsysevt_to_channel_map>(ARM_PRU1_INTERRUPT, CHANNEL1)
, TYPE<tsysevt_to_channel_map>(PRUIO_IRPT, PRUIO_CHAN)
, TYPE<tsysevt_to_channel_map>(-1, -1)},
{ TYPE<tchannel_to_host_map>(CHANNEL0, PRU0)
, TYPE<tchannel_to_host_map>(CHANNEL1, PRU1)
, TYPE<tchannel_to_host_map>(CHANNEL2, PRU_EVTOUT0)
, TYPE<tchannel_to_host_map>(CHANNEL3, PRU_EVTOUT1)
, TYPE<tchannel_to_host_map>(PRUIO_CHAN, PRUIO_EMAP)
, TYPE<tchannel_to_host_map>(-1, -1) },
)
#define PRUIO_IRPT
The interrupt number to use (25 => /dev/uio5, adapt constructor PruIo::PruIo() in case of changes).
Definition: pruio.hp:105
#define PRU1_ARM_INTERRUPT
System event PRU-1 -> ARM.
Definition: pruio_intc.bi:27
#define ARM_PRU1_INTERRUPT
System event ARM -> PRU (R31.t31)
Definition: pruio_intc.bi:31
#define PRU1_PRU0_INTERRUPT
System event PRU-1 -> PRU-0.
Definition: pruio_intc.bi:23
#define PRUIO_EMAP
The event for PRU messages (mapping, must match PRUIO_IRPT).
Definition: pruio_intc.bi:15
#define PRUIO_MASK
The mask to enable PRU interrupts (must match PRUIO_IRPT).
Definition: pruio_intc.bi:13
#define PRU_EVTOUT0
ID for event 0.
Definition: pruio_intc.bi:58
#define PRU_EVTOUT1_HOSTEN_MASK
Event 1 host enable mask.
Definition: pruio_intc.bi:80
#define PRU1_HOSTEN_MASK
Interrupt host enable mask for PRU-1.
Definition: pruio_intc.bi:76
#define PRU_EVTOUT0_HOSTEN_MASK
Event 0 host enable mask.
Definition: pruio_intc.bi:78
#define PRU0_PRU1_INTERRUPT
System event PRU-0 -> PRU-1.
Definition: pruio_intc.bi:21
#define PRU0_HOSTEN_MASK
Interrupt host enable mask for PRU-0.
Definition: pruio_intc.bi:74
#define PRU0_ARM_INTERRUPT
System event PRU-0 -> ARM.
Definition: pruio_intc.bi:25
#define CHANNEL1
ID for channel 1.
Definition: pruio_intc.bi:36
#define PRUIO_CHAN
The channel for PRU messages (must match PRUIO_IRPT).
Definition: pruio_intc.bi:11
#define PRU0
ID for PRU-0.
Definition: pruio_intc.bi:54
#define ARM_PRU0_INTERRUPT
System event ARM -> PRU (R31.t30)
Definition: pruio_intc.bi:29
#define CHANNEL0
ID for channel 0.
Definition: pruio_intc.bi:34
#define PRU1
ID for PRU-1.
Definition: pruio_intc.bi:56
#define CHANNEL2
ID for channel 2.
Definition: pruio_intc.bi:38
#define CHANNEL3
ID for channel 3.
Definition: pruio_intc.bi:40
#define PRU_EVTOUT1
ID for event 1.
Definition: pruio_intc.bi:60

Default interrupt controller init (we also set default interrupts, so that the other PRUSS can be used in parallel)

Definition at line 191 of file pruio_intc.bi.