BNMR: Custom pages: Difference between revisions
en>Suz mNo edit summary |
m (9 revisions imported) |
(No difference)
|
Revision as of 12:14, 25 April 2022
Links
Purpose
BNMR Custom pages are written specifically for the bnmr and bnqr experiments to enable to users to enter parameters and control the experiments more easily.
Introduction
MIDAS experiments run the web server [mhttpd] which allows users to control and communicate with their experiments using a standard web browser (e.g. Firefox).
Complicated experiments such as bnmr and bnqr involve a large number of ODB parameters in various directories that have to be setup in order to control the experiment. Navigating these parameters using the standard MIDAS ODB page can become complicated and time-consuming. For this reason, custom pages specific to an experiment are often written to present relevant parameters for the experiment in a more user-friendly way, and to display information specific to that experiment.
Custom pages for bnmr/bnqr
All MIDAS Custom Pages written for the bnmr and bnqr experiments are written in HTML and Javascript. They include the MIDAS Javascript library (mhttpd.js) and use the MIDAS asynchronous functions to access the ODB. Most custom pages also include the MIDAS stylesheet.
The custom pages written for the bnmr and bnqr experiments include:
- Custom Status page - replaces the MIDAS standard status page
- Parameters page - displays the parameters for the selected PPG Mode, Tunes, PSM Module setup.
- Compare Tunes page - enables users to compare two tunes
- PPG Mode 2e Graphical page - displays parameters for PPG Mode 2e graphically
- PPG Mode 20 Setup page - prevents users from entering invalid values for the Beam and RF parameters in PPG Mode 20
Define in /Custom ODB tree
In order for mhttpd to display custom pages, custom page files must be defined in the experiment's /Custom ODB tree. This includes external stylesheets, html and javascript code. Any images with superimposed labels must be listed in /Custom/Images subtree. The difference in appearance of the custom pages for bnmr and bnqr is handled by the stylesheets bnmr.css and bnqr.css respectively. All other files are identical for both experiments.
See keys in /Custom tree for more information.
Custom Page code
All custom page code is located in directory ~bn[mq]r/online/custom (see Nomenclature).
The following table lists the source filenames for the custom pages :
Custom Page | HTML | Javascript | Stylesheet | Image |
---|---|---|---|---|
Custom Status | Custom_Status.html | cs_functions.js | common.css, bn[mq]r.css * | |
Parameters | parameters.html | parameter_functions.js, params_common.js, parameters_tunes.js, tunes_descriptions.js |
mhttpd.css, common.css, bn[mq]r.css | |
Compare Tunes | compare_tunes.html | params_common.js, tune_descriptions.js, tunes_descriptions.js | common.css, bn[mq]r.css | |
Mode 2e graphical | enter_2e_params.html | common.css, bn[mq]r.css | 2e_params.gif
| |
Mode 20 setup | slider20.html ** | common.css, bn[mq]r.css |
- ** This page requires the standard jquery, nouislider, wnumb libraries.