Author Topic: ZynqberryTE0726-03m reconfigure the kernel on Zynqberrydemo2  (Read 4143 times)

Waldi3141

  • Active Member
  • *
  • Posts: 8
ZynqberryTE0726-03m reconfigure the kernel on Zynqberrydemo2
« on: November 17, 2017, 03:16:41 PM »
Hello,

i got installed:
Vivado & SDK 2017.1
PetaLinux 2017.1 (Virtualbox) on Ubuntu 16.04

I managed to get the Debian up and running on the Zynqberry TE0726-03m according to the short Instructions. (Zynqberrydemo2 - 2017.1)

Now i want to add a Wifi USB Stick(TP-Link TL_WN823N with RTL8192CU) to the running Debian System. Therefore I have to reconfigure the kernel and add some drivers.
So i created a new petalinux-project (2017.1) and choose the related drivers in 'petalinux-config -c kernel' like here
http://bootseeds.com/home-flex-slider/bootseeds-projects/microzed-wifi-petalinux
or
http://www.zedboard.org/content/howto-guide-using-usb-wifi-adapter-zedboard

The .hdf-File is from zynqberrydemo2/prebuilt/hardware/te_0726_m/

After successfull 'petalinux-build' i replaced the new 'image.ub' with the file on the SD-Card. Nothing else changed on the SD-Card/FPGA-Flash.

Now after Bootup i cant get into Desktop-Debian with the command 'startx' anymore.

Did I miss something ? btw, I also tried to use the petalinux-project in "zynqberrydemo2/os/petalinux"  which failed aswell.

Thanks for your time :)

Oleksandr Kiyenko

  • Global Moderator
  • Sr. Member
  • *****
  • Posts: 340
Re: ZynqberryTE0726-03m reconfigure the kernel on Zynqberrydemo2
« Reply #1 on: November 17, 2017, 05:54:04 PM »
Hello,

to you use Debian, you need to set you SD card as root filesystem. In other case you will get RAMFS image with simple linux.
Run petalinux-config and check
Image Packaging Configuration  ---> Root filesystem type
for Debian it should be set as "SD card"

Best regards
Oleksandr Kiyenko

Waldi3141

  • Active Member
  • *
  • Posts: 8
Re: ZynqberryTE0726-03m reconfigure the kernel on Zynqberrydemo2
« Reply #2 on: November 20, 2017, 01:45:07 PM »
Hi again,

thanks for your reply I set to "sd card" before without success. I found a workaround by using the "preconfigured PetaLinux project" inside the refernce Design "/os/petalinux" and building my kernel image.ub in there.
I only had to add the prebuilt .hdf-File and change a path in the Configs according to https://wiki.trenz-electronic.de/display/PD/PetaLinux+KICKstart.

So now i can configure the Kernel and build the project successfully.

I still can not see wifi-usb adapter on the Debian-Desktop with 'ifconfig', after configuring the kernel but thats probably another topic.

greetings
Waldi 

 

JH

  • Hero Member
  • *****
  • Posts: 839
Re: ZynqberryTE0726-03m reconfigure the kernel on Zynqberrydemo2
« Reply #3 on: November 22, 2017, 11:35:46 AM »
Hi,

use your HDF (maybe at first step try without changes or use prebuilt to check if you petalinux installation is correct) with template from:
  • zynqberrydemo2/os/petalinux
After Petalinux build process is finished, run the debian scripted from the folder. It will generate a image, what you can use for SD. Use  Use Win32 Disk Imager to write SD.
Insert SD into SD Card slot and generate Boot.bin with your uboot.elf , fsbl and bitfile. Write Boot.bin into Flash and reboot.

For Wifi, you must check Kernel driver , rootfs settings.... your tutorial is for Vivado 2015.4:
http://bootseeds.com/home-flex-slider/bootseeds-projects/microzed-wifi-petalinux
No you use 17.1 a lot of things has changed on petalinux during this time.
Maybe something like this helps:
http://www.wiki.xilinx.com/Zynq+SDIO+Wifi

If debian runs on SD, you can also try to install drivers... over ETH.

br
John

Waldi3141

  • Active Member
  • *
  • Posts: 8
Re: ZynqberryTE0726-03m reconfigure the kernel on Zynqberrydemo2
« Reply #4 on: November 23, 2017, 05:04:53 PM »
Hi,

