Changes

Jump to: navigation, search

Orange Pi 5 Plus

371 bytes added, 18:07, 6 June 2023
Use the CANalyst-II analyzer to test sending and receiving messages
<p>[[File:media/image322.png|165x134px]]</p></li>
<li><p>CANalyst-II analyzer data download link</p>
<p>[https{| class="wikitable" style="width://www.zhcxgd.com/3.html 800px;" |-|'''https://www.zhcxgd.com/3.html''']</p>|}</li>
<li><p>First install the software USBCANToolSetup</p>
<p>[[File:media/image323.png|553x94px]]</p></li>
<ol style="list-style-type: lower-alpha;">
<li><p>a. First set the baud rate of the CAN bus to '''1000kbps''' in &gt; the Linux system of the development board</p>
{| class="wikitable" style="width:800px;"
|-
|
<p>orangepi@orangepi:~$ '''sudo ip link set can0 down'''</p>
<p>orangepi@orangepi:~$ '''sudo ip link set can0 type can bitrate 1000000'''</p>
<p>orangepi@orangepi:~$ '''sudo ip link set can0 up'''</p>|}</li>
<li><p>Then run the '''candump can0''' command to prepare to receive &gt; messages</p>
{| class="wikitable" style="width:800px;" |-|<p>orangepi@orangepi:~$ '''sudo candump can0'''</p>|}</li>
<li><p>Then send a message to the development board in the USB-CAN &gt; software</p>
<p>[[File:media/image333.png|553x188px]]</p></li>
<li><p>If the message sent by the analyzer can be received in the &gt; development board, it means that the CAN bus can be used &gt; normally</p>
{| class="wikitable" style="width:800px;"
|-
|
<p>orangepi@orangepi5plus:~$ '''sudo candump can0'''</p>
<p>'''&nbsp;&nbsp;&nbsp;&nbsp; can0 &nbsp;&nbsp;&nbsp;&nbsp; 001 &nbsp;&nbsp;&nbsp;&nbsp; [8] &nbsp;&nbsp;&nbsp;&nbsp; 01 02 03 04 05 06 07 08'''</p>|}</li></ol>
</li>
<li><p>Development board sends CAN message test</p>
<ol style="list-style-type: lower-alpha;">
<li><p>a. First set the CAN baud rate to '''1000kbps''' in the Linux &gt; system</p>{| class="wikitable" style="width:800px;" |-|
<p>orangepi@orangepi:~$ '''sudo ip link set can0 down'''</p>
<p>orangepi@orangepi:~$ '''sudo ip link set can0 type can bitrate 1000000'''</p>
<p>orangepi@orangepi:~$ '''sudo ip link set can0 up'''</p>|}</li>
<li><p>Execute the '''cansend''' command on the development board and &gt; send a message</p>
{| class="wikitable" style="width:800px;" |-|<p>orangepi@orangepi:~$ '''sudo cansend can0 123#1122334455667788'''</p>|}</li>
<li><p>If the USB-CAN software can receive the message from the &gt; development board, the communication is successful</p>
<div class="figure">
<span id="how-to-install-and-use-wiringop-python"></span>
 
== How to install and use wiringOP-Python ==

Navigation menu