homepage

This issue tracker has been migrated to GitHub , and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: Sockets support for CAN_BCM
Type: enhancement Stage: resolved
Components: Library (Lib) Versions: Python 3.4
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: Nosy List: Thorney, neologix, pitrou, python-dev, tshepang
Priority: normal Keywords: patch

Created on 2012年07月15日 13:10 by Thorney, last changed 2022年04月11日 14:57 by admin. This issue is now closed.

Files
File name Uploaded Description Edit
python_bcm.patch Thorney, 2012年07月15日 13:10 Diff against 78110:ba264b26d8d9 review
bcm2.patch Thorney, 2013年01月16日 02:49 Diff against 81536:3fa3e7975724 review
bcm3.patch Thorney, 2013年01月17日 06:03 review
bcm4.patch Thorney, 2013年01月23日 04:24 Diff against 81667:9a0cd5363c2a review
Messages (9)
msg165527 - (view) Author: Brian Thorne (Thorney) Date: 2012年07月15日 13:10
In addition to CAN_RAW introduced in Python 3.3, it would be really useful to expose the CAN_BCM protocol. Effectively it hands off as much to the kernel as possible which gives Python programs the ability to send and receive many periodic messages with little additional jitter or overhead.
I've attached an early stab at a patch to see if there is interest.
I'll be putting more examples of using BCM sockets at https://bitbucket.org/hardbyte/python-socket-examples 
msg165564 - (view) Author: Brian Thorne (Thorney) Date: 2012年07月16日 02:25
Once I've got more complete examples, I can update the patch to include a testcase.
msg179030 - (view) Author: Charles-François Natali (neologix) * (Python committer) Date: 2013年01月04日 14:36
Brian, could you add tests to Lib/test/test_socket.py (look for CANTest, you should be able to complete them).
msg180070 - (view) Author: Brian Thorne (Thorney) Date: 2013年01月16日 02:49
I've added a single BCM test. Any feedback on it would be good and then I'll add more complex ones.
Should the documentation be updated in this patch as well?
msg180118 - (view) Author: Brian Thorne (Thorney) Date: 2013年01月17日 06:03
Thanks for the review Charles-François.
I can't make your suggested bcm_msg_fmt work - it was deadlocking on my machine!
msg180444 - (view) Author: Brian Thorne (Thorney) Date: 2013年01月23日 04:24
I've added (some) docs and added checking of the BCM constants to the test_socket module.
I would guess that checking each broadcast manager function provided by the kernel isn't required?
msg180671 - (view) Author: Charles-François Natali (neologix) * (Python committer) Date: 2013年01月26日 14:11
> I've added (some) docs and added checking of the BCM constants to the test_socket module.
This version looks good to me.
I'll commit it next week (I currently don't have access to my
development machine).
> I would guess that checking each broadcast manager function provided by the kernel isn't required?
No, the goal is not to test the kernel implementation. That should be
enough for now.
msg181466 - (view) Author: Roundup Robot (python-dev) (Python triager) Date: 2013年02月05日 18:42
New changeset f714af60508d by Charles-François Natali in branch 'default':
Issue #15359: Add CAN_BCM protocol support to the socket module. Patch by Brian
http://hg.python.org/cpython/rev/f714af60508d 
msg181472 - (view) Author: Charles-François Natali (neologix) * (Python committer) Date: 2013年02月05日 19:38
Committed.
Brian, thanks for the patch!
History
Date User Action Args
2022年04月11日 14:57:32adminsetgithub: 59564
2013年02月05日 19:38:42neologixsetstatus: open -> closed
resolution: fixed
messages: + msg181472

stage: resolved
2013年02月05日 18:42:59python-devsetnosy: + python-dev
messages: + msg181466
2013年01月26日 14:11:31neologixsetmessages: + msg180671
2013年01月23日 04:25:00Thorneysetfiles: + bcm4.patch

messages: + msg180444
2013年01月17日 06:03:23Thorneysetfiles: + bcm3.patch

messages: + msg180118
2013年01月16日 02:49:53Thorneysetfiles: + bcm2.patch

messages: + msg180070
2013年01月04日 14:36:22neologixsetmessages: + msg179030
2012年07月20日 16:23:13tshepangsetnosy: + tshepang
2012年07月16日 02:25:35Thorneysetmessages: + msg165564
2012年07月15日 13:18:03pitrousetnosy: + neologix
2012年07月15日 13:10:55Thorneycreate

AltStyle によって変換されたページ (->オリジナル) /