i really appreciate your answers.
Wifi ist working! :D :D :D Although i am not pretty sure why and how.
I gave it a new try, Vivado, SDK, Petalinux all 2017.1 .
I configured the kernel according to the links above with the Petalinux-Projekt from Zynqberrydemo2/os/petalinux. (Beside many other options i checked the RTL8192CU-Firmware for my Belkin N300 F7D2102)
Created the SDK-Project with the CMD-Script and created the "BOOT-bin"-image with prebuilt fsbl, prebuilt BIT-File and the uboot.elf from the Petalinux-Projekt.
Created the SD-Card with the Win32-Tool and Debian as the Rootfs.
Copied the created kernel-image.ub and the prebuilt uboot.rgba on the first partition.

So after Boot-up and "startx" I got it somehow running by following:

https://debianforum.de/forum/viewtopic.php?t=146042
https://wiki.debianforum.de/WLAN_Einrichten
https://www.linux.com/answers/how-do-i-get-debian-see-my-wifi

Had to reboot a few times till the network-manager symbol came up on the top right XFCE-Desktop and i were able to connect.

Thanks




Waldi3141

  • Active Member
  • *
  • Posts: 8
Re: ZynqberryTE0726-03m reconfigure the kernel on Zynqberrydemo2
« Reply #5 on: December 15, 2017, 12:30:16 PM »
Hi, its me again,
I thought i post the problem here, since it is basically the same issue as before except i am using the TE0720 + TE0703 carrier board.
Again I use all programs version 2017.1 and the Reference Design "test_board". It says USB,ETH,I2C and RTC are implemented so i thought i could copy the Debian Filesystem from the Zynqberry-Design and configure the kernel as before ..
But the single-USB-port seems to be very buggy. USB-WIFI can not be enumerated and i get often errors like: rtl_usb: reg 0x4, usbctrl_vendorreq TimeOut! status:0xffffff92 value=...

I wonder if something else must be set in petaLinux-configs ... but since it says USB is implemented i guess its more of a software problem ...

Maybe you can give me a hint ^^

regards waldi

JH

  • Hero Member
  • *****
  • Posts: 839
Re: ZynqberryTE0726-03m reconfigure the kernel on Zynqberrydemo2
« Reply #6 on: December 15, 2017, 12:39:58 PM »
Hi,

do you have this errors, if you use reference design as provided?

It's never a good idea to use files from different systems. I would recommend to regenerate all with files from TE0720 reference design. Try debian scripts from TE0726 on TE0020 petalinux. But with this carrier, you can't use GUI.

br
John

Waldi3141

  • Active Member
  • *
  • Posts: 8
Re: ZynqberryTE0726-03m reconfigure the kernel on Zynqberrydemo2
« Reply #7 on: December 18, 2017, 12:45:31 PM »
Hi

 1)
using the reference design prebuilt BOOT.bin and image.ub it always states messages similar to this when attaching USB devices (mass storage, wifi dongle etc.):

usb 1-1: new high-speed USB device number 3 using ci_hdrc
usb 1-1: new high-speed USB device number 4 using ci_hdrc
usb 1-1: device not accepting address 4, error -110
usb 1-1: new high-speed USB device number 5 using ci_hdrc
usb 1-1: device not accepting address 5, error -110
usb usb1-port1: unable to enumerate USB device

2)
I regenerated the Debian image from the TE0720 - /os/petalinx - directory with the "mkdebian.sh"-file and of course configured the kernel, set SD-boot etc. and still messages like these appear.
For the Belkin usb-wifi -adapter attached:

root@zynq:~# usb 1-1: new high-speed USB device number 2 using ci_hdrc
usb 1-1: device not accepting address 2, error -110
usb 1-1: new high-speed USB device number 3 using ci_hdrc
usb 1-1: New USB device found, idVendor=050d, idProduct=2103
usb 1-1: New USB device strings: Mfr=1, Product=2, SerialNumber=3
usb 1-1: Product: Belkin Wireless Adapter
usb 1-1: Manufacturer: Realtek
usb 1-1: SerialNumber: 00e04c000001
rtl8192cu: Chip version 0x11
rtl_usb: reg 0x32, usbctrl_vendorreq TimeOut! status:0xffffff92 value=0x0
rtl_usb: reg 0x33, usbctrl_vendorreq TimeOut! status:0xffffff92 value=0x0
rtl_usb: reg 0x30, usbctrl_vendorreq TimeOut! status:0xffffff92 value=0x0
rtl_usb: reg 0x30, usbctrl_vendorreq TimeOut! status:0xffffff92 value=0x0
^C
root@zynq:~# lsusb
Bus 001 Device 003: ID 050d:2103 Belkin Components F7D2102 802.11n N300 Micro Wireless Adapter v3000 [Realtek RTL8192CU]
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

Also, i often have to reboot the system since reattaching new usb devices has no effect.. no messages .. nothing

