Title: PDOMapping in EDS file does not check for ValueError Exception · Issue #385 · canopen-python/canopen · GitHub
Open Graph Title: PDOMapping in EDS file does not check for ValueError Exception · Issue #385 · canopen-python/canopen
X Title: PDOMapping in EDS file does not check for ValueError Exception · Issue #385 · canopen-python/canopen
Description: I've just encountered some EDS files that have the PDOMapping value with no value after the = sign e.g. [3020sub0] ParameterName=Number of entries ObjectType=0x07 DataType=0x0005 AccessType=ro DefaultValue=0x9 PDOMapping= when I try to l...
Open Graph Description: I've just encountered some EDS files that have the PDOMapping value with no value after the = sign e.g. [3020sub0] ParameterName=Number of entries ObjectType=0x07 DataType=0x0005 AccessType=ro Defa...
X Description: I've just encountered some EDS files that have the PDOMapping value with no value after the = sign e.g. [3020sub0] ParameterName=Number of entries ObjectType=0x07 DataType=0x0005 AccessType=ro ...
Opengraph URL: https://github.com/canopen-python/canopen/issues/385
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"PDOMapping in EDS file does not check for ValueError Exception","articleBody":"I've just encountered some EDS files that have the PDOMapping value with no value after the = sign e.g.\r\n\r\n```\r\n[3020sub0]\r\nParameterName=Number of entries\r\nObjectType=0x07\r\nDataType=0x0005\r\nAccessType=ro\r\nDefaultValue=0x9\r\nPDOMapping=\r\n```\r\nwhen I try to load the file it throws the error:\r\n```\r\nValueError: invalid literal for int() with base 0: ''\r\n```\r\n\r\nAt first I though the EDS file had been corrupted or generated incorrectly( it states it was made with CANopen Design Tool 2.2.34). \r\n\r\nAlso it only seems to happen on SubIndex 0.\r\n\r\nI double checked the spec CiA 306 version 1.3.0 and noticed this about arrays:\r\n\r\n\u003e the entry PDOMapping for all sub-indexes except 0 and 255 is given by the entry PDOMapping of the main object. sub-index 0 is assumed not to be mappable\r\n\r\nso that's why I'm guessing the tool though it was ok to leave it blank. \r\n\r\nI saw that the library handled the same situation for other values (DefaultValue seem to have the same issue a lot) , so I'' create a pull request to handle it in the same way for PDOMapping.\r\n\r\n","author":{"url":"https://github.com/Obsnold","@type":"Person","name":"Obsnold"},"datePublished":"2023-07-07T20:56:52.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":0},"url":"https://github.com/385/canopen/issues/385"}
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:79374816-bf01-6bb1-d8e7-aa87c17fbfa5 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | A5D4:1A68FF:6D98ACA:95AC82B:6A5E3740 |
| html-safe-nonce | 52291361edc320eef224ba83f0a924749560d6c4b5abfbe1e5368919ebe205db |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJBNUQ0OjFBNjhGRjo2RDk4QUNBOjk1QUM4MkI6NkE1RTM3NDAiLCJ2aXNpdG9yX2lkIjoiMjMzMjQzNDUzMjIxMjI5MTM5MiIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | ec1e695d9e54fc595fe4e4ec0d100ae07d62053b1a6e799490c68283d06d95ad |
| hovercard-subject-tag | issue:1794317895 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/canopen-python/canopen/385/issue_layout |
| twitter:image | https://opengraph.githubassets.com/7090b84a242f49a71fbb26ed57bd09b5916e09032aaaca69cc5b521acd2bbb29/canopen-python/canopen/issues/385 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/7090b84a242f49a71fbb26ed57bd09b5916e09032aaaca69cc5b521acd2bbb29/canopen-python/canopen/issues/385 |
| og:image:alt | I've just encountered some EDS files that have the PDOMapping value with no value after the = sign e.g. [3020sub0] ParameterName=Number of entries ObjectType=0x07 DataType=0x0005 AccessType=ro Defa... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | Obsnold |
| hostname | github.com |
| expected-hostname | github.com |
| None | e4b946991e2bd4b122ac7bb3d405be22af15feed82daaafcd1fe0a1231d54061 |
| turbo-cache-control | no-preview |
| go-import | github.com/canopen-python/canopen git https://github.com/canopen-python/canopen.git |
| octolytics-dimension-user_id | 200581454 |
| octolytics-dimension-user_login | canopen-python |
| octolytics-dimension-repository_id | 68737600 |
| octolytics-dimension-repository_nwo | canopen-python/canopen |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 68737600 |
| octolytics-dimension-repository_network_root_nwo | canopen-python/canopen |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | a421a3a9fbeebe1ed5ba7c8e5b803b098d65a30e |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width