Actually, I have follow the steps as Configuring Clocks for the [To use PLLAON as clock source] session, but my can parent clock is still osc
hello syujen_1997,
assume you did not update device tree correctly. please check the flashing process to ensure you’d update those binaries correctly.
also, please review /boot/extlinux/extlinux.conf
, it’s CBoot functionality includes a default booting scan sequence, it’ll have higher priority to load device tree blob via file system if you had FDT entry specified.
thanks
I never edit extlinux.conf
here is itextlinux.txt (862 Bytes)
I check tegra194-a02-bpmp-p2888-a04.dtb again, but I found everytime I edit it, after flash my Xavier, it is still the Original version,shows:
clock@can1 {
allow_fractional_divider = <0x1>;
allowed-parents = <0x121 0x5b 0x13a>;
clk-id = <0x9>;
};
clock@can2 {
allow_fractional_divider = <0x1>;
allowed-parents = <0x121 0x5b 0x13a>;
clk-id = <0xb>;
};
please share your steps to edit the binary and also the steps to flash Jetson AGX Xavier.
- prepare the NVIDIA SDK Manager on my virtual machine ubuntu 18.04 on the VMware Workstation Pro
- Connect Xavier to the virtual machine ubuntu 18.04, download JetPack OS image 4.4
- edit tegra194-a02-bpmp-p2888-a04.dtb under ~/nvidia/nvidia_sdk/JetPack_4.4_Linux_JETSON_AGX_XAVIER/Linux_for_Tegra/bootloader/ to dts by command
sudo ~/nvidia/nvidia_sdk/JetPack_4.4_Linux_JETSON_AGX_XAVIER/Linux_for_Tegra/kernel/dtc -I dtb -O dts -o ~/nvidia/nvidia_sdk/JetPack_4.4_Linux_JETSON_AGX_XAVIER/Linux_for_Tegra/bootloader/tegra194-a02-bpmp-p2888-a04.dts ~/nvidia/nvidia_sdk/JetPack_4.4_Linux_JETSON_AGX_XAVIER/Linux_for_Tegra/bootloader/tegra194-a02-bpmp-p2888-a04.dtb
make sure:
clock@can1 {
allow_fractional_divider = <0x1>;
allowed-parents = <0x121 0x13a 0x5e>;
clk-id = <0x9>;
};
clock@can2 {
allow_fractional_divider = <0x1>;
allowed-parents = <0x121 0x13a 0x5e>;
clk-id = <0xb>;
};
then turn it back to .dtb by command sudo ~/nvidia/nvidia_sdk/JetPack_4.4_Linux_JETSON_AGX_XAVIER/Linux_for_Tegra/kernel/dtc -I dts -O dtb -o ~/nvidia/nvidia_sdk/JetPack_4.4_Linux_JETSON_AGX_XAVIER/Linux_for_Tegra/bootloader/tegra194-a02-bpmp-p2888-a04.dtb ~/nvidia/nvidia_sdk/JetPack_4.4_Linux_JETSON_AGX_XAVIER/Linux_for_Tegra/bootloader/tegra194-a02-bpmp-p2888-a04.dts
- edit tegra194-p2888-0001-p2822-0000.dtb under ~/nvidia/nvidia_sdk/JetPack_4.4_Linux_JETSON_AGX_XAVIER/Linux_for_Tegra/kernel/dtb/ by command sudo /home/johnsyu/nvidia/nvidia_sdk/JetPack_4.4_Linux_JETSON_AGX_XAVIER/Linux_for_Tegra/kernel/dtc -I dtb -O dts -o ~/nvidia/nvidia_sdk/JetPack_4.4_Linux_JETSON_AGX_XAVIER/Linux_for_Tegra/kernel/dtb/tegra194-p2888-0001-p2822-0000.dts ~/nvidia/nvidia_sdk/JetPack_4.4_Linux_JETSON_AGX_XAVIER/Linux_for_Tegra/kernel/dtb/tegra194-p2888-0001-p2822-0000.dtb
make sure
clocks-init {
compatible = “nvidia,clocks-config”;
status = “okay”;
disable {
clocks = <0x4 0x9 0x4 0xb>;
};
};
mttcan@c310000 {
pll_source = “pllaon”;
clocks = <0x4 0x11c 0x4 0xa 0x4 0x9 0x4 0x5e>;; /New entry/
clock-names = “can_core”, “can_host”, “can”, “pllaon”;
};
mttcan@c320000 {
pll_source = “pllaon”;
clocks = <0x4 0x11d 0x4 0xc 0x4 0xb 0x4 0x5e>;
clock-names = “can_core”, “can_host”, “can”, “pllaon”;
};
then turn it back to .dtb file by command *sudo ~/nvidia/nvidia_sdk/JetPack_4.4_Linux_JETSON_AGX_XAVIER/Linux_for_Tegra/kernel/dtc -I dts -O dtb -o ~/nvidia/nvidia_sdk/JetPack_4.4_Linux_JETSON_AGX_XAVIER/Linux_for_Tegra/kernel/dtb/tegra194-p2888-0001-p2822-0000.dtb ~/nvidia/nvidia_sdk/JetPack_4.4_Linux_JETSON_AGX_XAVIER/Linux_for_Tegra/kernel/dtb/tegra194-p2888-0001-p2822-0000.dts
*
- flash OS
but I did’t install SDK compontents on my AGX Xavier
hello syujen_1997,
you cannot use the SDKManager to update the target with your customization, as it’ll flash the default JetPack image to the target.
instead, please refer to Basic Flash Script Usage and execute flash.sh
to deploy your modification.
Hi JerryChang,
Thank you for your patience.
I still don’t know how to do, how can I edit egra194-a02-bpmp-p2888-a04.dtb on my AGX Xavier, because there is no this file on my AGX Xavier
What I want to do is achieve CAN-bus communication in normal mode instead of loopback mode, but when I configure CAN in normal mode, it doesn’t work, somebody says I should enable PLLAON clock, so I do all these things
hello syujen_1997,
you should perform this modification on your x86 local host desktop, and update the binaries through flash.sh
accordingly.
for your reference, it’s the flash process to update bpmp-fw-dtb partition in the flash messages,
[ 214.6266 ] Writing partition bpmp-fw-dtb with tegra194-a02-bpmp-p2888-a02_sigheader.dtb.encrypt
[ 214.6610 ] [................................................] 100%
you may overwrite that binary file and use flash script to re-flash your target. $ sudo ./flash.sh -r jetson-xavier mmcblk0p1
or, you could enable partition update as you knew that’s bpmp-fw-dtb partition to include this binary. $ sudo ./flash.sh -r -k bpmp-fw-dtb jetson-xavier mmcblk0p1
thanks
Is there any video tutorials?
hello syujen_1997,
please refer to Basic Flash Script Usage for using the script file, flash.sh
.
I got it, but I’m still a little confused. What should I do after I modify the files tegra194-a02-bpmp-p2888-a04.dtb and tegra194-p2888-0001-p2822-0000.dtb on the host and before flashing Xavier? what do you mean by “update the binaries through flash.sh accordingly”
In other words, if “modifying the files tegra194-a02-bpmp-p2888-a04.dtb and tegra194-p2888-0001-p2822-0000.dtb on the host” is the first step and “flash AGX Xavier” is the third step, what do I need to do in the second step?
And, maybe I should edit tegra194-p2888-0004-p2822-0000.dtb instead of tegra194-p2888-0001-p2822-0000.dtb, P2888-0001 (16 GB) and P2888-004 (32 GB).
hello syujen_1997,
don’t you update the clock to use PLLAON as clock source?
as you may already knew it. these binaries on your local host contain the default JetPack image.
it’s up-to-you to edit than flashing, or flashing the target at first to have update binary applied.
furthermore,
you should check the flashing messages carefully, you’ll understand which binary file your target used.
hello syujen_1997,
it looks you did not execute this before, you don’t have system.img
on your local host. that’s why you cannot enable -r
options.
so, please perform $ sudo ./flash.sh -k bpmp-fw-dtb jetson-xavier mmcblk0p1
for confirmation,
thanks
I have one more question:
On one occasion, I flash os from SDK Manager, and I know it’s default OS, when I use can in normal mode, I type “cansend can1 123#1122”, CAN controller does sent message out, but it never stop and can’t send new message out, why does this happen?
hello syujen_1997,
did you use the CAN utility, candump
to receive a packet from can1?
Yes, I did.
In one terminal: candump can0
In the second terminal cansend can1 123#1122
Maybe it’s because can0 doesn’t work, because when I type cansend can1 123#1122, then connect CAN_H CAN_L to CAN analyzer( which shown in figure), it can receive message, just the message never stop, when connect CAN_H CAN_L to an Oscilloscope, the signal can be detected.
But when I type cansend can0 123#1122 and connect CAN_H CAN_L to CAN analyzer or to an Oscilloscope, the signal cannot be detected either.
Besides I set CAN in normal mode, by sudo ip link set can0 type can bitrate 200000 and sudo ip link set can1 type can bitrate 200000
Moreover, I test can in “loopback” mode, It acts rightly
Hi, JerryChang
I found one new question
After $ sudo ./flash.sh -k bpmp-fw-dtb jetson-xavier mmcblk0p1
, fig 1 shown on my host
It seems successful, and on my xavier I check
/sys/kernel/debug/bpmp/debug/clk/can1/parent
it shows pll_aoncan2/parent
shows pll_aon too.but I type these command in terminal step by step, every time I enter a command line, I check “parent clock”
sudo busybox devmem 0x0c303000 32 0x0000C400
sudo busybox devmem 0x0c303008 32 0x0000C458
sudo busybox devmem 0x0c303010 32 0x0000C400
sudo busybox devmem 0x0c303018 32 0x0000C458
sudo modprobe can
sudo modprobe can_raw
sudo modprobe mttcan
just after sudo modprobe mttcan
, can1/parent
turns back to osc
Thanks for your replay
I configured the clock according to the tutorial, and I found the same problem, the can1/parent
turns back to osc. And the can communication still failed. Do you solve the problem?
According to observation,after $ sudo ./flash.sh -r jetson-xavier mmcblk0p1 execution, the dtb file tegra194-a02-bpmp-p2888-a04.dtb and tegra194-p2888-0001-p2888-0000.dtb are restored to the original state rather than modified. This maybe the reason can1/parent
turns back to osc. But I do not know how to solve the problem. Dear JerryChang, could you help me?