FESA3 2.2.2/2.3.2 FAQ - Frequently Asked Questions
Working with Projects in Eclipse
- How to import an existing FESA class/FESA deploy-unit into the workspace ?
- Copy the class to your workspace or check it out via SVN
- Open the C++ perspective or the FESA perspective
- File --> Import --> "Existing Projects into Workspace"
- Browse to the root directory of the project(s) you want to add.
- Select the project(s) to import.
- Press "Finish"
Working with FESA3 in Eclipse
- How can I find out more on working with the FESA3 Eclipse plug-in?
- The FESA3 Eclipse plug-in ships with a number of "cheat sheets". The cheat sheets are integrated into the Eclipse IDE and can be accessed via the menu: Help > Cheat Sheets... . Open the folder named FESA from the cheat sheet list to select a cheat sheet to work with. The information of each step inside a cheat sheet will be displayed when clicking on "Start working on this task" and "Click to begin" in the introduction to each task. To display the wiki links select them and copy them into the browser of your choice.
- Where do I find example FESA3 software?
- The default of a new value-item is scalar. How can I use arrays?
- One way is to select the value-item's type <sclar> in the class design (Design View). Right-click to open the context menu and select the desired array, array2D, custom-type-array, etc .
The same works reverse, array types can be replaced by scalars as well.
- How can I comment or copy nodes in the design view of a FESA design?
- Right-click on any XML element and select <Comment> or <Copy> from the context menu.
Working with FESA3 on the commandline
- Can I use FESA3 on the commandline? Can I write a shell script for frequently occuring FESA3 operations?
- Yes. Frequently used operations from the FESA3 workflow are accessible via a commandline interface.
- How can I use the FESA3 command line interface?
- The FESA3 command line interface is based on JAVA. For Linux users in the fesa group on the as cluster the tool is fully accessible. Running 'fesa3' displays a list of the possible options. More information: https://www-acc.gsi.de/wiki/FESA/FESA3CLITool232
Plug-In Configuration
- What can I do to see more log-messages?
- In Window > Preferences > FESA > Log Preferences select the log level. Log level INFO allows to see detailed output of various FESA actions, e.g. the delivery paths during deployment.
- How do I set Eclipse's Secure Storage master password?
- E.g. the first time an SVN repository location is accessed the secure storage mechanism becomes active and asks the user to provide a master password. If a master password is entered the FESA plug-in requests this information during the start-up phase.
- How do I reset Eclipse's Secure Storage master password?
- On the Secure Storage Settings page in Window > Preferences > General > Security > Secure Storage select on the Contents tab the Default Secure Storage entry and press delete.
- How do I get rid of obsolete perspectives in Eclipse, e.g. <FESA> / <<FESA>> after repeated updates or new installations of the FESA plug-in?
- Open Window>Preferences>General>Perspectives, from the list of available perspectives delete the unwanted ones.
- How do I convince the build console to appear automatically in the front during a build?
- The full path for the console settings in Eclipse Kepler in the preferences is Window>Preferences>C++>Build>Console>Bring console to top when building (if present). It is also possible to search the preferences with the keyword "console" to find this option.
FESA Design
- In setting properties warning recommend to introduce min-/max- items for each value-item. What is this?
- The usage of min- and max- items per value-item is recommended to allow applications to define lower and upper bounds for these values. Otherwise they behave like normal value-items.
FESA Error Messages
- How do I treat the cryptic error messages in my instance file: "cvc-pattern-valid: Value ' {myStatusLabel1,myStatusLabel2}' is not facet-valid with respect to pattern '(\{)([ -z\{\}]*)(\})' for type '#AnonType_valueAdetailedStatus_labelsType'."
FESA3 Software on a 64-bit FEC / on an 64-bit SCU
- How do I mount the required FESA directories on a (virtual) front-end?
- Create a directory matching the hostname of the (virtual) front-end in /common/export/nfsinit/ and provide a symbolic link to the FESA initialization script similar to the one in e.g. /common/export/nfsinit/vmla02/ .
- How do I launch a FESA3 deploy-unit automatically on a (virtual) front-end?
- How do I configure the deploy-unit to use White Rabbit based timing?
- On an 64-bit FEC / SCU the damon launching the FESA deploy-unit automatically detects whether the deploy-unit uses White Rabbit based timing. The instantiation is parsed for expected information. The required parameters for the launch are applied only if the FAIR timing system is selected in the instantiation document.
- How do I test whether my FESA software is running and accessible for applications?
- Raphael M. kindly provided a tool ( see wiki page) to test the full stack from the top:
/common/usr/cscosv/opt/cscosv-device-test/bin/cscosv-device-test.sh <device instance name> <property name>
- The tool will not only print the data it received but also summarize at the end in which layer problems appeared. Example:
...
--------------- Result Summary ---------------
Device : 'XYR01LB1'
Property : 'Status'
Nameserver : success
CMW/RDA3 (get) : success
JAPC (get) : success
CMW/RDA3 (subscribe) : success
JAPC (subscribe) : success
- The official wiki page: https://www-acc.gsi.de/wiki/Service/SvDeviceTest
- How do I quickly test whether my FESA software is running and accessible via RDA3 directly?
- Use the RDA3 C++ client software which is available for the FESA developers on the asl cluster:
- get-rda3-c++, set-rda3-c++, subscribe-rda3-c++
user@asl73x:~> get-rda3-c++ -d TestDevice0 -p Status
FESA Framework Services
- When is the persistency file written ?
- The default interval is: 300 s (3 m). After a new setting was applied, a delay of 30 s is forced. As well there is a possibility to trigger persistency "by hand".
The default interval and the delay both can be configured in the fesa.cfg file. (On the asl cluster or on 32-bit
FECs it is possible to pass the configuration file of your choice via an application argument )
Migrating to newer FESA3 FWK versions
- After updating from FESA3 2.0.1 to FESA3 2.2.2 the following error occurs:
"cvc-complex-type.2.4.a: Invalid content was found starting with element 'acquisition-context-field-ref'. One of '{beamProcessID}' is expected."
- The element acqisition-context-field-ref element must be the last element of the acquisition-context-item. To resolve this error move this element behind the closing XML-tag of sequenceId.
Documentation
- How do I provide documentation for a FESA3 class?
C++ Programming
- How do I use C++ editing support?
- Eclipse offers the possibility to define code fragments that can be inserted by typing the name of the fragment and pressing CTRL+SPACE. For C++ a huge collection is already available and can be configured in Window > Preferences > C/C++ > Editor > Templates. For FESA3 related code a collection of code templates is defined.
- How do I place 2D-Arrays in the RDA data container using C++?
string testString = "This is a test string";
const char ** stringArray = new const char*[11];
for (int i = 0; i < 11 ; i++) {
stringArray[i] = testString.c_str();
}
long dims[2] = {11,25};
data.insert("dim_charArrayValue", dims, 2);
data.insert("charArrayValue", stringArray, 11);
- How do I enable / disable my own DEBUG messages within a FESA class?
- How do I use preprocessor directives to enable MOCK sections?
- If the preprocessor directive is going to be reused within several source files:
- Define a C++ helper class within <class project>/src/<class name>/Common/UserCode, e.g. <class name>Helper, make sure you have the same namespace as the FESA class itself
- define the preprocessor directive you need in the header, e.g. MOCK_<class name>
- in the source file you would like to use the preprocessor directive:
- include the helper class using #include <<class name>/Common/UserCode/<class name>Helper.hpp>
- use the directive #ifdef MOCK_<class name> around the section you use for mocking, etc
- if the preprocessor directive is uncommented in the helper classes' header the section will be executed during runtime
- if the preprocessor directive is commented the section will be ignored
- How do I use the hasDataChanged()-method in custom get actions?
- The hasDataChanged()-method was introduced to filter manual notifications. The default implementation returns true, but manual checks can be implemented to trigger manual notifications. A typical use-case for this method is data filtering at the real-time level. The method is also intended to steer when to send updated data. Keywords: on-change / subscription.
- How do I send manual notifications from an RT actions to other properties in a FESA class?
- Given that the FESA class design is already prepared for sending manual notifications from an RT action the following steps still have to be performed in the C++ code:
- call registerManualNotification("NameOfThePropertyWithoutNamespace", pDev->getName()); within the device loop
- call sendManualNotification(pCtxt); after the loop for the devices to send all registered notifications
- call resetManualNotification(); after having sent the notifications
- How do I work with filter-items?
-
- If filter-items are defined in a setting- or acquisition property it is possible to evaulate the content within the execute-method of the get-/set-action:
const char* theFilter = filter.getAFilter();
if( strcmp(theFilter, "AString")==0 ) {
data.setAnItem1(true);
data.setAnItem2(true);
} else {
data.setAnItem1(false);
data.setAnItem2(false);
}
- How do I get the FESA class name / version in the C++ code?
std::string className = this->WRTimingTestServiceLocator_->getClassName();
std::string classVersion = this->WRTimingTestServiceLocator_->getClassVersion();
- How do I provide on-change functionality? I.e. send data only when it has notably changed?
- In the FESA class design: set the attribute 'on-change' to true in the property definition. This will indicate the intention to the applications.
- In the property implementation: adapt the default implementation of the method 'hasDataChanged'. Per default this method returns true which indicates a data change. If data changes within borders only are supposed to be published it is possible to implement this in the 'hasDataChanged' method.
FESA3 software @runtime
- I use custom actions. Why does the data not look as expected?
- As soon as a property steered by a custom action makes use of referenced data fields the default action is called after the execution of the custom action to fill the remaining data fields. To prevent execution of the default action no value-item of the property may use references to data fields.
SVN Repository Usage
- I just marked a file to be ignored by SVN. However now I cannot commit the folder where the file to be ignored is inside.
- Trigger a SVN update of the folder in the Project Explorer. After that you will be able to commit the SVN ignore info of the folder.
- My FESA project was inserted into the SVN repository automatically during creation. But I am not able to synchronize the project with the SVN repository.
Plug-Ins in Eclipse
- How do I uninstall the FESA3 Eclipse plug-in?
- Select from the menu Help > Install New Software... . This displays the Available Software dialog.
- Click the blue hyperlink "What is already installed" in the bottom section of the Available Software dialog.
- From the Installed Software tab select the FESA Eclipse plug-in and press the Uninstall... button.
- Follow the required steps of the uninstall procedure and restart Eclipse as suggested.
FESA Explorer
- How can I use the FESA Explorer without Eclipse?
In both cases load the zip file manually in the FESA Explorer. Either directly from the
FECs test directory or (if available) from
https://websvcdev.acc.gsi.de/groups/fesa/fex/ .
FESA3 Workflow
- How do I work with the FESA3 database?
General
- How do I enable icons in menus in Eclipse?
- This is related to the general Linux settings. To enable the icons type the following in a terminal:
x@asl73x> gconftool-2 --type boolean --set /desktop/gnome/interface/buttons_have_icons true
x@asl73x> gconftool-2 --type boolean --set /desktop/gnome/interface/menus_have_icons true
Deployment to MCS
- How do I deliver FESA software for the MCS in Saclay, France?