Comments (11)
Could you run xcphello.py with -l DEBUG
option and post the trace or at least confirm that you are using MAX_DLC_REQUIRED=true
option?
Looks much like padded CAN frames -- shortUpload
currently just returns the raw response, which would be an explanation for this behaviour, even correct if address granularity == 1 ...
But anyways, I'll fix it.
from pyxcp.
probably fixed by latest commit
from pyxcp.
This is my other GitHub account. I will try it out tomorrow. Thank you very much
from pyxcp.
Hi!
The above issues have been resolved.Thank you very much.But when I read two bytes of data, the following error is displayed.
from pyxcp.
Note regarding UPLOAD
and SHORT_UPLOAD
:
Parameter length
requests a number of elements NOT bytes!
That is length multiplied by address granularity (1, 2, or 4 bytes); you get this information by inspecting/printing slaveProperties, as you did in your first screenshot (unfortunately AG isn't visible...).
An AG of 4 would fit in the picture:
- maxCto is 8 bytes (obviously CAN classic).
- max. payload is maxCto minus one byte result code (0xff) ==> 7 bytes.
- 2 elements ==> 8 bytes, one off, ERR_OUT_OF_RANGE.
from pyxcp.
One thing I forgot to mention:
the addressGranularity
member of slaveProperties
is more or less decorative in the first place;
since the last commit there's a new property bytesPerElement
which could directly used in calculations.
from pyxcp.
Also new: Warning if max. SHORT_UPLOAD
maxload is exceeded.
from pyxcp.
Thank you very much.
When a connection request is executed, slave replies with the following packets 'FF 05 41 08 00 08 01 01'. So I think AG is equal to 1.
from pyxcp.
Hmm, really strange.
You may try some tests:
ADDR=0x20003bfc
# Should work, if there is no access protection in this range.
for addr in range(ADDR-4, ADDR+4):
x.shortUpload(1, addr, 0)
# same, with two elements/bytes.
for addr in range(ADDR-4, ADDR+4):
x.shortUpload(2, addr, 0)
# you should also test other known-good addresses from your A2L.
x.setMta(ADDR-8, 0)
data = x.fetch(16) # calls UPLOAD not SHORT_UPLOAD under the hood.
from pyxcp.
OK.Thank you very much
from pyxcp.
Hi!
I tried the following.The response of the slave is correct, but the terminal does not print a response.
from pyxcp.
Related Issues (20)
- python can filter is not correct HOT 7
- XcpResponseError [ERR_ACCESS_LOCKED] - Seed and Key unlock process error HOT 6
- No more queues! HOT 1
- How to collect and save the XCP data ? HOT 15
- REINIT_DAQ HOT 7
- [Question] Retrieve timestamp from frame HOT 1
- How to get daq data?
- Help HOT 2
- ERR_CMD_UNKNOWN HOT 1
- Python 3.12 wheels HOT 2
- XCP-Download command problem HOT 13
- ERROR:pyxcp.errorhandler:XcpTimeoutError [Response timed out [block_receive].] HOT 7
- How to get DAQ data. HOT 3
- CAN-FD transport MAX_DLC_REQUIRED HOT 4
- Concurrent pyxcp method calls with asyncio HOT 1
- About DAQ data HOT 2
- pyxcp build error with pip in ubuntu HOT 2
- Cannot build pyxcp with python3.12 on ubuntu 24.04 HOT 6
- Memory growth issue while using daq mode HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pyxcp.