Page 1 of 1
How do read DTO pakct?
Posted: Fri 8. Feb 2019, 16:36
by bukkun
I'm developing a monitoring XCP-DAQ application-spftware use PEAK-CAN-USB and PCAN-XCP APIs on Windows.
Call SetDAQListPointer() to StartStopSynchronizedDAQList().
The slave node start to output DTO frames.
After, How do read DTO pakct?
When use CAN_Read() API, any part of DTO frames were thined outs.
When use XCP_DequeuePacket() API, error return XCP_ERR_QUEUE_EMPTY.
Please let me konw rightly method of to read DTO pakct.
Re: How do read DTO pakct?
Posted: Fri 8. Feb 2019, 16:53
by K.Wagner
Hello,
first of all makes sure that you are using the last version, Version 2.2.1 from 2018-12-13, since older version had a problem receiving DTOs.
Note that you have to use the XCP_TransportLayerCommand so that dedicated DTOs can be included in the receiving filter. After this, dedicated DTOs can be read over the function XCP_DequeuePacket.
Here an extract of the help (TransportLayerCommand)

- TransportLayerCommand.PNG (19.28 KiB) Viewed 5259 times
Re: How do read DTO pakct?
Posted: Mon 11. Feb 2019, 08:01
by bukkun
Hi.
Tahnk you for your advice.
I add a statement of calling XCP_TransportLayerCommand() to after SET_DAQ_LIST_MODE.
(subcommand:SET_DAQ_ID, slave Response:0xFF, Block(with wait) mode).
I download newist DLLs form your web-site.
I tried to use PXCP.dll ver. 2.2.1.33. (with PCANBasic.dll 4.3.2.161 and the driver 4.1.4.262)
However XCP_DequeuePack() is returend XCP_ERR_QUEU_EMPTY yet.
What do you think other cause?
Re: How do read DTO pakct?
Posted: Mon 11. Feb 2019, 08:27
by bukkun
I found that when packetBufferLength of XCP_DequeuPacket() is smaller then 8, return error.
The packetBufferLength is equal 8, I can read DTOs from XCP_DequeuPacket().
Thank you for your good support.