WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: how to install bluetooth?  (Read 3020 times)

Offline gestein

  • Newbie
  • *
  • Posts: 16
how to install bluetooth?
« on: March 23, 2019, 03:34:04 PM »
Hi,

I am working with Tiny Core Linux because I do have piCorePlayer.
Currently I am using piCorePlayer v3.02 | linux 4.4.20-piCore+ | piCore v8.0.

Now I would need to install a bluetooth stick.
dmesg shows:
Code: [Select]
[    3.763283] usb 1-1.3: new full-speed USB device number 5 using dwc_otg
[    3.888449] usb 1-1.3: New USB device found, idVendor=0a12, idProduct=0001
[    3.888477] usb 1-1.3: New USB device strings: Mfr=0, Product=2, SerialNumber=0
[    3.888490] usb 1-1.3: Product: CSR8510 A10

I thought this should be quite easy, as piCorePlayer also has some kind of webinterface to install extensions.
But there is no bluez.tcz listed.

Could someone please give me a hint how to install this?

thanks a lot in advance and best regards
Gerhard

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11256
Re: how to install bluetooth?
« Reply #1 on: March 23, 2019, 07:20:46 PM »
Hi gestein
According to the piCorePlayer website, later versions do have Bluetooth support. Your best bet may be to update.

Offline gestein

  • Newbie
  • *
  • Posts: 16
Re: how to install bluetooth?
« Reply #2 on: March 24, 2019, 02:39:50 AM »
Hi Rich,

I see.
I wanted to follow “never touch a running system” as I also have installed some extensions.
But if there is no other easy way, I will have to update.

Thanks a lot
Gerhard

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11256
Re: how to install bluetooth?
« Reply #3 on: March 24, 2019, 05:53:41 AM »
Hi gestein
The alternative is creating one or more extensions. At the very least you need  bluetooth-KERNEL.tcz  for drivers for your
device, where the word  KERNEL  matches your kernel version. It doesn't exist in the TC8 v6 repo but should be relatively
straightforward to create.
Install  squashfs-tools.tcz
Download:
http://tinycorelinux.net/8.x/armv6/releases/RPi/src/kernel/4.4.20-piCore%2B_modules.tar.xz
Then execute these commands:
Code: [Select]
busybox tar xvf 4.4.20-piCore+_modules.tar.xz
mkdir -p package/usr/local/lib/modules/4.4.20-piCore+/kernel/drivers
mkdir -p package/usr/local/lib/modules/4.4.20-piCore+/kernel/net
cp -a modules/4.4.20-piCore+/kernel/drivers/bluetooth package/usr/local/lib/modules/4.4.20-piCore+/kernel/drivers
cp -a modules/4.4.20-piCore+/kernel/net/bluetooth package/usr/local/lib/modules/4.4.20-piCore+/kernel/net
mksquashfs package bluetooth-4.4.20-piCore+.tcz
rm -rf modules
rm -rf firmware
rm -rf package
Then copy the  bluetooth-4.4.20-piCore+.tcz  extension you just created to your  tce/optional/  directory and add a line that reads:
bluetooth-4.4.20-piCore+.tcz
to your  onboot.lst  file which is in your  tce  directory.

If you need other programs like  bluez  or  blueman , one option would be to compile them yourself. Those programs do exist
in the  http://tinycorelinux.net/8.x/armv7/tcz/info.lst  repository. Supposedly the  v7  programs are compiled to be binary compatible
with  v6  processors but I don't have any piCore systems so I really don't know.

Offline gestein

  • Newbie
  • *
  • Posts: 16
Re: how to install bluetooth?
« Reply #4 on: March 24, 2019, 01:23:24 PM »
Dear Rich,

incredible. I did it step by step and it seems to work.
At least I do have the following lines listed by dmesg:
Code: [Select]
[   40.959965] Bluetooth: Core ver 2.21
[   40.960096] NET: Registered protocol family 31
[   40.960110] Bluetooth: HCI device and connection manager initialized
[   40.960138] Bluetooth: HCI socket layer initialized
[   40.960162] Bluetooth: L2CAP socket layer initialized
[   40.960233] Bluetooth: SCO socket layer initialized

Now I will do some testing. Hopefully that's all I need.

Thanks again for helping me out of this.
Best regards
Gerhard

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11256
Re: how to install bluetooth?
« Reply #5 on: March 24, 2019, 02:07:06 PM »
Hi gestein
That certainly looks promising. I've never dealt with Bluetooth so I don't know what else is involved.

Offline gestein

  • Newbie
  • *
  • Posts: 16
Re: how to install bluetooth?
« Reply #6 on: March 24, 2019, 03:18:01 PM »
Hi,

unfortunately there is one more issue.
The programm I want to use is missing the tools "hciconfig" and "hcitool".
Only hcidump is installed through bluez-hcidump.tcz

I will try your suggested solution.
Best regards
Gerhard

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11256
Re: how to install bluetooth?
« Reply #7 on: March 24, 2019, 05:59:45 PM »
Hi gestein
... The programm I want to use is missing the tools "hciconfig" and "hcitool". ...
Those are provided by  bluez.tcz.  Near as I can tell from the compile script located with the source package here:
http://tinycorelinux.net/8.x/armv7/tcz/src/bluez/
It appears to use the same flags as armV6. Try downloading these into your  tce/optional directory:
http://tinycorelinux.net/8.x/armv7/tcz/bluez.tcz
http://tinycorelinux.net/8.x/armv7/tcz/bluez.tcz.dep
Add  bluez.tcz  to your  onboot.lst. To make sure the required dependencies are present, run:
Code: [Select]
tce-load -w dbus-glib.tcz libudev.tcz libical.tcz sbc.tcz readline.tczReboot and see if it works.

Offline gestein

  • Newbie
  • *
  • Posts: 16
Re: how to install bluetooth?
« Reply #8 on: March 25, 2019, 04:30:36 PM »
Dear Rich,

it seems you are complete right again.
I did this step by step and it obviously works.

Thanks a lot for your great support.
I already checked some functions of the tool that I need to run and found that I need another tool stdbuf.
This is located in coreutils.tcz

I also need 2 perl modules: YAML and Net::Server::Daemonize, which I installed via "sudo cpan -i XX".

Unfortunately after a reboot these installation is gone and I have to redo the installation of the 2 perl moduls.
So I need to have a look on how to make these perl modules persistant.

Thanks again for your help
Gerhard

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11256
Re: how to install bluetooth?
« Reply #9 on: March 25, 2019, 05:34:31 PM »
Hi gestein
IF the files are not too large and you know where they are located then backing them up is one option. For example, if YAML is
installed in:
Code: [Select]
/usr/local/lib/perl5/vendor_perl/5.14.1/YAMLthen add that (minus the leading slash) to your  /opt/.filetool.lst  file. Be aware there may (or may not) be additional files installed
in other directories.