WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: setup usb - lan adapter on pi zero running piCore 8.0  (Read 7290 times)

Offline bernie

  • Newbie
  • *
  • Posts: 15
setup usb - lan adapter on pi zero running piCore 8.0
« on: June 30, 2016, 11:51:04 AM »
Hello,

After reading allot of similar threads on getting ssh to work i realise that i can't seem to figure out the basics, for instance setting up the drivers from the armv6/releases/RPi/src/kernel/4.4.11-piCore+_modules.tar.xz file etc.

What i have is a cheap (blue) usb-lan adapter, a serial connection via mac terminal-FTDI to piCore 8.0v3.
My serial usb connection works, i can log in and change partition etc.

I dont have a clue where to start with the 4.4.11-piCore file mentioned above. Do i have to move the appropriate files to my sd-card where the picore image is installed and do the rest via command line?

This reply from mikedev seems to answer my questions, but i need some pointers towards the actual command line used.

To support that dirt cheap usb LANadapter+USB2.0 3ports hub, I need to get http://tinycorelinux.net/8.x/armv6/releases/RPi/src/kernel/4.4.11-piCore+_modules.tar.xz and extract the
dm9601.ko
dm9601.ko.gz
into /usr/local/lib/modules/4.4.11-piCore+/kernel/dirvers/net/usb/
and remaster the core.gz

Thanks, and sorry if i missed something i should have read first.





Offline curaga

  • Administrator
  • Hero Member
  • *****
  • Posts: 11049
Re: setup usb - lan adapter on pi zero running piCore 8.0
« Reply #1 on: June 30, 2016, 12:17:21 PM »
Just install net-usb-4.4.14-piCore_v7+.tcz. "tce-load -wi net-usb-KERNEL" should do.
The only barriers that can stop you are the ones you create yourself.

Offline bernie

  • Newbie
  • *
  • Posts: 15
Re: setup usb - lan adapter on pi zero running piCore 8.0
« Reply #2 on: June 30, 2016, 01:31:15 PM »
Thank you, but that would require internet excess already installed?

Offline Paul_123

  • Administrator
  • Hero Member
  • *****
  • Posts: 1264
Re: setup usb - lan adapter on pi zero running piCore 8.0
« Reply #3 on: June 30, 2016, 02:56:44 PM »
That is the problem with the zero.....you need another computer to get it running.

Setup the SDcard on a B or B+ then move the card to the Zero

or

Put the SDcard into another working linux system.   Mount the 2nd partition, and Download the file directly with wget.
http://distro.ibiblio.org/tinycorelinux/8.x/armv6/tcz/net-usb-4.4.14-piCore+.tcz
and
http://distro.ibiblio.org/tinycorelinux/8.x/armv6/tcz/net-usb-4.4.14-piCore+.tcz.md5.txt



Offline bernie

  • Newbie
  • *
  • Posts: 15
Re: setup usb - lan adapter on pi zero running piCore 8.0
« Reply #4 on: July 01, 2016, 07:16:29 AM »
Thank you, i tried it in virtualbox and finally got Ubuntu to recognize my sd-card.
Having said that i cant figure out how to mount to the second partition (dev/mmcblk0p2)
I have tried with the fdisk command on both /dev/sdb2 ?? and dev/mmcblk0p2 i also tried from within the sd-card (cd /media/user/PICORE) but without succes. again, i have no experience in this whatsoever.

fdisk -l gives me:
Code: [Select]
Device      Boot Start        End Sectors  Size        Id           Type
/dev/sdb1            8192 69631    61440               30M     c      W95 FAT32 (LBA)
/dev/sdb2          69648 93119    23472               11,5M 83          Linux

and

Code: [Select]
root@user-VirtualBox:/home/user# cd /media/user/PICORE
Code: [Select]
root@user-VirtualBox:/media/user/PICORE# ls
8.0beta3.gz                                  bootcode.bin            fixup_db.dat              RELEASE
8.0beta3v7.gz                              cmdline3.txt             fixup_x.dat                  start_cd.elf
bcm2708-rpi-b.dtb                       cmdline.txt              kernel4414.img          start_db.elf
bcm2708-rpi-b-plus.dtb              config.txt                  kernel4414v7.img     start.elf
bcm2708-rpi-cm.dtb                    COPYING.linux     LICENCE.broadcom  start_x.elf
bcm2709-rpi-2-b.dtb                    fixup_cd.dat           [color=blue]overlays[/color]
bcm2710-rpi-3-b.dtb                    fixup.dat                  README

