Project

General

Profile

PMCUCD Notes

VxWorks PMCUCD Crib Notes, McClure, June 9, 2016

Example run on node pxint. The prompt is "pxint->".

Enter trig_help at prompt to display a list of commands:

pxint->trig_help
trig_help
  trig_event_histogram(index) /*-1=previous, 0=current, 1=oldest */
  trig_event_differences()
  trig_event_listing() /* lists all non-zero events */
  trig_time_stamp()
  trig_event_time(event), trig_event_time_all()
value = 49 = 0x31 = '1'
pxint->

Enter the command to display the information of interest:

pxint->trig_event_listing
Listing of HISTOGRAM of EVENTS: non-zero; current=1, SC=42 Secs.
            current cycle--------->oldest cycle
Histogram =    01     00     03     02
event 00:       0;     1;     1;     1;
event 02:       8;    12;    12;    12;
event 07:    30689;  43343;  43344;  43344;
event 0c:     640;   903;   903;   903;
event 0f:     640;   903;   903;   903;
event 8f:      43;    60;    60;    61;
event aa:      42;    60;    61;    60;
event ab:      42;    60;    61;    60;
event ac:     426;   602;   602;   602;
event ad:     213;   301;   301;   301;
event ae:    2557;  3612;  3612;  3612;
event af:     426;   602;   602;   602;

TotEvents  35726; 50459; 50462; 50461;value = 7 = 0x7

pxint->trig_event_histogram
HISTOGRAM of EVENTS:  largest count=41373, idx=1
event 02:    11;
event 07:  41373;**************************************************
event 0c:   862;*
event 0f:   862;*
event 8f:    57;
event aa:    57;
event ab:    57;
event ac:   574;
event ad:   287;
event ae:  3447;****
event af:   574;
value = 2 = 0x2

pxint->trig_event_differences
Differences in HISTOGRAM of EVENTS: current=2, SC=49 Secs.
            previous cycle--------->oldest cycle
Histogram =    01     00     03
event 07:    43340;  43344;  43344;
event 8f:      60;    60;    61;
event aa:      60;    61;    60;
event ab:      60;    61;    60;
value = 2 = 0x2
pxint->

Enter pmcucd_help:

pxint->pmcucd_help
pmcucd_help
  pmcucd_status(pmcucd, status_mask) /*0 implies 0xFFFF*/
  pmcucd_status_all(pmcucd, status_mask) /*0 implies 0xFFFF*/
  pmcucd_dump(pmcucd, address, len) /* pmcucd=NULL implies first pmcucd */
  pmcucd_modify(pmcucd, address)
  pmcucd_command(pmcucd, cmd)
  pmcucd_diagnostic(pmcucd)
  pmcucd_get_time_stamp(pmcucd)
  pmcucd_clr_time_stamp(pmcucd)
value = 33 = 0x21 = '!'
<pre>

Enter the command to display the information of interest:
<pre>
pxint->pmcucd_status
MDat NOT Present
TClock Enable
MDat Buffer Zero Enable
TClock FIFO Empty
value = 293 = 0x125
</pre>

Entering pmcucd_diagnostic will display address of the pmcucd, interrupt information, structures that refer to interrupt events, events with time-stamp to be stored in FIFO and the event that resets the time-stamp to zero.
<pre>
pxint->pmcucd_diagnostic
pmcucd name is pmcucd; card structure @0x26cf010, card address @0x87040000 card 
mem address @0x87041000
PMC registers.......
  vector[0]=0x0 mux[0]=0x0
  vector[1]=0x0 mux[1]=0x0
  vector[2]=0x48 mux[2]=0x3
  vector[3]=0x48 mux[3]=0x4
  vector[4]=0x0 mux[4]=0x0
  vector[5]=0x0 mux[5]=0x0
  vector[6]=0x0 mux[6]=0x0
  vector[7]=0x0 mux[7]=0x0
  revision=0x4a
  sw=0x0
  timer_enable=0x0
0...DISABLED source mux=0x0
1...DISABLED source mux=0x0
2...ENABLED 0x1048,  source mux=0x3
3...ENABLED 0x1048,  source mux=0x4
4...DISABLED source mux=0x0
5...DISABLED source mux=0x0
6...DISABLED source mux=0x0
7...DISABLED source mux=0x0
AUX  0:  RESERVED..............
AUX  1:  RESERVED..............
AUX  2:
struct @0x269f9d0; event=0x7...............
  event_ts=0xffffff07, routine=0x319412c, rtn_arg=0x0, pmcucd=0x26cf010
      routine name=pmcucd_int60hz
  scaler=1, scaler_cnt=1,  vector=72
