Page 1 of 1

PCAN-USB to PCAN-USB communication

Posted: Thu 22. Sep 2016, 11:43
by kpenov16
I am new to CAN and I am experimenting with 2 of your PCAN-USB interfaces. I have connected them with twisted pair wire, terminated with a resistor on the one end.

I open twice PCAN-View and I can send messages from one of them and receive the messages on the other side, in the second PCAN-View. So I guess everything is working fine so far.

I would like to do the same in code with C#.

I hope my questions make sense :) :

Can I use UDSApi.Initialize to initialize each of them in a different projects and use UDSApi.Write on one of them to send a message and UDSApi.Read on the other to read the message, as described in PCAN-UPS user guide? (my question is if this is the right way of thinking or I need some kind of server to handle the messages, as I am learning now I need the simplest possible setup)

From the PCAN-UPS user guide I can see that the assumption is "mapping were configured", but I can't find info about mapping in PCAN-UPS user guide. I find info about mapping in PCAN-ISO-TP user guide, the CanTpApi.AddMapping method, am I supposed to use the PCAN-ISO-TP for the mapping in PCAN-UPS ? (I know that they kind of build up on each other, but I am not sure)

And the last thing is the message itself, is there a way to see an example of how the data is filled to the message in request.DATA = new byte[4095]; ?

It is my first post here so if I did something wrong with your rules please let me know.

EDIT: I have fixed everything, no need to answer.

Re: PCAN-USB to PCAN-USB communication

Posted: Mon 26. Sep 2016, 08:50
by PEAK-Support
closed