Thank you

Offline bernie

  • Newbie
  • *
  • Posts: 15
Re: setup usb - lan adapter on pi zero running piCore 8.0
« Reply #5 on: July 01, 2016, 07:27:30 AM »
I now see another partition after running df -h, still no clue how to go from here.

Code: [Select]
/dev/sdb1        30M   29M  1,2M  97% /media/user/PICORE
/dev/sdb2        11M  6,5M  2,8M  70% /media/user/a02d2d78-3372-4a56-ad8a-4365dc452d37


Offline Paul_123

  • Administrator
  • Hero Member
  • *****
  • Posts: 1264
Re: setup usb - lan adapter on pi zero running piCore 8.0
« Reply #6 on: July 01, 2016, 07:31:29 AM »
Thank you, i tried it in virtualbox and finally got Ubuntu to recognize my sd-card.
Having said that i cant figure out how to mount to the second partition (dev/mmcblk0p2)
I have tried with the fdisk command on both /dev/sdb2 ?? and dev/mmcblk0p2 i also tried from within the sd-card (cd /media/user/PICORE) but without succes. again, i have no experience in this whatsoever.

fdisk -l gives me:
Code: [Select]
Device      Boot Start        End Sectors  Size        Id           Type
/dev/sdb1            8192 69631    61440               30M     c      W95 FAT32 (LBA)
/dev/sdb2          69648 93119    23472               11,5M 83          Linux

and

Code: [Select]
root@user-VirtualBox:/home/user# cd /media/user/PICORE
Code: [Select]
root@user-VirtualBox:/media/user/PICORE# ls
8.0beta3.gz                                  bootcode.bin            fixup_db.dat              RELEASE
8.0beta3v7.gz                              cmdline3.txt             fixup_x.dat                  start_cd.elf
bcm2708-rpi-b.dtb                       cmdline.txt              kernel4414.img          start_db.elf
bcm2708-rpi-b-plus.dtb              config.txt                  kernel4414v7.img     start.elf
bcm2708-rpi-cm.dtb                    COPYING.linux     LICENCE.broadcom  start_x.elf
bcm2709-rpi-2-b.dtb                    fixup_cd.dat           [color=blue]overlays[/color]
bcm2710-rpi-3-b.dtb                    fixup.dat                  README

Thank you

Are you sure it didn't automount.   The second partition should be listed in /media/user/.   Look for a long string of characters.....which is the uuid of the partition.

Also, make sure you expand the second partition

Offline bernie

  • Newbie
  • *
  • Posts: 15
Re: setup usb - lan adapter on pi zero running piCore 8.0
« Reply #7 on: July 01, 2016, 08:13:54 AM »
thank you, I did wget  ...picore+.tcz in root@user-VirtualBox:/media/user# , and it saved to: ‘net-usb-4.4.14-piCore+.tcz’ . i hope this was what you meant by  /media/user/.

ls gives me:
Code: [Select]
root@user-VirtualBox:/media/user# ls
a02d2d78-3372-4a56-ad8a-4365dc452d37  net-usb-4.4.14-piCore+.tcz.md5.txt
net-usb-4.4.14-piCore+.tcz            PICORE


sorry i didnt get:  Look for a long string of characters.....which is the uuid of the partition.

I will expand the size of the second partition via usb serial with: sudo fdisk /def/mmcblk0 , delete and recreate p2.

If i did it correctly i still need to know how to extract the
dm9601.ko
dm9601.ko.gz
into /usr/local/lib/modules/4.4.11-piCore+/kernel/dirvers/net/usb/
and remaster the core.gz

Should i do this over serial, or is it more convenient to do this in Ubuntu?

« Last Edit: July 01, 2016, 08:17:18 AM by bernie »

Offline bernie

  • Newbie
  • *
  • Posts: 15
Re: setup usb - lan adapter on pi zero running piCore 8.0
« Reply #8 on: July 01, 2016, 09:12:44 AM »
Alright i did
Code: [Select]
mkdir /tmp/image
sudo mount -o loop net-usb-4.4.14-piCore+.tcz /tmp/image

then

Code: [Select]
cd /tmp/image/usr/local/lib/modules/4.4.14-piCore+/kernel/drivers/net/usb/

