-
Hello, I'm doing some tests to familiarize myself with pythonSoftIOC. In one of my tests, I wanted to modify "RVAL" of an AI record in order to use "ASLO" for value conversion. Unfortunately, I get an error. Is it possible to do this with pythonSoftIOC? Xavier Error return:
My code :
|
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 4 replies
-
There are a couple of issues here. First of all, all channel access writes to In records are automatically disabled by pythonSoftIOC (by setting Secondly, softIOC device ai/ao records do not use If you really want ai/ao records with value conversion support you can always use |
Beta Was this translation helpful? Give feedback.
-
Hello, Thank you for your explanation. I suspected that it was not possible, but I wanted a confirmation. Since the conversion worked with an ao, I was wondering if it could also work with an ai. Therefore, it's better to implement a conversion in Python functions rather than through the underlying IOC. I will keep this in mind when designing my programs. I wish you a happy holiday season. Xavier |
Beta Was this translation helpful? Give feedback.
Ah yes, I understand why you get the result you want with AO but not with AI. But ... don't do that, please!
PythonSoftIOC deliberately does not do conversions and takes care to bypass any conversions built into the record type: an AI or AO is the true floating point value that you are reading or writing to that record. Personally I feel that record level programming in EPICS is archaic!
If you want to do conversion for hardware IO, I think you have two choices: