EPICS Controls Argonne National Laboratory

Experimental Physics and
Industrial Control System

1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  <20222023  2024  Index 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  <20222023  2024 
<== Date ==> <== Thread ==>

Subject: Re: RTEMS 5 Cannot Read Event Generator
From: "Hamadyk, Paul \(DLSLtd, RAL, LSCI\) via Tech-talk" <tech-talk at aps.anl.gov>
To: "tech-talk at aps.anl.gov" <tech-talk at aps.anl.gov>, "chengsn at ihep.ac.cn" <chengsn at ihep.ac.cn>
Date: Thu, 18 Aug 2022 07:23:24 +0000
I have performed some basic tests with the EVG using the mrfTiming driver with RTEMS 5 and EPICS 7 on an mvme5500. Look at MRF_CONFIG_SITE in mrfApp/src. It says this:

# If you don't know which address modifier your BSP uses for the A24 window,
# then just select one of the answers below (you have a 50% chance of being
# right).  Load the software onto an IOC that contains an Event Generator or
# an Event Recevier card and call either the "EgConfigure" or "ErConfigure"
# routine.  If the routine fails with a message of the form:
#    "Unable to read Event Generator/Receiver Card x (Slot y) at VME/A24
#     address ......",
# then you chose the wrong option. 

I created the config file MRF_CONFIG_SITE_RTEMS-beatnik and set these options:
EPICS_SUPPORTS_CRCSR = YES
BSP_SUPPORTS_CRCSR = YES
ADDRESS_MODE = SUPERVISOR

Do you have the same settings? My base address was set to 0x10000 for the EVG and 0x0 for the EVR, both in the same crate. Here is my A24 address configuration, which should be the default:

Universe Master Ports:
Port  VME-Addr   Size       PCI-Adrs   Mode:
1:    0x00000000 0x00ff0000 0x9f000000 A24, D64 [MBLT], Dat, Sup

Paul.
________________________________________
From: Tech-talk <tech-talk-bounces at aps.anl.gov> on behalf of chengsn via Tech-talk <tech-talk at aps.anl.gov>
Sent: 17 August 2022 10:03
To: tech-talk at aps.anl.gov
Subject: RTEMS 5 Cannot Read Event Generator

Hello all,

I try to running the mrfEventSystem driver with EPICS 7 on RTEMS 5. After modifying part of the code, the driver can read the EVR(EVent Reciever) Card, and it works well. But when I run the driver and use the EVG(EVent Generator), I get this error: EgConfigure: Unable to read Event Generator Card 0 (slot 3) at VME/A24 address 0x1800000.

In st.cmd file, the configuration for the EVG is EgConfigure(0, 3, 0x1800000). When I change the OS from RTEMS to vxWorks(on MVME6100 and MVME5500), the driver can read the EVG.


Here is the hardware I am using:

 EVG: VME-EVG-230.

 EVR: VME-EVG-230-RF.

 Single board computer: MVME6100 and MVME5500.

The software:

 mrfEventSystem Driver Version: MRF Series 200 Event System Software Release V2-4.

 EPICS Version: 7.0.6.1

 RTEMS Version: 5


I also compared the difference between the return value of EVG and EVR in the process of calling the function devReadProbe()(devReadProbe(sizeof(epicsUInt16), pEg, &Junk) and devReadProbe(sizeof(epicsUInt16), pEr, &Junk)).The source of the difference in the return value of devReadProbe() is that the return value of the RTEMS function _BSP_clear_hostbridge_errors() is different. The function as follows:


unsigned long
_BSP_clear_hostbridge_errors(int enableMCP, int quiet)
{
unsigned long rval;

/* MCP is not connected */
if ( enableMCP )
return -1;

rval  = (clear_hose_errors(0, quiet) & PCI_ERR_BITS)>>8;
rval |= clear_hose_errors(BSP_pci_hose1_bus_base, quiet) & PCI_ERR_BITS;

/* Tsi148 doesn't propagate VME bus errors to PCI status reg. */
if ( _BSP_clear_vmebridge_errors )
rval |= _BSP_clear_vmebridge_errors(quiet)<<16;

return rval;
}

(ret = _BSP_clear_hostbridge_errors(0,1); )

The ret is return value of the bspExtMemProbe().

The value of ret: EVR returns 0; EVG returns 0x88FD0000 (in vxWorks and RTEMS, sizeof(long) = 8).

Do you have any suggestions?


Thank you!

chengsn

IHEP

-- 
This e-mail and any attachments may contain confidential, copyright and or privileged material, and are for the use of the intended addressee only. If you are not the intended addressee or an authorised recipient of the addressee please notify us of receipt by returning the e-mail and do not use, copy, retain, distribute or disclose the information in or attached to the e-mail.
Any opinions expressed within this e-mail are those of the individual and not necessarily of Diamond Light Source Ltd. 
Diamond Light Source Ltd. cannot guarantee that this e-mail or any attachments are free from viruses and we cannot accept liability for any damage which you may sustain as a result of software viruses which may be transmitted in or with the message.
Diamond Light Source Limited (company no. 4375679). Registered in England and Wales with its registered office at Diamond House, Harwell Science and Innovation Campus, Didcot, Oxfordshire, OX11 0DE, United Kingdom


Replies:
Re: Re: RTEMS 5 Cannot Read Event Generator chengsn via Tech-talk
References:
RTEMS 5 Cannot Read Event Generator chengsn via Tech-talk

Navigate by Date:
Prev: Re: Re: RTEMS 5 Cannot Read Event Generator chengsn via Tech-talk
Next: RE: EPICS for a small lab - overkill? Sean Leavey - STFC UKRI via Tech-talk
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  <20222023  2024 
Navigate by Thread:
Prev: Re: Re: RTEMS 5 Cannot Read Event Generator chengsn via Tech-talk
Next: Re: Re: RTEMS 5 Cannot Read Event Generator chengsn via Tech-talk
Index: 1994  1995  1996  1997  1998  1999  2000  2001  2002  2003  2004  2005  2006  2007  2008  2009  2010  2011  2012  2013  2014  2015  2016  2017  2018  2019  2020  2021  <20222023  2024 
ANJ, 14 Sep 2022 Valid HTML 4.01! · Home · News · About · Base · Modules · Extensions · Distributions · Download ·
· Search · EPICS V4 · IRMIS · Talk · Bugs · Documents · Links · Licensing ·