Zynq u-boot: Unterschied zwischen den Versionen
Zur Navigation springen
Zur Suche springen
Nick (Diskussion | Beiträge) |
Nick (Diskussion | Beiträge) |
||
| (24 dazwischenliegende Versionen desselben Benutzers werden nicht angezeigt) | |||
| Zeile 1: | Zeile 1: | ||
= | = Build U-Boot = | ||
Download tools and u-boot: | Download tools and u-boot: | ||
sudo apt install bison -y | sudo apt install libssl-dev bison gcc-arm* -y | ||
git clone https://github.com/Xilinx/u-boot-xlnx.git | git clone https://github.com/Xilinx/u-boot-xlnx.git | ||
cd u-boot-xlnx/ | cd u-boot-xlnx/ | ||
| Zeile 7: | Zeile 7: | ||
export CROSS_COMPILE=arm-linux-gnueabihf- | export CROSS_COMPILE=arm-linux-gnueabihf- | ||
export ARCH=arm | export ARCH=arm | ||
Konfigurieren und baunen von u-boot: | Konfigurieren und baunen von u-boot (< 2020.1 Release): | ||
make distclean | make distclean | ||
make | make zynq_zc706_defconfig | ||
make | make | ||
Konfigurieren und baunen von u-boot (>= 2020.1 Release): | |||
make distclean | |||
make xilinx_zynq_virt_defconfig | |||
export DEVICE_TREE="zynq-zc706" #device tree können unter u-boot-xlnx/arch/arm/dts/ gefunden werden | |||
make xconfig #(optional) u-boot konfigurieren | |||
make | |||
Der "device tree" sollte (muss aber nicht) vor dem u-boot geladen werden. | |||
== Upload U-Boot (JTAG) == | |||
*Menüleiste Xilinx ⇒ XSCT Console | |||
Vor dem u-boot.elf hochladen, muss der FSBL.elf hochgeladen werden: | |||
connect #Mit Hardware verbinden | |||
targets #Anzeigen der CPUs | |||
targets 2 #Auswahl CPU 2 | |||
cd path_to_fsbl/ #In das Verzeichnes vom fsbl wechseln | |||
dow fsbl.elf #Upload fsbl | |||
con #gestoppten CPU weiter laufen lassen | |||
stop #Vor dem CPU Stop etwas warten | |||
dow u-boot.elf #Upload u-boot | |||
con #gestoppten CPU weiter laufen lassen | |||
Wird keine Ausgabe auf der Seriellen Konsole angezeigt, kann es sein das die Ausgabe auf einer anderen UART Schnittstelle erfolgt.<br> | |||
Zum Beispeil: Ausgabe fsbl.elf auf UART0 und Ausgabe u-boot.elf auf UART1. | |||
= Probleme = | |||
{| class="wikitable" | |||
!Fehler | |||
!Lösung | |||
|- | |||
| | |||
./scripts/gcc-version.sh: line 25: arm-linux-gnueabihf-gcc: command not found | |||
| | |||
sudo apt-get install gcc-arm* | |||
|- | |||
| | |||
There is no active target available for server at localhost. | |||
Targets(s) ",jsn-..." may be locked by another hw_server. | |||
| | |||
VirtualBox Manager ⇒ Ändern ⇒ USB ⇒ USB-3.0-Controller (xHCI) | |||
|- | |||
| | |||
Upload fsbl.elf und u-boot.elf<br> | |||
Keine oder nur fsbl.elf Ausgabe über die serielle Konsole. | |||
| | |||
Die Ausgabe auf einer anderen UART (z.B. UART 1, nicht UART 0) | |||
|} | |||
= Quelle = | |||
[https://xilinx-wiki.atlassian.net/wiki/spaces/A/pages/18841973/Build+U-Boot Xilinx U-Boot] | |||
Aktuelle Version vom 2. September 2021, 11:23 Uhr
Build U-Boot
Download tools and u-boot:
sudo apt install libssl-dev bison gcc-arm* -y git clone https://github.com/Xilinx/u-boot-xlnx.git cd u-boot-xlnx/
Umgebungsvariablen für Zynq setzen:
export CROSS_COMPILE=arm-linux-gnueabihf- export ARCH=arm
Konfigurieren und baunen von u-boot (< 2020.1 Release):
make distclean make zynq_zc706_defconfig make
Konfigurieren und baunen von u-boot (>= 2020.1 Release):
make distclean make xilinx_zynq_virt_defconfig export DEVICE_TREE="zynq-zc706" #device tree können unter u-boot-xlnx/arch/arm/dts/ gefunden werden make xconfig #(optional) u-boot konfigurieren make
Der "device tree" sollte (muss aber nicht) vor dem u-boot geladen werden.
Upload U-Boot (JTAG)
- Menüleiste Xilinx ⇒ XSCT Console
Vor dem u-boot.elf hochladen, muss der FSBL.elf hochgeladen werden:
connect #Mit Hardware verbinden targets #Anzeigen der CPUs targets 2 #Auswahl CPU 2 cd path_to_fsbl/ #In das Verzeichnes vom fsbl wechseln dow fsbl.elf #Upload fsbl con #gestoppten CPU weiter laufen lassen stop #Vor dem CPU Stop etwas warten dow u-boot.elf #Upload u-boot con #gestoppten CPU weiter laufen lassen
Wird keine Ausgabe auf der Seriellen Konsole angezeigt, kann es sein das die Ausgabe auf einer anderen UART Schnittstelle erfolgt.
Zum Beispeil: Ausgabe fsbl.elf auf UART0 und Ausgabe u-boot.elf auf UART1.
Probleme
| Fehler | Lösung |
|---|---|
./scripts/gcc-version.sh: line 25: arm-linux-gnueabihf-gcc: command not found |
sudo apt-get install gcc-arm* |
There is no active target available for server at localhost. Targets(s) ",jsn-..." may be locked by another hw_server. |
VirtualBox Manager ⇒ Ändern ⇒ USB ⇒ USB-3.0-Controller (xHCI) |
|
Upload fsbl.elf und u-boot.elf |
Die Ausgabe auf einer anderen UART (z.B. UART 1, nicht UART 0) |