Send master request frame - problem

RS-232 to CAN/LIN Interface
Locked
Sternal87
Posts: 4
Joined: Wed 13. Mar 2013, 10:05

Send master request frame - problem

Post by Sternal87 » Wed 13. Mar 2013, 10:52

Hi,

At the moment i write an C# app to control lin slave using your hardware and I have problem with sending master request frame to slave. According to standard it should look in these order:

Master =>(ID)(Sync Field)(Sync Break) and then Slave respond with (Data)(CRC).

I want to send data frames and receive response from slaves.
My question is how to achieve it with these settings:

Forward Mask: RS232
Master status: Inactive
Lin Bus Termination: Master

Can you send me a example byte sequence for example respond frame:

ID: 1
Data length: 8
CRC: 2.x

M.Maidhof
Support
Support
Posts: 1306
Joined: Wed 22. Sep 2010, 14:00

Re: Send master request frame - problem

Post by M.Maidhof » Wed 13. Mar 2013, 11:33

Hi,

please configure the frame configuration of PCAN-LIN with the PCAN-LIN-CT software, so that ID 1 is set to subscriber and checksum 2.x. Set the forward mask in LIN section to RS232 and enable the RS-232 Error field, set the LIN Bus termination to master, and send the configuration to the module. Disconnect the PCAN-LIN CT to let your application use the serial port.

Send the following serial stream on the serial port:

0x02 0x01 0x81 0x81 0x01

Answer from PCAN-LIN:
0x02 0x01 0x00 0x01 // OK

Answer from the LIN Slave:
0x02 0xA9 0x81 0x12 0x34 0x56 0x78 0x9A 0xBC 0xDE 0xFF 0x27

Please see PCAN-LIN Protocoll Definitions pdf on page 99 for more details.

regards

Michael

Sternal87
Posts: 4
Joined: Wed 13. Mar 2013, 10:05

Re: Send master request frame - problem

Post by Sternal87 » Wed 13. Mar 2013, 11:56

Yes, I saw this, and I think I tired it but with no success. I think I made some stupid mistake because frame that you send me works.

Many thanks for god and fast advice :D

User avatar
U.Wilhelm
Sales & Support
Sales & Support
Posts: 1196
Joined: Fri 10. Sep 2010, 19:34

Re: Send master request frame - problem

Post by U.Wilhelm » Mon 18. Mar 2013, 10:14

closed
--------------------------------
PEAK-System Technik
Technical Support Team
support@peak-system.com
-------------------------------

Locked