The GaussianSlewLimited quantity class only generated simulation values that are python primitive types (float in this case) which are appropriate for attributes with a SCALAR data format.
This is a problem for the attrbiutes with more complex data formats, SPECTRUM/IMAGE. When reading an attribute, the quantity returns a primitive type which PyTango is not expecting, therefore resulting in the error, Wrong Python type for attribute... Expected a sequence. This change here allows us to cater for the complex data formats. The method next_val now generates the simulation data according to the data format, given by the meta dictionary.
[ ] Commented code, particularly in hard-to-understand areas?
[ ] Made corresponding changes to the documentation (e.g. Python documentation, System Engineering Documentation, version description updates, README file, etc)?
The
GaussianSlewLimited
quantity class only generated simulation values that are python primitive types (float in this case) which are appropriate for attributes with a SCALAR data format.This is a problem for the attrbiutes with more complex data formats,
SPECTRUM
/IMAGE
. When reading an attribute, the quantity returns a primitive type which PyTango is not expecting, therefore resulting in the error,Wrong Python type for attribute... Expected a sequence
. This change here allows us to cater for the complex data formats. The methodnext_val
now generates the simulation data according to the data format, given by themeta
dictionary.Resolves #157
Signed-off-by: Katleho Madisa katleho.madisa47@gmail.com
Screenshots or code snippets (if appropriate): N/A
Definition of Done Checklist
SKA-JIRA: 442