Closed edras closed 4 months ago
This issue is being addressed on the branch assigned. Functionality is implemented, it needs to be tested
accessing array variable, i.e., motorbench:
x2c_scope = X2CScope(...) variable = x2c_scope.get_variable("motor.estimator.zsmt.iqHistory") iqHistory = variable.get_value()
or you may use item functions for get and set iqHistory[0] # retrieve the first element iqHistory[-1] # retrieve the last element
iqHistory[0] = 9 # set the first element iqHistory[-1] = 10 # set the last element
It is not possible to access an array variable, i.e.:
C: uint16_t my_var[8];
it would be interesting to access this variable "my_var" through variable_factory in python
either by: my_var = [ ] my_var = variable_factory.get_variable_elf("my_var")
or
my_var0 = variable_factory.get_variable_elf("my_var[0]")