From cba450a4e1a7d8ef5d6f9334bd874e819985be4c Mon Sep 17 00:00:00 2001 From: yunsik oh Date: Mon, 2 Sep 2024 10:09:56 +0900 Subject: [PATCH 1/3] fix can_id bit shift --- gateway/gateway.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gateway/gateway.py b/gateway/gateway.py index 86d3b3c..6df0b3d 100644 --- a/gateway/gateway.py +++ b/gateway/gateway.py @@ -157,7 +157,7 @@ def get_binary(self): def __get_canid(self): arbitration_id = self.can_id & 0x3FFFFFFF rtr = (1 << 29) if self.remote and not self.fd else 0 - extid = (2 << 29) if self.extend_id else 0 + extid = (1 << 30) if self.extend_id else 0 return arbitration_id | rtr | extid def __get_channel_idx(self): From 2de06b0a15b1bd0e39f746fd45d315eacc089598 Mon Sep 17 00:00:00 2001 From: yunsik oh Date: Mon, 2 Sep 2024 10:22:20 +0900 Subject: [PATCH 2/3] modified README.md - add details for gateway configurations --- README.md | 21 +++++++++++++-------- 1 file changed, 13 insertions(+), 8 deletions(-) diff --git a/README.md b/README.md index 56a716a..da2a0b8 100644 --- a/README.md +++ b/README.md @@ -17,25 +17,30 @@ Target Device : in [user manual](https://www.peak-system.com/produktcd/Pdf/English/PCAN-Ethernet-Gateway-FD-DR_UserMan_eng.pdf), custom gateway protocol is presented. -in Route Configuration Page, add Routing IP Addresses both side(CAN->Ethernet, Ethernet->CAN) +### Handshake Off +you must **disable handshake** for custom protocol integration. +- enter "Expert Mode" in admin page +- turn Handshake Checkbox off + +### Router Configuration +in Route Configuration Page, add Routing IP Addresses both side +- CAN->Ethernet +- Ethernet->CAN -
## Install Plugin Package +install from PyPI ```shell - -# install from PyPI $ pip3 install pcan-gatewaybus +``` -or - -# local installation +local installation +```shell $ git clone https://github.com/ys-oh/python-can-gatewaybus $ cd python-can-gatewaybus $ pip3 install . - ``` From 746823898b49e8d191601f3dd46a86cdb5153257 Mon Sep 17 00:00:00 2001 From: yunsik oh Date: Mon, 2 Sep 2024 10:31:24 +0900 Subject: [PATCH 3/3] update fetch version --- setup.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/setup.py b/setup.py index 3de1c1f..818b16c 100644 --- a/setup.py +++ b/setup.py @@ -7,7 +7,7 @@ setuptools.setup( name="pcan-gatewaybus", - version="0.0.2", + version="0.0.3", author="yunsik oh", author_email="oyster90@naver.com", description="pcan gatewaybus backend for \"python-can\"",