softwareschneiderei / hula Goto Github PK
View Code? Open in Web Editor NEWA new and tiki code generator for tango-controls device servers
A new and tiki code generator for tango-controls device servers
Currently only reading images via attributes is supported
An attribute definition like
[[attributes]]
name = "ExperimentUUID"
type = "bool"
results in the member function deklaration
virtual bool read_experiment_u_u_i_d() = 0;
in the hula generated base class. The following declaration would be more correct and much better to read:
virtual bool read_experiment_uuid() = 0;
Tango supports the notion of device properties that have to be defined in the database. Hula should support making properties mandatory, too.
Many Tango Clients display and rely on the device state for their communication. They should always be generated and maybe get a default implementation like returning UNKNOWN as state if nothing else is implemented by the developer.
Tango-documentation features of attributes and commands should be supported.
Need int16, int64, uint16, uint32, uint64 - possibly also 8-bit types (for images?)
Consider reserved names for C++ (continue, break, etc) and tango (Init, State, Status)
E.g. when naming commands "continue" - error out or change the name slightly?
We have some devices requiring two dimensional data for flags and measurement values in contrast to classical picture data.
A build with conan 2 gives the following error:
ERROR: /tango-ads-bridge/hula:
ConfigParser: Unrecognized field 'build_requires'
In addition the dependency cppTango also does not build with conan 2...
Recipe 'cpptango/9.3.3@softwareschneiderei/stable' seems broken.
It is possible that this recipe is not Conan 2.0 ready
If the recipe comes from ConanCenter check: https://conan.io/cci-v2.html
If it is your recipe, check if it is updated to 2.0
ERROR: Package 'cpptango/9.3.3@softwareschneiderei/stable' not resolved: cpptango/9.3.3@softwareschneiderei/stable: Cannot load recipe.
Error loading conanfile at '/root/.conan2/p/cppta8c4692633816f/e/conanfile.py': Unable to load conanfile in /root/.conan2/p/cppta8c4692633816f/e/conanfile.py
File "", line 790, in exec_module
File "", line 228, in _call_with_frames_removed
File "/root/.conan2/p/cppta8c4692633816f/e/conanfile.py", line 4, in
ImportError: cannot import name 'ConanFile' from 'conans' (/usr/local/lib/python3.9/dist-packages/conans/init.py)
Array command parameter-/return-type:
parameter_type = "string[]"
return_type = "float[]"
Will use use std::vector<std::string>
and std::vector<float>
Spectrum attribute:
type = "int[1024]"
Will use std::vector<int>
, max size 1024
Image attribute:
type = "double[800,600]"
Will use std::vector<double>
, max size 800x600 (hence the vector can have up to 800*600 elements)
You have to define at least one attribute and at least one command. In the wild there may be some devices without the need of one or the other.
Especially in development there is the realistic possibility to start without (user defined) commands for example.
When the sections for attributes/commands are missing following errors are reported:
[error] key "commands" not found in the top-level table
--> master.toml
|
1 | name = "Master"
| ^--- the top-level table starts here
[error] key "attributes" not found in the top-level table
--> master.toml
|
1 | name = "Master"
| ^--- the top-level table starts here
If you specify a mandatory section but leave it empty following error is displayed:
[error] key "name" not found
--> master.toml
|
15 | [[attributes]]
| ~~~~~~~~~~~~~~ in this table
I have a device with attributes like
[[attributes]]
name = "Master1Alive"
type = bool
[[attributes]]
name = "Master2Alive"
type = bool
Current hula generates these functions out of the attribute definition:
virtual bool read_master_alive() = 0;
virtual bool read_master_alive() = 0;
Obviously that does not work due to duplicate declarations because the number is lost.
Tango has support for multiple device classes in one server. It requires a bit of manual work and changes to generated code to build a device server with more than one hula generated device class.
This should become easier.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.