struct @0x270b240; event=0x7...............
  event_ts=0xffffff07, routine=0x32d65a8, rtn_arg=0x0, pmcucd=0x26cf010
      routine name=snsh_720_events
  scaler=1, scaler_cnt=1,  vector=72
struct @0x270bdb0; event=0x7...............
  event_ts=0xffffff07, routine=0x32ca7d4, rtn_arg=0x0, pmcucd=0x26cf010
      routine name=stats
  scaler=1, scaler_cnt=1,  vector=72
struct @0x2711e90; event=0x7...............
  event_ts=0xffffff07, routine=0x3365ad0, rtn_arg=0x3381300, pmcucd=0x26cf010
      routine name=_ZN6Timing25EvtTrigTclkEventGenerator12_pmcucdISR07EP16PMCAUX
_interruptPv
  scaler=1, scaler_cnt=1,  vector=72
struct @0x26e5090; event=0x7...............
  event_ts=0xffffff07, routine=0x3369c08, rtn_arg=0x4f24b50, pmcucd=0x26cf010
      routine name=_ZN6Timing18PMCUCDTimingSystem12_pmcucdISR07EP16PMCAUX_interr
uptPv
  scaler=1, scaler_cnt=1,  vector=72
struct @0x26e5f90; event=0x7...............
  event_ts=0xffffff07, routine=0x32aa398, rtn_arg=0x26e5b40, pmcucd=0x26cf010
      routine name=_ZN10ClassACNet6FtpIsrEP17AUX_interrupt_tagPNS_6PortalE
  scaler=1, scaler_cnt=1,  vector=72
AUX  3:
struct @0x26e9340; event=0xf...............
  event_ts=0xffffff0f, routine=0x32aa430, rtn_arg=0x26e5b40, pmcucd=0x26cf010
      routine name=_ZN10ClassACNet13TimeKeeperIsrEP17AUX_interrupt_tagPNS_6Porta
lE
  scaler=1, scaler_cnt=1,  vector=72
 Events NOT in FIFO: trigger=0
   event 0x7: FIFO, trigger memory=0x4
 Events which CLR TIME STAMP: trigger=1
   event 0x2: CLEAR TIME STAMP, trigger memory=0x3
value = 0 = 0x0
pxint->
</pre>

The pmcucd register space address is displayed at the top of the results of “pmcucd_diagnostics” command. The address 0x87040042 displays the module status. The LSB at that address indicates TCLOCK is present=1/not present=0. The bit-2 indicates if TCLOCK is enabled. The register at address 0x87040040 is the command register. Writing a 0x0001 will enable TCLOCK, writing a 0x0002 will disable TCLOCK. The register pair at 0x87040046 and 0x87040048 displays the current time-stamp. Address 0x8704004A determines which column in EVENT MEMORY resets the time-stamp and also what column writes to the EVENT FIFO. Adresses beginning at 0x87040060 and 0x87040070 allow interrupts to be:
•    Enabled
•    Level selected
•    Vector choice
•    Interrupt source 
<pre>
pxint->d 0x87040000
NOTE: memory values are displayed in hexadecimal.
0x87040000:  0000 0000 0000 0000 0000 0000 0000 0000  *................*
0x87040010:  0000 0000 0000 0000 0000 0000 0000 0000  *................*
0x87040020:  0000 0000 0000 0000 0000 0000 0000 0000  *................*
0x87040030:  0000 0000 0000 0000 0000 0000 0000 0000  *................*
0x87040040:  0001 0125 0000 15e5 b900 0102 007f 4a00  *...%..........J.*
0x87040050:  0000 0000 0000 0000 0000 0000 0000 0000  *................*
0x87040060:  0000 0000 1048 1048 0000 0000 0000 0000  *.....H.H........*
0x87040070:  0000 0000 0003 0004 0000 0000 0000 0000  *................*
0x87040080:  0000 0000 0000 0000 0000 0000 0000 0000  *................*
0x87040090:  0000 0000 0000 0000 0000 0000 0000 0000  *................*
0x870400a0:  0000 0000 0000 0000 0000 0000 0000 0000  *................*
0x870400b0:  0000 0000 0000 0000 0000 0000 0000 0000  *................*
0x870400c0:  0000 0000 0000 0000 0000 0000 0000 0000  *................*
0x870400d0:  0000 0000 0000 0000 0000 0000 0000 0000  *................*
0x870400e0:  0000 0000 0000 0000 0000 0000 0000 0000  *................*
0x870400f0:  0000 0000 0000 0000 0000 0000 0000 0000  *................*
value = 0 = 0x0
pxint->
</pre>