Code: [Select]
ls
asix.ko          gl620a.ko          kaweth.ko    plusb.ko       sierra_net.ko
ax88179_178a.ko  huawei_cdc_ncm.ko  lg-vl600.ko  qmi_wwan.ko    smsc75xx.ko
catc.ko          int51x1.ko         mcs7830.ko   r8152.ko       sr9700.ko
cx82310_eth.ko   ipheth.ko          net1080.ko   rndis_host.ko  sr9800.ko
dm9601.ko        kalmia.ko          pegasus.ko   rtl8150.ko     zaurus.ko

now i have to figure out how to move dm9601.ko to the appropriate directory and where it is located in /media/user# .

Also find out where to find dm9601.ko.gz and find out how to remaster core.gz

Offline bernie

  • Newbie
  • *
  • Posts: 15
Re: setup usb - lan adapter on pi zero running piCore 8.0
« Reply #9 on: July 01, 2016, 09:52:26 AM »
i probably should have
Code: [Select]
wget net-usb-4.4.14-piCore+.tcz into
Code: [Select]
/media/user/a02d2d78-3372-4a56-ad8a-4365dc452d37 
and 
Code: [Select]
sudo mount -o loop net-usb-4.4.14-piCore+.tcz into the appropriate directory.   // lost+found maybe?

tce gives me
Code: [Select]
root@user-VirtualBox:/media/user/a02d2d78-3372-4a56-ad8a-4365dc452d37/tce# ls
mydata.tgz  onboot.lst  ondemand  optional

at this point iḿ stuck.

Offline Paul_123

  • Administrator
  • Hero Member
  • *****
  • Posts: 1264
Re: setup usb - lan adapter on pi zero running piCore 8.0
« Reply #10 on: July 01, 2016, 10:26:13 AM »
Probably need to go back and read the core book and wiki.

But once the tcz is in the optional directory, just use tce-load -i <nameofextension.tcz>

And for boot purposes, add the extension name to onboot.lst

Offline bernie

  • Newbie
  • *
  • Posts: 15
Re: setup usb - lan adapter on pi zero running piCore 8.0
« Reply #11 on: July 02, 2016, 07:10:28 AM »
thank you Paul, I will go back and read the book/wiki.

I got it working, i have a internet connection, i still cant log in via ssh tc@. i probably have to configure something but don't know how, should be something obvious. but at lease i can connect via serial/ftdi and instal stuff.

what i did was, wget net-usb-4.4.14-piCore+.tcz (in VB Ubuntu)

then (over serial)
Code: [Select]
cd /etc/sysconfig/tcedir/optional
mv -v net-usb-4.4.14-piCore+.tcz /etc/sysconfig/tcedir/optional (it was already there but somehow nessesary).
cd /etc/sysconfig/tcedir
echo net-usb-4.4.14-piCore+.tcz >> onboot.lst
tce-load -i net-usb-4.4.14-piCore+.tcz

then, (i have no idee if this was necessary or why i did it?).
Code: [Select]
sudo depmod -a
then sudo reboot to see if it was installed at boot.

This was about it.


For my project i need for instance to tce-load -wi alsa-config.tcz, but i get an error on some of the .tcz i need to download.

Code: [Select]
Downloading: tce-load.tcz
Connecting to repo.tinycorelinux.net (89.22.99.37:80)
wget: server returned error: HTTP/1.1 404 Not Found
md5sum: tce-load.tcz.md5.txt: No such file or directory
Error on tce-load.tcz

other .tcz (alsa, nano etc.) download fine, why is this?

Thank you.







« Last Edit: July 02, 2016, 07:13:57 AM by bernie »

Offline sbp

  • Sr. Member
  • ****
  • Posts: 429
    • piCorePlayer homepage
Re: setup usb - lan adapter on pi zero running piCore 8.0
« Reply #12 on: July 02, 2016, 07:14:23 AM »
I think in version piCore8 you should install alsa-utils.tcz instead of alsa-config.tcz

Regards
Steen

Offline bernie

  • Newbie
  • *
  • Posts: 15
Re: setup usb - lan adapter on pi zero running piCore 8.0
« Reply #13 on: July 02, 2016, 07:46:05 AM »
thank you, Is there a way to find out what .tcz have been changed for 8.x?

these give me the error:

tce-load -wi alsa-config.tcz

compile-essentials.tcz

wiringpi.tcz

i dont see wiringpi.tcz and compile-essentials.tcz in the repo.

Offline patrikg

  • Wiki Author
  • Hero Member
  • *****
  • Posts: 722
Re: setup usb - lan adapter on pi zero running piCore 8.0
« Reply #14 on: July 02, 2016, 07:49:24 AM »
I know that compile-essentials.tcz has new name to compiletc.tcz.