WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: TCZ download, for later use?  (Read 3155 times)

Offline doctoranonymous

  • Newbie
  • *
  • Posts: 22
TCZ download, for later use?
« on: November 17, 2019, 04:08:32 PM »
Curious, as a newbie, if I can download a TCZ (extension) to a flash drive, and then install the TCZ, later, when I get home, onto the raspberry pi zero (no W; no internet at home; very 1980s!).

I am interested in minimal-linux (I just made that up; a portmanteau ; "minimalinux"), and your's is the minimal-est!

Offline doctoranonymous

  • Newbie
  • *
  • Posts: 22
Re: TCZ download, for later use?
« Reply #1 on: November 17, 2019, 04:24:07 PM »
Also, follow-up question(s):

(1) Have many pis (zeros, but always number # 1 in my book!)), and wish to boot five, sequentially, with the same piCore, uSD card. Do-able?

(2) Have--One Pi To Rule Them All, and in the Pi-ness Bind Them--running raspbian (buster), and don't know if i need serial/ethernet gadget mode? I think, just SSH will do it? (a) Make the raspbian-pi-zero generate key pairs; and then (b) make the piCore-five-pis ("clients") generate their key pairs, and then (c) put all the public key pairs on a flash drive and move over to Raspbian "server" and place in appropriate folder. Also, make sure each key has a nice unique name, and take notes, matching public key name to their IP address (note these too; by running ifconfig, and under eth0 heading, look at entry for "inet address", i.e. ipv4 address.).

(3) Oh wait; I just figured it out; the PiCore-five-pis (clients) must be ethernet gadget mode, in order to plug into the USB strip that the raspbian-pi-zero is in charge of, right?

(4) Can piCore make a raspberry-pi into an ethernet gadget? Raspbian can? Is it the same method as described on the raspbian page (namely cmd.txt and config.txt, "dt=overlay", etc. edits?)

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11590
Re: TCZ download, for later use?
« Reply #2 on: November 17, 2019, 04:29:11 PM »
Hi doctoranonymous
Curious, as a newbie, if I can download a TCZ (extension) to a flash drive, and then install the TCZ, later, when I get home, onto the raspberry pi zero (no W; no internet at home; very 1980s!). ...
Yes you can. You would also need to download all of its dependencies. There is a script for doing just that posted here:
http://forum.tinycorelinux.net/index.php/topic,23034.msg144013.html#msg144013
It was written to be able to run on any Linux machine.

Offline doctoranonymous

  • Newbie
  • *
  • Posts: 22
Re: TCZ download, for later use?
« Reply #3 on: November 17, 2019, 04:36:19 PM »
(5) for piCore desktop, I need the X server TCZ and the FLWM TCZ, right? Is that all? Maybe, once I figure out how to move TCZs by flash drive,  (TCZ = "Extensions" right? Is that what I should call them?), I can just move everything that sounds like "Xorg" and/or "FLMW".

(6) can I get "festival" the speech program on piCore? Or "Flite" the lightweight version? If not, how about an intro on alsa (?pulseaudio? and other associated programs? Sound, in Linux; I know it is "complex"?) and/or GSM? Just a hint or two, to get me started ...

(2: edit) I meant to say "copy all the public key pairs", as I must leave one copy of the public keys on the clients, and move one copy of public keys, via flash drive, to the appropariate folder on the "server".

(4: edit) Not raspbian website; the adafruit website... Heich-tee-tee-pee ://learn.adafruit.com/turning-your-raspberry-pi-zero-into-a-usb-gadget/overview

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11590
Re: TCZ download, for later use?
« Reply #4 on: November 17, 2019, 04:48:18 PM »
Hi doctoranonymous
(5) for piCore desktop, I need the X server TCZ and the FLWM TCZ, right? Is that all? Maybe, once I figure out how to move TCZs by flash drive,  (TCZ = "Extensions" right? Is that what I should call them?), I can just move everything that sounds like "Xorg" and/or "FLMW". ...
A list of available extensions for  TC9  ARMv6  can be found here:
http://tinycorelinux.net/9.x/armv6/tcz/info.lst
For a GUI, you probably want  TC.tcz:
http://tinycorelinux.net/9.x/armv6/tcz/TC.tcz.info

I recommend you take an hour to read this fine book:
http://tinycorelinux.net/corebook.pdf
While it was written for the x86 version of Tinycore, most of it also applies to ARM.

Offline doctoranonymous

  • Newbie
  • *
  • Posts: 22
Re: TCZ download, for later use?
« Reply #5 on: November 17, 2019, 04:59:20 PM »
Thanks , Rich

(5: edit) Heich-tee-tee-pee://learn.adafruit.com/turning-your-raspberry-pi-zero-into-a-usb-gadget/ethernet-gadget   (ethernet, is my goal, not serial)

Step 1.  Edit config.txt ; open file; Go to the bottom and add dtoverlay=dwc2 as the last line ; Save the config.txt file as plain text

Step 2.  Edit cmdline.txt;  open cmdline.txt ; After rootwait (the last word on the first line) add a space and then modules-load=dwc2,g_ether

(Don't have, my pi, or uSD cards with me, at the moment? Do they even HAVE these files? cmd.txt and cmdline.txt? I am almost certain that the pi NEEDS these files to function, regardless of which flavor of OS is used?. I guess i can check the tinycore-picore repository before I post a silly question like that? Wouldn't you know it, the answer is in my notebook, and I forgot that too! ).

(6) Thanks again Rich; we are "passing posts" ; Yup, I was thinking of trying piCore 11alpha etc. version, but I am on 9.0.3 version right now. Thanks; "TC.tcz" I think I knew that, or read that, but forgot ( I am a biologist, and a bit helpless, if it isn't hexadecimal!). Thanks for the book recommendation... BUT ... (Beware the "buts", as they always foreshadow some pretty wily opinions ...) ... as you said, it was written for x86, and I recall that it seemed very non-relevant to me. I can try reading it again, to see if some knowledge will accidentally rub off, but being as new as I am, and inexpert at x86, and inexpert at ARMv6 (or ARMvANYTHING?), it probably won't help much. Also, it is my understanding, due to GPU issues--and others,--and due to "not-entirely-open" hardware, despite being billed as such, that there are limited options in the initial bootstrapping, and thus, all OSes that want to deal with pi, have to do the first ten (or 50?) steps, pretty much identical? Am I mistaken in this notion? So, I sort of fail to see how the x86 book can help much? But, again, I am inexpert. (I know a fair amount about the 6502, but always at the nuts and bolts, transistor level; not at the OS level).

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11590
Re: TCZ download, for later use?
« Reply #6 on: November 17, 2019, 09:42:59 PM »
Hi doctoranonymous
You'll probably find  config.txt  and  cmdline.txt  in the first partition of your card. The pi unmounts that partition after it boots so
if you plan on using the pi to edit those files, you will need to mount it first.

There are a couple of readme files here:
http://tinycorelinux.net/9.x/armv6/releases/RPi/

This is at the end of one of them:
Quote
Core Book
=========

Also, strongly advised to read the Core book, "Into the Core":

http://tinycorelinux.net/book.html

It is about the x86 version in details, but generic parts, like
concept, tools, etc. valid for other ports, like piCore.

Enjoy!

Bela Markus (bmarkus)
That's from the creator piCore, so it's probably good advice.

Offline doctoranonymous

  • Newbie
  • *
  • Posts: 22
Re: TCZ download, for later use?
« Reply #7 on: November 23, 2019, 05:35:34 PM »
So,  I think I was missing a BIG part of this picture. Assignment of IP addresses (and routers). Since just want a "local network" or "cluster computer", then, I just wanted to "USB-everything-together", and then I think I want to SSH from "master pi" to the "client pis". Maybe not so easy?

I guess, in Raspbian, SSH will accept a name, and is not restricted to just an IP; "raspbian.local" seems to be the default name assigned.

But, I am not sure I need ethernet gadget mode; in fact, it could be detrimental to my plan. Can a pi-zero (server/maseter) power the other pi zeros (clients) through the second-USB(USB+data) port?

I have a power supply that has about 12 ports, each with more than enough amps to run a  pi zero, and any peripherals that might attach to the pi-zero.

So, let's assume I set aside the "ethernet-gadget mode" idea (from looking on the pages in this forum, it seems I would have to do some "figurin' " if I want to make this work on piCore!), and I power each pi independently (and cross my fingers there is no backfeed, anywhere? I am novice about EVERYTHING!). So, now, how do I network these things LOCALLY! Can I just plug them all into the "server-USB-hub"; and data will shunt around , no problem?

I have read some (alot! more than I want to!) about USB specifications, and I have a few books on the subject. Will the r-pi zero automatically configure itself as a device, and the host configure itself as host? I mean, the host has to run the bus, right? I think I will have to choose and alter the settings and/or software of the "host" and "devices"?

I suppose I could just (1) power-up and boot the raspbian server, (2) boot the picores (with one SD card, to share among all the "clients"; removing the card after each successful boot and using it to boot the next one), and (3) start plugging in the USB "data wires", from the data-port of the picore-clients into the USB-hub (data-port) of the raspbian-server. IS this "plug an play", haphazard, cross-your-fingers, approach wise?

Will this cause bus contention, or will the pis figure out "Who's the Boss"?

If this does work, how do I SSH? I guess, assuming it works, plugged in, as described above, I could just "ifconfig" and hope that a local IP was assigned? Or I could assign local IPs myself?

Offline doctoranonymous

  • Newbie
  • *
  • Posts: 22
Re: TCZ download, for later use?
« Reply #8 on: November 25, 2019, 09:45:06 AM »
OK, I guess I found an answer about static IP addresses. There are tons of pages and pointers and guides for raspberry pi OTG (ethernet or serial) mode, but fewer mentions of the USB Device(slave)/Host(master), dichotomy. I understand its essentially the same thing, but I like to read books, and the books on USB all refer to USB Device/Host.

haich-tee-tee-pee-esss  ://gist.github.com/gbaman/50b6cca61dd1c3f88f41

" g_ether .... . A far simplier was though is just to give the Raspberry Pi a fixed IP address. To do this, you will need to run echo -e "interface usb0 \nstatic ip_address=169.254.64.64" | sudo tee -a /etc/dhcpcd.conf. You can then access the Raspberry Pi Zero by connecting to 169.254.64.64, or by using raspberrypi.local if your computer has Bonjour installed (Mac and most Linux OSs including Raspbian). Note this method does not support adding a fixed address to the cmdline.txt file. For that, you have to use the Ethernet only kernel below. "

I think this will work.

I guess I should think about it this way; my "Raspbian machine" will have a dedicated SD card, and be the Host (always), and act as "server". (I think I should set a static IP for this one too?).

The Picore machines (about 5 QTY) will share an SD card, and boot up sequentially (ugggh, plug and unplug, in apish, simian, troglodytic fashion!),  and then I will assign static IP to them (I might have a tutorial or two on this? But what is the "right way" to install a static IP on a picore machine? Perhaps I'll rersearch a bit more!).

And so, once they all have static IPs, I can probably (a) power them all separately (through the USB power port) AND (b) hook the "data USB" to the "server hub" and let the "server" (i.e. USB Host) play master to them all? Right?