Closed donvicario closed 8 years ago
Hi, which version of mdf file are you trying to read ? in mdfreader.py, there is a function called _convertMatlabName. It should remove problematic characters and could be reused in the code to solve your issue, for instance in mdf.py add_channel() method.
Do you still have this issue ? Critical ? As no answer for a while, I close this issue, feel free to reopen it.
Hi, I have the same issue reading a MDF 3.00 file right during the initialize phase
How exactly should I use the function _convertMatlabName? As I understand, I should modify your code and call _convertMatlabName from add_channel() method. Is it correct? Unfortunately I'm new to Python and don't know how to modify the code correctly, can you please show me how?
Thank you a lot in advance.
_convertMatlabName is an example of function that is cleaning name from not allowed characters., it can be introduced in the code to avoid this issue but this is dirty patch. ':' character is allowed for a dict key. But as I do not see where is this error in the code (your picture is not complete) and no complete information either from donvicario, I cannot troubleshot. Could you please send your snapshot again or inform the line number and in which file for the final error?
Thank you a lot for your fast reply and also sorry for my late. Here is the full trace:
Thanks for the update. It is more clear now. Actually, recarray uses python identifiers, which has not allowed characters. I implemented a new function in mdf.py module shared in all modules to declare only the recarray format. --> it should solve your issue, please try.
It worked! Thank you a lot!!!
Hello,
I want to read some MDF files with the mdfreader tool. My MDF files have some fields which are called "Dauermesung_1: Time", "Dauermessung_2: Time", etc. If I read these files with mdfreader.mdf() I get the error
ValueError: ':' is not an allowed character in buffer field names
Is there a chance to fix this?
Best regards, donvicario