python-j1939 icon indicating copy to clipboard operation
python-j1939 copied to clipboard

compatibility with 11-bit CAN messaging

Open DaveP987 opened this issue 3 years ago • 1 comments

Hello Miller,

I'm on a project where I need to support simultaneous 11-bit and J1939 messaging. I've hacked this package a bit to make it work (it doesn't really take much) and thought I could make a contribution to provide that support.

The changes include:

  1. building J1939 filters on any specified can_filters,
  2. dispatching incoming non-PDU messages to a method that still ignores them but can be sub-classed for addition to the queue,
  3. dispatching outgoing non-PDU messages directly to self.can_bus.send

Another change I made was to put the construction of RawCanBus into a method so a sub-class can swap in a dummy bus for tests.

Dave

DaveP987 avatar Sep 01 '22 18:09 DaveP987

Hi Dave,

Put up a PR and if I don't see it break anything I'll accept it.

I'm glad you found the project useful; I was depending on it when it was deleted from hardbyte/python-can, that why I created the repo and have worked to make it functional..

It's great to see contributions so I'm not the sole maintainer.

Miller


From: Dave Paul @.> Sent: Thursday, September 1, 2022 11:37 AM To: milhead2/python-j1939 @.> Cc: Subscribed @.***> Subject: [milhead2/python-j1939] compatibility with 11-bit CAN messaging (Issue #18)

External Email Think Before You Click.

Hello Miller,

I'm on a project where I need to support simultaneous 11-bit and J1939 messaging. I've hacked this package a bit to make it work (it doesn't really take much) and thought I could make a contribution to provide that support.

The changes include:

  1. building J1939 filters on any specified can_filters,
  2. dispatching incoming non-PDU messages to a method that still ignores them but can be sub-classed for addition to the queue,
  3. dispatching outgoing non-PDU messages directly to self.can_bus.send

Another change I made was to put the construction of RawCanBus into a method so a sub-class can swap in a dummy bus for tests.

Dave

— Reply to this email directly, view it on GitHubhttps://nam10.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fmilhead2%2Fpython-j1939%2Fissues%2F18&data=05%7C01%7Cmiller.lowe%40polaris.com%7Ceaaabfeca36843eea6c608da8c4911cd%7C85f78c4cad11473596240b2c11611dff%7C0%7C0%7C637976542711622654%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=MWYEgUuiSM6oXz9l4oId5UwYEFC6k7S4e8eFmkyKUEM%3D&reserved=0, or unsubscribehttps://nam10.safelinks.protection.outlook.com/?url=https%3A%2F%2Fgithub.com%2Fnotifications%2Funsubscribe-auth%2FAEWRWU7G4MX73YD4BAND4O3V4DZXXANCNFSM6AAAAAAQCTWN3U&data=05%7C01%7Cmiller.lowe%40polaris.com%7Ceaaabfeca36843eea6c608da8c4911cd%7C85f78c4cad11473596240b2c11611dff%7C0%7C0%7C637976542711622654%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C3000%7C%7C%7C&sdata=drqG8X1HwEawk093f%2BPkD6PsbSE9hCBN1BjOOxyoRzg%3D&reserved=0. You are receiving this because you are subscribed to this thread.Message ID: @.***>

CONFIDENTIAL: The information contained in this email communication is confidential information intended only for the use of the addressee. Unauthorized use, disclosure or copying of this communication is strictly prohibited and may be unlawful. If you have received this communication in error, please notify us immediately by return email and destroy all copies of this communication, including all attachments.

milhead2 avatar Sep 01 '22 22:09 milhead2