News:

Attention: For security reasons,please choose a user name *different* from your login name.
Also make sure to choose a secure password and change it regularly.

Main Menu

Zynqberry 726 + Petalinux + Kernel + CAN support

Started by javier.reyes.g, April 09, 2018, 03:22:39 PM

Previous topic - Next topic

javier.reyes.g

Dear all

I am trying to build an image for the Zynqberry 726 with Petalinux. I am using the scripts in the test_board project provided (for Vivado & Petalinux 2017.4), and adding the CAN peripheral in the IP Core (before running the hardware export), as well as the necessary configurations for mapping the CAN signals to EMIO to header pins.

Following the Petalinux Kickstart (https://wiki.trenz-electronic.de/display/PD/PetaLinux+KICKstart), and the Getting started Wiki (https://eewiki.net/display/Motley/Getting+Started+with+the+ZynqBerry), I can observe that in the kernel config, it is necessary to include the drivers for the USB to Ethernet module.

My question is: Should I also config something in the kernel (or later in the device tree), to be able to use the CAN module?

Thanks in advance.

Best regards

Javier

JH

Hi,

i think CAN driver will be set automatically during hdf import. But you can also check:
for CAN, see also:
br
John

javier.reyes.g

Thanks for the link.

I was trying to build the linux image, and the command petalinux-build failed for the Device Tree, after I added the section that is shown here (http://www.wiki.xilinx.com/Linux+CAN+driver) into the system-user.dtsi file.


zynq_can_0: can@e0008000 {
    compatible = "xlnx,zynq-can-1.0";
    clocks = <&clkc 19>, <&clkc 36>;
    clock-names = "can_clk", "pclk";
    reg = <0xe0008000 0x1000>;
    interrupts = <0 28 4>;
    interrupt-parent = <&intc>;
    tx-fifo-depth = <0x40>;
    rx-fifo-depth = <0x40>;
};


I cannot find any other helpful information on how to enable the can controller in the linux image build process. What could I do?

JH

Hi,

did you enable the same CAN controller on the PS in your design?
Did you use the new generated HDF for your petalinux project?
Which Vivado and Petalinux version did you use?
Petalinux generate a log file, did you check this? See console output to find the log file.

br
John