Error in node.pdo.save()
See original GitHub issueHello.
I got the error messages as below:
Traceback (most recent call last):
File "testing.py", line 55, in <module>
motor_node.tpdo.save()
File "/usr/local/lib/python3.7/site-packages/canopen/pdo/base.py", line 57, in save
pdo_map.save()
File "/usr/local/lib/python3.7/site-packages/canopen/pdo/base.py", line 334, in save
self.com_record[1].raw = self.cob_id | PDO_NOT_VALID
TypeError: unsupported operand type(s) for |: 'NoneType' and 'int'
with the codes like below:
node.tpdo[1].clear()
node.tpdo[1].add_variable('8 bit digital input block area', '1. digital input block')
node.tpdo[1].add_variable('8 bit digital input block area', '2. digital input block')
node.tpdo[1].enabled = True
node.tpdo.save()
I have checked some variables,
node.tpdo[1].cob_id
is None
,
and node.tpdo[1].predefined_cob_id
is 0x181
(my node id is 1
).
Did I misunderstand something or should something be improved? Thanks very much.
Issue Analytics
- State:
- Created 5 years ago
- Comments:10 (1 by maintainers)
Top Results From Across the Web
New node does not save, PDO exception in Workflow_node ...
Hi All, I have setup work flow module for my site, but when i add a new node ( that has only one...
Read more >Getting PDO Exception Error message when trying to save content ...
After editing content in About us page, when trying to save I get the following error message. PDOException: SQLSTATE[42S02]: Base table or view...
Read more >7 - PDOException Error upon saving node with computed field ...
I encountered a "PDOException: SQLSTATE[22001]" error which kept giving a blank white screen of death error. After some 2 hours or so, I...
Read more >mySQL PDO error - php - Stack Overflow
You have a comma between "stud" and "pass" in your insert statement - it should be. INSERT INTO my_tb (stud_user, stud_pass, ...
Read more >Why You Should Be Using PHP's PDO for Database Access
Data is obtained via the ->fetch() , a method of your statement handle. Before calling fetch, it's best to tell PDO how you'd...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Sorry for my late reply. I think we can assume this topic as closed.
Most devices have EDS files usually for the product version. But as a R&D engineer, I have to touch many under-developing devices which do NOT have any EDS files. Meanwhile, some device suppliers in China provide incorrect EDS files but correct manuals for CANopen dictionaries. Thus, we have to avoid any EDS files in our production codes.
That was why I would like to have this feature for some spike testing. If we have this feature in future, that would be great. If no, there are also OK since I have implemented a workaround solution. If I have time, I can try to contribute my codes to this repo.
Thanks very much for everyone.
Ok, you are welcome @zcchen to contribute. Keep hacking! xD