Hi all,
I'm first time user of the PLIN USB LIN interface and I'm trying to do a simple communication with my product. (I have worked with NI-XNET in the past but it was some time ago) I have some general knowledge on LIN but I'm strugling to get the communication working with the API DLL. I first tried the comunication from the PLIN View PRO and it is working without an issue the steps what I took there:
1. Load the LDF file with the Open function.
2. Set up the node as Master
3. Created a new Schedule
4. Configured the Schedule as Not Repeating
5. Added a new Entry
6. Configured the ID 11h and set the Delay to 10
7. Connected to the HW as Master with 19200baud rate
8. Started the Schedule and I receive response from my target device correctly.
Unfortunately I'm not able to reproduce a similiar behaviur with the API. These are the steps I triy to follow from my code:
LIN - Register Client
LIN_ConnectClient
LIN_InitializeHardware
LIN_SetClientFilter(0xFFFFFFFFFFFFFFFF)
LIN_SetFrameEntry(FrameID: 17, Length 2, Direction Subscriber(2), ChecksumType Enhanced(2), Flags IgnoreInitial(2), InitialData 1D 8Elemetn Array with zeros)
The Set Frame Entry returns error code 4 which is invalid checksum, I do not get what is the issue. I have the exact same seetings in the PLIN Viewer Pro and there it is not a problem.
Thank you for your help in advance.
PLIN - Simple API Example
Re: PLIN - Simple API Example
Hi,
unfortunately with the given code snipped, we are not able to help (many details are not visible). Please have a look in the PLIN API manual, which will show you how to use the API for the different applications:
https://www.peak-system.com/produktcd/D ... PI_enu.pdf
Please also have a look in the code samples we provide with the PLIN-API for more details.
regards
Michael
unfortunately with the given code snipped, we are not able to help (many details are not visible). Please have a look in the PLIN API manual, which will show you how to use the API for the different applications:
https://www.peak-system.com/produktcd/D ... PI_enu.pdf
Please also have a look in the code samples we provide with the PLIN-API for more details.
regards
Michael
Re: PLIN - Simple API Example
Hi Michael,
Thank you for getting back to me, I read the manual extensively and I have checked the example codes many times but these did not help me.
What do you need from me for further assistance?
You mentioned:
Please give me more detailed description on the information what you need from me!
Thanks
Ambrus
Thank you for getting back to me, I read the manual extensively and I have checked the example codes many times but these did not help me.
What do you need from me for further assistance?
You mentioned:
What do you mean by this? I provided the functions which I ues in the order how I exeecute them I also wrote the paramters what I use wheer it is necessarry.unfortunately with the given code snipped, we are not able to help (many details are not visible)
Please give me more detailed description on the information what you need from me!
Thanks
Ambrus
Re: PLIN - Simple API Example
Hi,
we need the full code to be able to help your with your API problem. Looks like you also sent an email to our support email address, so we will go on by email.
regards
Michael
we need the full code to be able to help your with your API problem. Looks like you also sent an email to our support email address, so we will go on by email.
regards
Michael