Title: New Record Interface for Modular Register Map Firmware
1New Record InterfaceforModular Register Map
Firmware
- (a work in progress)
- Eric Björklund
2Current Status
- Strawman Design is essentially complete
- e.g. Mozarts Requiem
- Brookhaven has begun coding on the Event Receiver
driver/device support. - Design points are being vigorously discussed
3Previous (APS) Monolithic Record Style
- One record per EVR
- erevent records mapped events to actions
- One record per EVG
- egevent records defined sequences
- Adding hardware features required adding record
fields - Significant mismatch between APS-style records
and Modular Register Map.
4Proposed Interface
- Replace specialized monolithic records with
standard EPICS record types (bi, bo, mbbi, mbbo,
ai, ao, longin, longout) - Record fields in the previous model are replaced
by individual records. - Features can be added/removed without needing to
recompile/rebuild all your IOCs.
5Basic Addressing Scheme
- VME_IO addressing is used.
- Record function is determined by record type,
signal number, and parameter.
C0 S5 _at_PULSER_DELAY
Set (a0) or Read (ai) Pulser Delay
EVR Card 0
Pulser 5
6Modification to Addressing Scheme
- Object Oriented
- Record function is determined by record type,
device type, signal number, and parameter. - Reflected in EVG section (but not EVR section)
- Possibility of creating custom device support for
event system features.
DTYP EVR Pulser
Object is an Event Receiver Pulser
C0 S5 _at_DELAY
Set (a0) or Read (ai) Pulser Delay
EVR Card 0
Pulser 5
7Example EVG Sequencer
- Three Objects
- Sequences
- Sequence Events
- Sequence RAMs
8Sequences
- Collection of Sequence Events (up to 2048)
- Each sequence has a unique identifying number.
- There may be many (more than 2) sequences defined.
DTYP EVR Sequence
Object is anEvent Generator Sequence
C0 S2 _at_SEQ_UNITS
Select Time Units for Sequence Delays (mbbo)
EVG Card 0
Sequence Number 2
9Sequence Event
- An object, but also a property of a sequence.
- Sequence Events have Names
- Names must be unique within a sequence
- Same name can appear in different sequences
- Sequence event is defined by 2 4 records
- EVENT_CODE (longout)
- EVENT_TIME (ao)
- EVENT_ENABLE (bo)
- EVENT_PRIORITY (longout used to resolve
collisions)
DTYP EVR Sequence
Object is anEvent Generator Sequence
C0 S2 _at_EVENT_CODE CycleStart
Set Event Code for CycleStart Event
Event Name
Event Belongs to Sequence Number 2
EVG Card 0
10Sequence RAM
- System-Wide Functions
- Operating Mode (Single or Multi Sequence)
- Update Mode (Accumulate Changes or Immediate)
- Switch RAMs
- RAM-Specific Functions
- Set Trigger Mechanism
- Set Repeat Mode
- Load Sequence Into RAM
- Start/Stop Sequence RAM
11Sequence RAM Operating Mode
- Single-Seq Mode
- Like the old Alternate Mode
- Treats the card as if there were only one
sequencer - Sequence updates are written to the inactive RAM
- RAMs switch at end of current sequence.
- Sequence RAM 0 is the virtual sequence RAM
- Multi-Seq Mode
- Nothing automatic happens
- You have complete control of the sequence RAMs
12Sequence RAM Update Mode
- Only applicable when operating mode is
Single-Seq - Immediate
- Any change to the sequence takes place
immediately after the end of the current cycle. - Accumulate
- Changes to the sequence do not take effect until
they are told to.
13Sequence RAM Switch Record
- Only applicable when operating mode is
Single-Seq and update mode is Accumulate - Mechanism that signals that sequence changes
should take effect.
14Active Design Questions
- Human-Centric Vs. Hardware-Centric Interface
- Atomic change issues
- e.g. Output Port Assignments
- What is useful?
- e.g Do We Need 2 Event Mapping RAMs?
- Device Support Vs. Asyn
- Multiple-Driver Issues
- e.g. Linux CompactRIO EVR Drivers,Old New
Register Map - Intra-Record Dependencies
- e.g. Sequencer RAMsTime Conversion