Importing files¶
Especially for systems already in production, a common scenario is to have most displays - or even all of them - already developed using the same tool. As much as one would want to have them ported to a web-native application, redrawing everything in another tool can be very time-consuming task.
For that reason, WEISS provides methods to facilitate the import of existing displays from other tools, reducing the manual effort required to recreate them in a web-native environment.
Warning
An imported display should be treated as a starting point to save time and effort. Always test it
with the intended IOC and review the complete display before making it available to operators.
For now, WEISS supports importing displays from CS-Studio/Phoebus only. Other tools will be
considered in future updates.
From CS-Studio¶
WEISS currently supports importing Phoebus Display Builder files (.bob), the display format used
by modern CS-Studio installations. The importer converts the display into WEISS widgets so you can
continue editing it in the browser or use it right away.
Make sure you have things ready¶
Open the displays you want to import in CS-Studio/Phoebus and check that they work as expected.
The extension accepted is a .bob file only, so check that they are also saved on this format.
Be sure to have all image files or embedded displays used by your OPI at hand, as they will also need to be uploaded or imported.

Import the display(s)¶
With the WEISS app running, login as a “Developer” and select the destination folder in the project
tree (or a file inside it). Click Import in the application header and select From
CSS/Phoebus. In the dialog, drop .bob files or whole folders, or use Select files / Select
folder. Folders are imported recursively and keep their structure.
Each foo.bob is converted and saved as foo.opi.json in the destination folder; there is no need
to create the files beforehand. Files that already exist are skipped unless Overwrite is
checked. When a single display is imported, it opens in the editor.

Pictures (.svg, .png, .jpg, .jpeg) found in imported folders are uploaded along with the
displays, at the same relative paths. Pictures elsewhere can be selected or dropped in the same
dialog, or uploaded later to the repository. Make sure the paths used by the imported Image
widgets match the paths of the uploaded files. Paths to embedded displays are converted from .bob
to .opi.json.
Important
Not all Phoebus widgets and features are supported. The unsupported widgets will be substituted by a dashed outline as placeholder, and a warning will be shown. Check next section for details on supported widgets and features.
Review the conversion¶
The goal of this tool is to reduce the manual effort required to recreate already existent displays, but does not eliminate the need for checking and validating your OPI in WEISS. Manual adjustments may be needed, especially for more complex widgets or rules.
The current widget support is:
Phoebus type |
WEISS widget |
Status |
|---|---|---|
|
|
✅ |
|
|
✅ |
|
|
✅ |
|
|
✅ map based on action type |
|
|
✅ |
|
|
✅ |
|
|
✅ |
|
|
✅ |
|
|
✅ |
|
|
✅ |
|
|
✅ |
|
|
✅ |
|
|
✅ |
|
|
✅ |
|
|
✅ |
|
|
✅ |
|
|
✅ |
|
|
✅ per-tab colors not supported |
|
|
✅ |
|
|
✅ |
|
|
✅ see notes below |
|
— |
🔶 not implemented |
|
— |
🔶 not implemented |
|
— |
🔶 not implemented |
|
— |
🔶 not implemented |
|
— |
🔶 not implemented |
|
— |
🔶 not implemented |
|
— |
🔶 not implemented |
|
— |
🔶 not implemented |
|
— |
🔶 not implemented |
|
— |
🔶 not implemented |
|
— |
🔶 not implemented |
|
— |
🔶 not implemented |
|
— |
🔶 not implemented |
|
— |
🔶 not implemented |
|
— |
🔶 not implemented |
|
— |
❌ not planned |
|
— |
❌ not planned |
|
— |
❌ not planned |
|
— |
❌ not planned |
|
— |
❌ not planned |
|
— |
❌ not planned |
|
— |
❌ not planned |
|
— |
❌ not planned |
Other conversion details:
Phoebus formula PVs (names starting with
=, e.g.=timestamp(...)) are not supported and are removed, with a warning.Local and simulated PVs (
loc://,sim://) are kept but not supported, and a warning is shown.imagewidgets keep their PV, colormap, colorbar visibility and intensity limits. ColormapsMAGMAandJETbecomeinfernoandturbo; other colormaps use the default. A fixed image size (data_width/data_height) is not imported: for plain waveform PVs, set the Size X/Y PV properties of theAreaDetectorwidget.
Rules and scripts are currently not implemented for the imported displays and need to be added manually using the WEISS interface.
Test, commit, and deploy¶
After checking PV names and macros, switch to Runtime mode and verify that the imported widgets connect to their PVs and the display behaves as expected.
When the OPI is ready, you can then commit and deploy it using the workflow described in the first web OPI tutorial.