WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: Where to build/install ADC module  (Read 28319 times)

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11630
Re: Where to build/install ADC module
« Reply #15 on: February 18, 2021, 09:21:42 PM »
Hi MTCAT
You are still trying to compile the old source package. That package is looking for  get_info  which was removed in
kernel 2.6.26. You are running 2.6.33. It doesn't have  get_info  so the old driver won't build on it.

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11630
Re: Where to build/install ADC module
« Reply #16 on: February 18, 2021, 09:43:23 PM »
Hi MTCAT
If you unpack the source package in your home directory, you won't need to use sudo for everything.

Offline MTCAT

  • Sr. Member
  • ****
  • Posts: 370
Re: Where to build/install ADC module
« Reply #17 on: February 19, 2021, 08:31:18 AM »
Hi Rich,

Oh, okay, sorry I didn't "clue in" to that, thanks for explaining that to me, I'll try building the newest driver (4.11) this afternoon then.

Explains why Slack12 (2.6.21.5) was able to build the driver at least (but still wasn't able to load the module due to CPU confusion I think).

Thanks,

David

Offline MTCAT

  • Sr. Member
  • ****
  • Posts: 370
Re: Where to build/install ADC module
« Reply #18 on: February 19, 2021, 04:42:49 PM »
Hi Rich,

I tried to install the new driver package (24dsi.linux.4.11.91.32.0.tar.gz) and unfortunately the behavior seems worse, immediately started spewing errors.

Attached a screenshot, "/bin/sh: stat: not found", over and over !

Is there perhaps another tinycore "package" that needs to be installed ?

Thanks,

David

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11630
Re: Where to build/install ADC module
« Reply #19 on: February 19, 2021, 04:48:38 PM »
Hi MTCAT
Install  coreutils.tcz.
« Last Edit: February 21, 2021, 10:08:00 PM by Rich »

Offline MTCAT

  • Sr. Member
  • ****
  • Posts: 370
Re: Where to build/install ADC module
« Reply #20 on: February 19, 2021, 05:15:46 PM »
Hi Rich,

Thanks, that did it ! ! !, awesome, thanks so much.

There's now a 24dsi.o (not .ko ??) module that's loaded, when I type "lsmod", whoop there it is, 24dsi !, sure took a long time to compile all the individual c programs though, seems a lot more complicated than the "old" driver, a lot of new functions available I suppose, I'm sure it will give my existing acquisition code fits...

With respect to the old driver, do you think a version of TinyCore with kernel 2.6.26 or older would be worth a try ? Would that be TinyCore2 ?

Or, maybe just grin and bear it and try to move forward with the new driver, I have no idea the horrors that may await trying to get the acquisition code to work with it though...

Thanks,

David

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11630
Re: Where to build/install ADC module
« Reply #21 on: February 19, 2021, 08:26:28 PM »
Hi MTCAT
... With respect to the old driver, do you think a version of TinyCore with kernel 2.6.26 or older would be worth a try ? ...
If you reread reply #15, that function was removed in 2.26.26. So you would need 2.6.25 or older.

Quote
... Would that be TinyCore2 ? ...
TC2 used kernel 2.6.29.
TC1 used kernel 2.6.26.
« Last Edit: February 21, 2021, 10:08:36 PM by Rich »

Offline MTCAT

  • Sr. Member
  • ****
  • Posts: 370
Re: Where to build/install ADC module
« Reply #22 on: February 20, 2021, 11:57:53 AM »
Hi Rich, thanks again so much, I have to make a journal here of all the steps you guys "walked me through" to get this to work ! I can post that too if you think it might help someone else ?

But then, I still need to save all the changes so I don't have to re-install all the packages every boot up, just reading up on the wiki-page on that, boot codes, etc. 

Sounds like, when installing packages, I can also use the "SET" option in the Installer to set the location of the package install, i.e., a hard drive, or in my case, a CF card, and then with a boot code, can load all those packages on every boot up, is that the basic idea ?

I guess I'll probably stick with the new driver and move forward with that, one advantage of the new driver is that I should also be able to use a newer version of TinyCore if I want too, I don't know if there would be any advantages though ?, I don't have a problem with TinyCore3, looks like it will do everything I need, so, not sure, I always would like to keep things as simple as possible....

The next (last ?) step will be getting the acquisition code running, hopefully that will be possible.

Thanks again for all your help !

Offline MTCAT

  • Sr. Member
  • ****
  • Posts: 370
Re: Where to build/install ADC module
« Reply #23 on: February 21, 2021, 01:45:01 PM »
Hi Rich,

For my own notes and education, can you tell me why the command below is needed to install the ADC driver ?

tce-load -wi compiletc perl5 bash ncursesw-dev bc-1.06.94 glibc_apps elfutils-dev

I do know that "compiletc" installs gcc of course.

Are Perl5 and Bash also needed just to be able to execute the commands in the ADC "makefile" ? Scripting commands, almost like a batch file dare I say ? My programming experience to date has been very crude (Fortran77/90) in the sense of just compiling single programs at the command line, or compiling a few programs separately, and then just linking the few object files manually, I've never made my own "Makefile" before, so I'm new to Makefiles in general.

What about these guys ?

ncursesw-dev - for reading "wide" characters, Unicode, not even sure what that is.

bc - command line calculator I think ?

glibc_apps - extra C functionality ?

elfutils-dev - to be able to read ELF binary files, whatever that is ?

Thanks so much.

David

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11630
Re: Where to build/install ADC module
« Reply #24 on: February 21, 2021, 10:21:12 PM »
Hi MTCAT
For my own notes and education, can you tell me why the command below is needed to install the ADC driver ?

tce-load -wi compiletc perl5 bash ncursesw-dev bc-1.06.94 glibc_apps elfutils-dev ...
It's not. It's needed to compile the driver. I don't know that you need all of them. This is the list of extensions required
to compile a kernel, so I used it as a starting point.

Offline MTCAT

  • Sr. Member
  • ****
  • Posts: 370
Re: Where to build/install ADC module
« Reply #25 on: February 23, 2021, 03:15:11 PM »
Hi Rich,

Oh, okay, better to have more packages than less I suppose, play it safe type of thing.

Thanks for letting me know.

Cheers,

David

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11630
Re: Where to build/install ADC module
« Reply #26 on: February 28, 2021, 09:21:55 PM »
Hi MTCAT
In your thread  Persistence Question  the topic of creating an extension came up. An extension is really a read only
file system.

So first set up the directory structure:
Code: [Select]
mkdir -p package/usr/local/lib/modules/2.6.33-tinycore/kernel/drivers/dsi
Next copy the library and driver into that directory structure:
Code: [Select]
cp 24dsi.linux.4.11.91.32.0/24dsi/lib/lib24dsi_api.so package/usr/local/lib/
cp 24dsi.linux.4.11.91.32.0/24dsi/driver/24dsi.ko package/usr/local/lib/modules/2.6.33-tinycore/kernel/drivers/dsi/

Finally, create the extension:
Code: [Select]
tce-load -iw squashfs-tools
mksquashfs package 24dsi-2.6.33-tinycore.tcz

Leave the  2.6.33-tinycore  in the extension name because it indicates which kernel version it will work with.

Offline MTCAT

  • Sr. Member
  • ****
  • Posts: 370
Re: Where to build/install ADC module
« Reply #27 on: February 28, 2021, 10:26:17 PM »
Hi Rich,

Thanks for the help, I've been reading up on this, making an extension with a binary source, your directions are great !, thank you. I've become generally aware of replicating the directory structure and using squashfs to make the extension, but I wasn't sure, I was going to copy the entire /usr/src/linux/drivers/24dsi/... into the extension ! Would have been a lot bigger than necessary !

And then, lastly, does the new .tcz file needs to be added to onboot.lst ?

I've been meaning to ask you though, this weekend I've noticed in TC3.8.4, quite often (50 % of the time maybe ?), TC3.8.4 doesn't seem to "see" the PCI bridge on the ADC card.

Specifically, typing "lspci -v" doesn't always return me with a "PLX Technology PCI9080..." at the bottom of the list, or anywhere in the list, it's just not there...yet in TC3, although I had to download and install pciutils every time, it always worked, I was always able to "see" the PCI bridge.

Any ideas what might be causing the oddness with "lspci -v" with TC3.8.4 ?? I do also occasionally see an odd error message at the SYSLINUX level of booting up TC3.8.4, something to do with a memory problem as relates to a PCI device, I need to try to capture this on my phone maybe (burst photo's) during boot. I don't see that boot-up error message all that often, however, even when I do, "lspci -v" still may work fine, so not sure if these two things are related or not.

I wasn't sure if maybe uninstalling and re-installing pciutils would be needed , but I wasn't sure how to uninstall an extension either. I hope it's not a hardware issue, the card is quite expensive !

Thanks,

David

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11630
Re: Where to build/install ADC module
« Reply #28 on: February 28, 2021, 11:06:06 PM »
Hi MTCAT
... And then, lastly, does the new .tcz file needs to be added to onboot.lst ? ...
Yes, copy the extension to your  tce/optional  directory and add  24dsi-2.6.33-tinycore.tcz  to your  onboot.lst  file.

Quote
... something to do with a memory problem as relates to a PCI device, I need to try to capture this on my phone maybe (burst photo's) during boot. ...
Please, no pictures. Does this return the error message you saw:
Code: [Select]
dmesg | grep -i pci
Or you can look through the kernel messages:
Code: [Select]
dmesg | less -INavigate with arrow keys and  Page Up/Down  keys.

Or you can save the messages to a file:
Code: [Select]
dmesg > dmesg.txt
Quote
... I wasn't sure if maybe uninstalling and re-installing pciutils would be needed  ...
No, that won't change anything. You could see if updating PCI database helps:
http://repo.tinycorelinux.net/4.x/x86/tcz/pci-utils.tcz.info

You might also want to read this one to make sure you find the correct file or files to back up:
http://repo.tinycorelinux.net/10.x/x86/tcz/pci-utils.tcz.info

Offline MTCAT

  • Sr. Member
  • ****
  • Posts: 370
Re: Where to build/install ADC module
« Reply #29 on: March 01, 2021, 08:43:31 AM »
Thanks Rich, over the next couple of days, I'll try to build the extension, and install it, and if that error message comes up, I'll see if I can isolate it in a text file as you've instructed.

Thanks so much,

David