Hi,
I’m exploring the concept of Dynamic Attribute. I’m able to successfully create and use attributes dynamically of type Double, Float, String, etc. But if I try to dynamically create an attribute of type “DevEnum” I get following error:
ERROR 2015-09-09 20:10:27,699 [RequestProcessor-5 - td/1/1] org.tango.utils.DevFailedUtils.throwDevFailed:37 - org.tango.testdynamic.DynamicEnumAttrEnum cannot be an attribute
ERROR 2015-09-09 20:10:27,706 [RequestProcessor-5 - td/1/1] org.tango.utils.DevFailedUtils.throwDevFailed:38 -
fr.esrf.Tango.DevFailed: IDL:Tango/DevFailed:1.0
at org.tango.utils.DevFailedUtils.throwDevFailed(DevFailedUtils.java:36) ~[JTango-9.0.3.jar:na]
at org.tango.server.attribute.AttributeValue.setValue(AttributeValue.java:118) [JTango-9.0.3.jar:na]
at org.tango.server.attribute.AttributeValue.<init>(AttributeValue.java:61) [JTango-9.0.3.jar:na]
at org.tango.testdynamic.DynamicEnumAttr.getValue(DynamicEnumAttr.java:128) [TestDynamic/:na]
at org.tango.server.attribute.AttributeImpl.updateValue(AttributeImpl.java:187) [JTango-9.0.3.jar:na]
at org.tango.server.servant.DeviceImpl.checkAlarms(DeviceImpl.java:2350) [JTango-9.0.3.jar:na]
at org.tango.server.servant.DeviceImpl.getState(DeviceImpl.java:2332) [JTango-9.0.3.jar:na]
at org.tango.server.servant.DeviceImpl.executeStateCmd(DeviceImpl.java:423) [JTango-9.0.3.jar:na]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_31]
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[na:1.8.0_31]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_31]
at java.lang.reflect.Method.invoke(Method.java:483) ~[na:1.8.0_31]
at org.tango.server.command.ReflectCommandBehavior.execute(ReflectCommandBehavior.java:66) [JTango-9.0.3.jar:na]
at org.tango.server.command.CommandImpl.execute(CommandImpl.java:90) [JTango-9.0.3.jar:na]
at org.tango.server.servant.DeviceImpl.commandHandler(DeviceImpl.java:1730) [JTango-9.0.3.jar:na]
at org.tango.server.servant.DeviceImpl.command_inout_4(DeviceImpl.java:1609) [JTango-9.0.3.jar:na]
at fr.esrf.Tango.Device_5POA._invoke(Device_5POA.java:229) [JTango-9.0.3.jar:na]
at org.jacorb.poa.RequestProcessor.invokeOperation(RequestProcessor.java:350) [JTango-9.0.3.jar:na]
at org.jacorb.poa.RequestProcessor.process(RequestProcessor.java:672) [JTango-9.0.3.jar:na]
at org.jacorb.poa.RequestProcessor.run(RequestProcessor.java:830) [JTango-9.0.3.jar:na]
I know that the TANGO 9 is not yet officially released and the Enum datatype is a feature of TANGO 9. I just want to know if the error is because of the incorrect code or the feature of Dynamic Attribute with Enum Datatype is not yet implemented.
I have attached the device server code.
I’m using the JTango-9.0.3 jar file. I generate the code using the Pogo-9.1.2a which has the feature of using Enumeration as TANGO Deta types.