3)
 Yes i cannot directly plug a monitor to it but i was able to access the Debian-GUI (Xfce) with the Tight VNC-Server, eventhough its not really necessary

waldi

 

JH

  • Hero Member
  • *****
  • Posts: 839
Re: ZynqberryTE0726-03m reconfigure the kernel on Zynqberrydemo2
« Reply #8 on: December 18, 2017, 12:54:50 PM »
Hi,
to be on the safe side. Boot.bin and image.ub from 2017.2 reference design?
Quote
usb 1-1: new high-speed USB device number 3 using ci_hdrc
usb 1-1: new high-speed USB device number 4 using ci_hdrc
usb 1-1: device not accepting address 4, error -110
usb 1-1: new high-speed USB device number 5 using ci_hdrc
usb 1-1: device not accepting address 5, error -110
usb usb1-port1: unable to enumerate USB device
If you get this message with different USB devices and prebuilt files. I think something is with your Hardware.

Can you try following: Unplug TE0720 from TE0703. Check visual B2B connectors, if something is with these pins from carrier and module. If everything seems to be OK, plug on TE0720 and try again.
 
br
John

Waldi3141

  • Active Member
  • *
  • Posts: 8
Re: ZynqberryTE0726-03m reconfigure the kernel on Zynqberrydemo2
« Reply #9 on: December 18, 2017, 02:36:28 PM »
its really weird... i get different messages now
with with the reference design 2017.1 and 2017.2 image.ub and BOOT.bin following messages like these are shown for the Belkin USB device:

root@plnx_arm:~# usb 1-1: new high-speed USB device number 6 using ci_hdrc
usb 1-1: new high-speed USB device number 7 using ci_hdrc

no enumeration error anymore :)

maybe it is something with the power supply, it makes a light but clearly hearable high beeping noise, I measured 5,18 V .. its the provided one 


JH

  • Hero Member
  • *****
  • Posts: 839
Re: ZynqberryTE0726-03m reconfigure the kernel on Zynqberrydemo2
« Reply #10 on: December 18, 2017, 04:18:14 PM »
Hi,

you bought TE0720 starterkit? I haven't this power supply unit on my place. But I am not aware of any problems with this.

If you connect usb memory stick, can you get access?

br
John

Waldi3141

  • Active Member
  • *
  • Posts: 8
Re: ZynqberryTE0726-03m reconfigure the kernel on Zynqberrydemo2
« Reply #11 on: December 18, 2017, 06:10:20 PM »
Hi, yes i bought the kit. 

Yes i just managed to mount a usb mass storage device and access data.

It is so weird i get these errors.. since i did the same configuration on the zynqberry where i was able to get wifi working.

Now when I  plug in the Belkin wifi dongle I always get these errors:

root@zynq:~# usb 1-1: new high-speed USB device number 3 using ci_hdrc
rtl8192cu: Chip version 0x11
rtl8192cu: Board Type 0
rtl_usb: rx_max_size 15360, rx_urb_num 8, in_ep 1
rtl8192cu: Loading firmware rtlwifi/rtl8192cufw_TMSC.bin
rtl8192cu: MAC auto ON okay!
rtl8192cu: Tx queue select: 0x05
rtl_usb: reg 0x82, usbctrl_vendorreq TimeOut! status:0xffffff92 value=0xa200
rtl_usb: reg 0x82, usbctrl_vendorreq TimeOut! status:0xffffff92 value=0xa300
rtl_usb: reg 0x82, usbctrl_vendorreq TimeOut! status:0xffffff92 value=0xa400
rtl_usb: reg 0x80, usbctrl_vendorreq TimeOut! status:0xffffff92 value=0xa500



Waldi3141

  • Active Member
  • *
  • Posts: 8
Re: ZynqberryTE0726-03m reconfigure the kernel on Zynqberrydemo2
« Reply #12 on: December 19, 2017, 11:18:26 AM »
Good morning
You wont believe me...

I changed the Power supply 5V 4A from trenz. Now I use a 5V 2A supply.

I can connect to Wifi now without these messages:

rtl_usb: reg 0x82, usbctrl_vendorreq TimeOut! status:0xffffff92 value=0xa200
rtl_usb: reg 0x82, usbctrl_vendorreq TimeOut! status:0xffffff92 value=0xa300
rtl_usb: reg 0x82, usbctrl_vendorreq TimeOut! status:0xffffff92 value=0xa400
rtl_usb: reg 0x80, usbctrl_vendorreq TimeOut! status:0xffffff92 value=0xa500

with the 5V 4A supply again i get these messages ...

lost so much time ... how could that be the reason O.o ..

thanks