You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
See error: TypeError: in method 'TemplateCharMsgPayload_dataVector_set', argument 2 of type 'unsigned char [3]'
Expected behavior
Script should be able to set dataVector array without error.
System Info
OS: Ubuntu
Version: 22.04.5 LTS
Python version: 3.10.12
Additional context
This appears to be an extension of this issue that was resolved with this pull request; however, support for uint8_t and unsigned char were not added. By adding the following lines to basilisk/src/architecture/_GeneralModuleFiles/swig_conly_data.i in their respective ARRAYASLIST and ARRAY2ASLIST locations, the issue appears to be resolved on my local machine:
Describe the bug
SWIG wrapper does not support arrays of type uint8_t and unsigned char
To reproduce
Expected behavior
Script should be able to set dataVector array without error.
System Info
Additional context
This appears to be an extension of this issue that was resolved with this pull request; however, support for uint8_t and unsigned char were not added. By adding the following lines to
basilisk/src/architecture/_GeneralModuleFiles/swig_conly_data.i
in their respective ARRAYASLIST and ARRAY2ASLIST locations, the issue appears to be resolved on my local machine:ARRAYASLIST(uint8_t, PyLong_FromUnsignedLong, PyLong_AsUnsignedLong)
ARRAYASLIST(unsigned char, PyLong_FromUnsignedLong, PyLong_AsUnsignedLong)
ARRAY2ASLIST(uint8_t, PyLong_FromUnsignedLong, PyLong_AsUnsignedLong)
ARRAY2ASLIST(unsigned char, PyLong_FromUnsignedLong, PyLong_AsUnsignedLong)
Example script:
The text was updated successfully, but these errors were encountered: