这是indexloc提供的服务,不要输入任何密码
Skip to content

Conversation

@mjarvisal
Copy link

Fixes issue #367

Bluetooth connectivity is accessible from long press context menu.

@Grimler91
Copy link
Member

Could you summarize a bit what this does?
From looking at the code I assume it allows for connecting/disconnecting to devices through menu.

Is there any particular reason why you choose to integrate it into the main app instead of into termux-api?

@mjarvisal
Copy link
Author

From the long press menu it opens the paired bluetooth devices. Once a bluetooth device has been selected it tries to open a bluetooth connection using SPP. This is useful with devices such as the Raspberry Pi 3 which can be setup to have a shell in the bluetooth RFCOMM socket.

It was necessary to integrate it to the main app because I wanted to be able to use the vt-100 terminal emulator. To my knowledge this is not possible from the termux-api.

This enables to use all the Linux cli applications over the Bluetooth connection because of the vt-100 terminal emulator can interpret the escape characters and display the shell environment correctly.

@Kaosxlinus
Copy link

Long press for bluetooth isn't working for me

@mjarvisal
Copy link
Author

@Kaosxlinus It does work, but this has not been merged with the master so it is no included in the Play Store version. If you want to use the Bluetooth functionality then you have to clone my repo and build it your self and then upload it via debug mode to your phone. Naturally you will then be using an older version of the Termux app from the time of my fork but with bluetooth.

@Kaosxlinus
Copy link

@mjarvisal Ah okay, my bad. Thank you

@DoomyDwyer
Copy link

DoomyDwyer commented Jan 13, 2019

HI @mjarvisal , it'd be great if you could let us know when this will be available on the playstore version. Thanks.

Blueterm just doesn't cut it. Termux rules! Bluetooth to Pi is handy when you're moving around and don't have Wifi set up yet where you are. W/o this functionality I'm bound to my laptop & puTTY to execute sudo raspi-config on the serial BT connection.

@DoomyDwyer
Copy link

Fork downloaded and Bluetooth branch built in Android Studio to create a signed APK.

I've installed this on my GT-I9505 running CM 12.1. (Uninstalled the Playstore release first).

Termux seems to be working as normal. I could even hit the context (i.e. menu) button quickly to bring up the context menu and connect to my Pi. This was all successful.

I'd usually only use Bluetooth before setting up Wifi wherever I am, so the next step for me is:

sudo raspi-config

After which Termux died ("Unfortunately, Termux has stopped"). Any ideas? If there are any logs you'd like to see, please let me know where to find them.

raspi-config is of course a menu-based application. Might this have something to do with the root cause?

Cheers

@DoomyDwyer
Copy link

HI @mjarvisal,

I've fixed the error on the Bluetooth Session. I'll e-mail you the details.

Cheers.

@DoomyDwyer
Copy link

      Could you summarize a bit what this does?

From looking at the code I assume it allows for connecting/disconnecting to devices through menu.
Is there any particular reason why you choose to integrate it into the main app instead of into termux-api?

Hi @Grimler91

If you can give us some pointers on how this should be added to termux-api, I'll see what I can do to refactor it out of the main app.

Cheers.

@Grimler91
Copy link
Member

Hi @DoomyDwyer,
I don't know much about android app-programming so @mjarvisal might very well be correct that it is not possible to implement this through termux-api (or as a new addon app) as far as I know.

We want to keep the permission list short for termux-app and let users that want these additional features install addon apps. If it isn't possible to implement it through an addon app then it this might not be merged unless a lot of users request it.

Still, really nice work by @mjarvisal.
It would be nice if you (@DoomyDwyer) could rebase this and fix the conflicting files to simplify for users that want to build the app with this feature on their own

@DoomyDwyer
Copy link

Hi @Grimler91,

I'll look into getting this done when I have a few free moments.

Cheers

@ZehCastro
Copy link

Seems like a nice feature. I would not mind the extra permissions needed.

@DoomyDwyer
Copy link

Seems like a nice feature. I would not mind the extra permissions needed.

I've packaged up a release for those who don't want to build it themselves in Android Studio: https://github.com/DoomyDwyer/termux-app/releases/tag/v0.59_bt

Please read the accompanying notes with the release.

@n3rd4i
Copy link

n3rd4i commented Mar 23, 2019

I've packaged up a release for those who don't want to build it themselves in Android Studio: https://github.com/DoomyDwyer/termux-app/releases/tag/v0.59_bt

Will then be possible to allow USB/BT access to third party apps inside termux like: noble ?

Ideally allowing even USB OTG BT dongles from the phone?

@DoomyDwyer
Copy link

I've packaged up a release for those who don't want to build it themselves in Android Studio: https://github.com/DoomyDwyer/termux-app/releases/tag/v0.59_bt

Will then be possible to allow USB/BT access to third party apps inside termux like: noble ?
Ideally allowing even USB OTG BT dongles from the phone?

No idea mate.

@parkerlreed
Copy link

Would be great if the device was opened as a device file (so I could use a program that expects serial)

@Mhowser
Copy link

Mhowser commented Aug 4, 2019

Any progress on this?

@fornwall
Copy link
Member

fornwall commented Aug 4, 2019

While interesting, this is a rather niche use case for only a few users which adds additional permissions.

Perhaps the best way forward would be to create something like a "Termux:Bluetooth" standalone application which could reuse the terminal handling from this app, just like the Termux:Float app does. Anyone interested in doing that or helping out with testing?

@DoomyDwyer
Copy link

While interesting, this is a rather niche use case for only a few users which adds additional permissions.
Perhaps the best way forward would be to create something like a "Termux:Bluetooth" standalone application which could reuse the terminal handling from this app, just like the Termux:Float app does. Anyone interested in doing that or helping out with testing?

I do plan to pick this up at some point, but am very busy with study at the moment, alongside working full-time, so I can't really commit to it until I'm further down the road with the study and have some free time on my hands. I'm even studying throughout the summer so it's really full on, I'm afraid.

In the meantime however, Termux v0.59 has been built by myself with the Bluetooth functionality added. The APK is available for download here:

https://github.com/DoomyDwyer/termux-app/releases/tag/v0.59_bt

Hopefully this should meet most people's needs and tide them over until something more permanent comes along.

@T-vK
Copy link

T-vK commented Apr 18, 2020

Has there been any progress on this? I'm very interested in having Bluetooth functionality in the official release.

@DoomyDwyer
Copy link

Has there been any progress on this? I'm very interested in having Bluetooth functionality in the official release.

I'll be finishing off my study in a couple of weeks - hope to spend some time on mobile development after that. Thanks for your patience everybody.

@T-vK
Copy link

T-vK commented Jul 21, 2020

Hey @DoomyDwyer, just wanted to ask if you've been able to find some time to work on this. :)

@agnostic-apollo agnostic-apollo force-pushed the master branch 4 times, most recently from 105a19a to b950efe Compare April 28, 2022 04:35
@MatejMagat305
Copy link

what is missing here?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.