Terminal access via ssh - Nexus 4 Q&A, Help & Troubleshooting

I am thinking of getting a Nexus 4 (or a Nexus 5 if such a thing appears in the not too distant future) as my first smartphone, with the eventual possibility of running Ubuntu for Android if and when it becomes available. However, for now the only capability I need the phone for is to be able to open up a Linux style command line terminal on the phone where I can ssh into a couple of other Linux based devices I have, via wifi, so I can run some "C" executables that I have written on these other devices. These other devices are running SSH servers. Is this doable? Do I need a special app or a special ROM, etc.

I assume you mean to run the C executable on the remote machine... not the phone itself?
If yes, then: YES, you can do that. And there are many ways to do it.
At the most basic, the only app that you would need is a Terminal Emulator app (several terminal apps are available for free... some are better than others). From that, you can do what you want. Any of the good ones will work just like any other Terminal on a PC.
But there are other apps that will make it easier because typing out commands, on a phone, isn't the funnest thing ever. Copy-pasting commands is an obvious way to make it easier...
But there are even easier ways than that...
ConnectBot (ssh-agent-patch) app would allow you to ssh into a remote host with a single tap (even using public-private key authentication if you want). Then you can run your ./command (or copy-paste it).
You can even VNC into a remote host and control it graphically (assuming a VNC server is running on the host machine).
You can even go the other way too... you can run an ssh server on the phone and access it from your PC.
Like all ssh capabilities, all of this can be done over the internet too, you aren't limited to WiFi LAN.
Also, on all of my file explorers (on all of my computers AND my Phones) I've made shortcuts for easy file sharing too (all using pub/private key authentication for security). Not only does that make file transfers super easy no matter what machine I have my hands on at the moment, but it also makes my desktop PC at home my own personal cloud server to my phone. Who needs dropbox?
Basically anything you can do with ssh on a computer, it can be done on an Android phone.
ps... if you re-compiled your C executables for the Android system... you could even run them natively on the phone.

iowabeakster said:
I assume you mean to run the C executable on the remote machine... not the phone itself?
Click to expand...
Click to collapse
Yes.
Fantastic, thanks for the detailed answer. I wanted to know right away before I wasted my time, but now am googling around for all the details. I have a raspberry pi running Debian that I need to communicate with and it is headless (No monitor, keyboard, etc., just a wifi dongle) so this would be perfect. I also have desktop computers that run a bunch of OS's (Centos, Scientific Linux, Fedora, Ubuntu, etc) that I might want to connect to.
From what I understand, all of that can be done without modifying the phone (rooting, etc.), correct?
However, down the road I may want to try and root it anyway, because the bigger set of Linux commands offered by Busybox would nice. I have been putting off getting a smartphone because of the cost, but the Nexus 4 with something like straight talk is the same monthly price as my 400 minutes of just talk with Verizon, so it is time. The coverage and uptime with Verizon is really good, but the costs are just not keeping up with the times.

From what I understand, all of that can be done without modifying the phone (rooting, etc.), correct?
Click to expand...
Click to collapse
good question.
I don't know with absolute certainty what functions would require root (I always root right away... so I don't ever think about it... like you said... additional functions... and I forget about it).
Basic, ssh-client functions should not require root. Running the ssh-server on the phone, that I mentioned, certainly does require root though. I know that my Terminal Emulator and File explorer apps have root access, but root is not needed just for the ssh-client functions (I am pretty sure).
Rooting on the nexus 4 is pretty easy. Rooting does require the installation of a custom recovery (at least temporarily). That is something that sounds like it would take someone like a you only a few minutes to do (not counting the time you would likely spend reading about it before hand... and installing the android sdk on a PC). Certainly, no other mods other than rooting would be needed.

iowabeakster said:
good question.
I don't know with absolute certainty what functions would require root (I always root right away... so I don't ever think about it... like you said... additional functions... and I forget about it).
Click to expand...
Click to collapse
Great, I will probably just root the phone after using the phone for a while; I have zero experience with smartphones, plus I want to make sure that the phone works properly. The important thing is that it will do exactly what I need it for.
Last question. I see there are several guides for rooting and unlocking the bootloader.....Any recommendation of which one to use? I see that the one written by Jubakuba "Ultimate Nexus Root Guide" has pointers to urls that are broken (Therefore many critical steps are missing), and apparently it has been that way for quite a while.

I started looking for what I thought the best guide... but I gotta do some stuff... I will be back in a couple hours (hopefully with a good suggestion).
I will piece together a guide tomorrow morning from all the various "how-to" guides out there for you. So many of them are geared towards Windows users, and they start babbling about installing and removing drivers and stuff that you won't bother with in Linux. But I need sleep, right now. It'll just be some copying and pasting from a few of them out there. It shouldn't take long.

iowabeakster said:
I started looking for what I thought the best guide... but I gotta do some stuff... I will be back in a couple hours (hopefully with a good suggestion).
I will piece together a guide tomorrow morning from all the various "how-to" guides out there for you. So many of them are geared towards Windows users, and they start babbling about installing and removing drivers and stuff that you won't bother with in Linux. But I need sleep, right now. It'll just be some copying and pasting from a few of them out there. It shouldn't take long.
Click to expand...
Click to collapse
It's not necessary to go through all of that; I thought there was maybe one document that a lot of people were using. It is really up to me to start reading up on the subject.

Just bit the bullet and placed an order for the Nexus 4 before it is out of stock again.
Found some simple instructions for unlocking and rooting the Nexus 4:
http://forums.androidcentral.com/nexus-4-rooting-roms-hacks/224861-guide-nexus-4-unlock-root.html
Also found better descriptions of what the various terms floating around mean and what each piece of software does, however it is on the Galaxy S III section of this forum, so obviously I am not going to follow any of the procedures listed:
http://forum.xda-developers.com/showthread.php?t=1927113

Here's my favorite instructional...
http://forum.xda-developers.com/showthread.php?p=37823933#post37823933

iowabeakster said:
Since googling around to find a good "How to" for Android noobs, I kind of felt like I could maybe help a few other folks out there too So, I went ahead and made my own "How to".
Click to expand...
Click to collapse
Nice.

I just ran across this, and thought about you... looks like a nice new SSH client. I've never used it. But Jerry at Android Central is a pretty serious Linux nerd, so I do put some stock in his recommendations. Just thought I'd throw it out there for you to see.
http://www.androidcentral.com/apps-week-juicessh-7x7-audible-android-and-more

iowabeakster said:
I just ran across this, and thought about you... looks like a nice new SSH client. I've never used it. But Jerry at Android Central is a pretty serious Linux nerd, so I do put some stock in his recommendations. Just thought I'd throw it out there for you to see.
http://www.androidcentral.com/apps-week-juicessh-7x7-audible-android-and-more
Click to expand...
Click to collapse
Well, I had the phone for a couple of weeks and I think I turned it on twice. I really didn't get addicted and start to install apps until I used the GPS feature for a long trip I took yesterday. First time using a GPS....Yeah, just a little behind the times.
So, without rooting, today I installed the following apps which gives me everything I need:
ConnectBot. Works great and allows me to ssh to my Linux boxes.
Terminal Emulator. For basic command access.
FreebVNC. Has a secure tunnel feature built in, so you don't have to go through the whole two step process of setting up a tunnel and then running VNC through the tunnel. Also, it has a zoom feature, access to special keys and mouse emulation.
Wifi Analyzer. Gives you access points, signal strength, etc. There was another app that I added to that app to easily connect to the access points.
Fing. Network Info like mac addresses, etc.
Still will root eventually and install Busybox. However, now that I can access my raspberry pi remotely, my priority is to finish writing my software programs and building electronics for a project that uses that little ARM computer.

pjc123 said:
I am thinking of getting a Nexus 4 (or a Nexus 5 if such a thing appears in the not too distant future) as my first smartphone, with the eventual possibility of running Ubuntu for Android if and when it becomes available. However, for now the only capability I need the phone for is to be able to open up a Linux style command line terminal on the phone where I can ssh into a couple of other Linux based devices I have, via wifi, so I can run some "C" executables that I have written on these other devices. These other devices are running SSH servers. Is this doable? Do I need a special app or a special ROM, etc.
Click to expand...
Click to collapse
For a ssh client, try ConnectBot. I have been using this since the G1 came out for work (Sys Admin) and home.
For a better keyboard, check out Hacker's Keyboard.

SpookyTunes said:
For a ssh client, try ConnectBot. I have been using this since the G1 came out for work (Sys Admin) and home.
For a better keyboard, check out Hacker's Keyboard.
Click to expand...
Click to collapse
As mentioned above, I already installed ConnectBot and it has nice features. However, I am interested in the keyboard (keys in the right place, Crtrl/Tab/Esc keys, etc.), so I will be installing that next.

Yep, ConnectBot is the old standard (if there is such a thing in Android world). I use it.
I've pretty much always used Jack Palevich's Terminal Emulator app. Very small and lightweight. It's always done everything I've ever needed to do. But there are many Terminal apps to choose from. I usually stop trying apps, when I find one that meets my needs, and stick with it until it doesn't... I started using that Terminal my first week with my first Android, after trying a couple of others. I've never used anything since.
Hacker's keyboard is an awesome suggestion! Thanks man! How have I survived without this!
For VNC purposes (which I rarely use) I use androidVNC. I've never tried anything else since I use it so rarely. It seems to do everything I can imagine it should. Mostly I use it to mess with my wife's head with some "ghost in the shell" pranks when she is using her laptop. She will scream from the living room, "WTF!!!! My computer just told me it's going to eat my brains tonight!"
And I'm just innocently sitting there reading emails on my phone "That is strange, honey."

iowabeakster said:
For VNC purposes I use androidVNC.
Click to expand...
Click to collapse
I actually looked at androidVNC first due to the amount of reviews and positive ones, but I liked the extra features of FreebVNC even though it violates my following policy. I have found, just like shopping at Amazon, that in general the quantity and quality of reviews quickly narrows the search dramatically from the huge database of products/apps. The only side effect of this is to weed out excellent apps that are new and could be excellent, but just like major operating system updates, with anything new I let them weed out the bugs first.
iowabeakster said:
I've never tried anything else since I use it so rarely.
Click to expand...
Click to collapse
I totally agree with you that I don't ever see myself using the VNC client on the smartphone again other than just as a novelty. What does intrigue me is putting a VNC server on the smartphone. I wonder if there would be a way to use an external computer's mouse and keyboard to control the gui portion of the smartphone while displaying it on the computer's large screen, the problem being that the smartphone is touch based; that is something that I could see using.
iowabeakster said:
I use it to mess with my wife's head with some "ghost in the shell" pranks.
Click to expand...
Click to collapse
Me and a friend used to do similar pranks at work, messing each others displays, keyboards, etc. I think the best non-computer prank that someone did to me while I was on vacation was to line one of my desk drawers with plastic and fill it full of goldfish. The best prank that some colleagues did, was to inflate a weather balloon in our departmental director's office and turn the nozzle away from the door so he couldn't get in.

Related

ROM for juniors?

Hi,
I got a few spare androids' and i'm considering giving them to my kids (11 and 12) to play around with it and enjoy the android experience. however I don't want them being able to put 3rd party applications. how do i go about removing the option of "unknown sources" and maybe wifi from the settings.apk.
I'm not new to java and xml but sort of new to android development, I've tried several ways to remove it from the apk only (ark, ddx, baksmali, apksign) I did it in so many ways that i can't remember them all. I've also tried to decode the apk with apktool, ddx, baksmali, and creating a new project from existing source in eclipse, and I couldn't figure out what parts I have to modify to get it working (i kept on getting errors in eclipse so i wasn't even able to compile and test it in DDMS-eclipse).
Also i would like to know if maybe it is necessary to port the whole kernel source into eclipse?
I've searched all over the internet for a information for this specific thing and I couldn't find anything.
Btw, I'm using nix lucid.
Thanks In advance.
any help would be appreciated!
how about flash the supere rom without the google apps? that way they wont be able to access the market..
lagu805 said:
how about flash the supere rom without the google apps? that way they wont be able to access the market..
Click to expand...
Click to collapse
I know, the problem is not the market, i can pull it out from the phone with adb in a second w/o superE, but they can still install stuff on it with a sd card, and I would hate to not put in a file browser on the phone.
I think it would be a good idea to make a rom that's made for kids, for playing games and stuff without me worrying about it.
I'm sure that they will try to figure out a way to get around the "no market on the phone" and I should not underestimate a kid (even a 12 year old). I've seen him getting around lots of technological obstacle's.
I think that the world could use a kid's version of android, you know, get them hooked when they're young. The last thing i would like to hear from my kids is talking about iPhone or Windows. We're all linux in our house
Interesting. I too gave Magics to my 11 & 12 yr olds, one without a data plan and the other without a SIM at all. I think the right way might be multiuser like we already do on the desktops. Sudo would be a nice touch but I'd be happy to login as admin to install or whatnot.
Multiuser is something I'd like to see anyway with most or some settings on a per user basis. Or at least just for security, normal login can't do critical tasks that might cause issues. I think we'll hear about this again once we hear about some seriously dangerous apps/scams/viri on the phones.
In the meantime your best bet is education and rules about what can and can't be done. Then once per week or so you take the phone and check things out, update as needed, etc. So far my kids have little interest in breaking the rules and are happy browsing the market for fun things.
I think the only way to achieve this is to download the AOSP, edit the sources to remove the options and then compile your own ROM.
3rdcoast said:
Interesting. I too gave Magics to my 11 & 12 yr olds, one without a data plan and the other without a SIM at all. I think the right way might be multiuser like we already do on the desktops. Sudo would be a nice touch but I'd be happy to login as admin to install or whatnot.
Multiuser is something I'd like to see anyway with most or some settings on a per user basis. Or at least just for security, normal login can't do critical tasks that might cause issues. I think we'll hear about this again once we hear about some seriously dangerous apps/scams/viri on the phones.
In the meantime your best bet is education and rules about what can and can't be done. Then once per week or so you take the phone and check things out, update as needed, etc. So far my kids have little interest in breaking the rules and are happy browsing the market for fun things.
Click to expand...
Click to collapse
well, it is just a nix and SUDO should be possible, but setting this up is a quite a project and I don't think this is a one day project.
As for educating, I think they know right from wrong and I don't think that they will willingly break the rules, the market however is full of apps that are not meant for young kids..... what do you think they're going to do when they bump in to one of those apps? .
Actually what i wanted to do is to give them a phone with a line and no data plan so they can play games or watch movies, If the kids want to use the internet, there are more than enough boxes at home they can use. This phone is strictly for voice text and games.
What I want to accomplish in general, is having a child safe phone, and have the other parents here who want their kids to have to have an android, enjoy it. My way of giving back to the community.
But to have a phone that will be suitable for the purpose (not just for my kids) the data has to be completely disabled, and wifi is going to be the issue. putting on an encryption on wifi is a joke, ever heard of aircrack? I'm sure there are lots of determined horny 15 year olds that will get around that. (am i paranoid?)
Case_ said:
I think the only way to achieve this is to download the AOSP, edit the sources to remove the options and then compile your own ROM.
Click to expand...
Click to collapse
That's exactly what i want to do. The question is how do I do it?
Again, I'm not a complete noob, I just never played around with android as an OS. so if I can have the first push here here what I'm supposed to do to start this I would really appreciate it.
As I've said in my first post, I tried a few things and i couldn't get it right. what part of this don't i get??
Thanks a lot.
well your not even going in the right direction..
do you have an IDE with compiler and the android SDK all set up? then you can check on dferrera post on how to compile android from source... its listed in this forum.. please search
if your not a programmer or have no idea what classes - functions etc are then this might now be an option for you that is something you can be instructed on
you are going to need to learn to compile android from source and modify it, this is a very big task mate - be prepared, and no one can answer all the questions for u
alan090 said:
well your not even going in the right direction..
do you have an IDE with compiler and the android SDK all set up? then you can check on dferrera post on how to compile android from source... its listed in this forum.. please search
if your not a programmer or have no idea what classes - functions etc are then this might now be an option for you that is something you can be instructed on
you are going to need to learn to compile android from source and modify it, this is a very big task mate - be prepared, and no one can answer all the questions for u
Click to expand...
Click to collapse
Thanks for the reply, but i can't seem to get java5 working on 10.04 (the 10.04 repos have only java6 but i did add the old repos and ran in to some issues), I had it working on 9.04 though. anyone made it run on 10.04? or should I downgrade (or run it in VB) to 9.04/.10?
k50aker said:
Thanks for the reply, but i can't seem to get java5 working on 10.04 (the 10.04 repos have only java6 but i did add the old repos and ran in to some issues), I had it working on 9.04 though. anyone made it run on 10.04? or should I downgrade (or run it in VB) to 9.04/.10?
Click to expand...
Click to collapse
Add these 2 lines to the end of /etc/apt/sources.list file
Code:
deb http://pl.archive.ubuntu.com/ubuntu/ jaunty multiverse
deb http://pl.archive.ubuntu.com/ubuntu/ jaunty universe
then do:
Code:
sudo apt-get update
sudo apt-get install sun-java5-jdk
@k50aker
Hiding Wifi and other things should be quite easy task, but... how do you want to protect against system reinstallation? They could download any ROM from internet and install it in just 10 minutes. Backuping is easy too, so they could have 2 systems installed and switch between them when their dad comes home.
Android phones aren't desktops. You can't have root and don't give it to other users of a device.
Mod. edit: not dev related, moved to general
I wouldn't want to hide WiFI, the device is useless without connectivity, much cheaper toys out there for that if I wanted stand alone.
My two children each have a Magic and this is my experience, none of the worries that many parents seem to fear. They are well behaved and so far no problems and they are ready for 2.1 since 1.5 is just too confining even for them. Education goes a long way.
The best choice I made was to not put a SIM in one of the phones. WiFI is ideal since she is nearly always in a zone. This has gotten her used to IM instead of texting. Same effect but costs nothing. A SIP app works almost as well as SIM voice. Someday I'll do a data only SIM so she has total coverage, she'll understand that heavy data is to be done over WiFI and cell data is for VoIP and for times when it is really needed and can't wait.
However it would be nice if there was a limited setting requiring admin password for certain functions. But really, there hasn't been any problems but my kids might be grateful enough to not abuse the rights I give them. Best advice besides education if they are very young is to not SIM until after they get into the alternatives and not be addicted to texting. The older one has learned to watch her usage patterns and has to pay if she goes over budget.
Switch33 said:
Add these 2 lines to the end of /etc/apt/sources.list file
Code:
deb http://pl.archive.ubuntu.com/ubuntu/ jaunty multiverse
deb http://pl.archive.ubuntu.com/ubuntu/ jaunty universe
then do:
Code:
sudo apt-get update
sudo apt-get install sun-java5-jdk
Click to expand...
Click to collapse
those ropes are for jaunty not for lucid, and I have tried that before anyway and this is what i get:
Code:
desktop:~$ sudo apt-get install sun-java5-jdk
Reading package lists... Done
Building dependency tree
Reading state information... Done
sun-java5-jdk is already the newest version.
The following packages were automatically installed and are no longer required:
libwv2-4
Use 'apt-get autoremove' to remove them.
0 upgraded, 0 newly installed, 0 to remove and 11 not upgraded.
1 not fully installed or removed.
After this operation, 0B of additional disk space will be used.
Setting up sun-java5-doc (1.5.0-19-0ubuntu0.9.04) ...
This package is an installer package, it does not actually contain the
J2SDK documentation. You will need to go download one of the
archives:
jdk-1_5_0-doc.zip jdk-1_5_0-doc-ja.zip
(choose the non-update version if this is the first installation).
Please visit
http://java.sun.com/j2se/1.5.0/download.html
now and download. The file should be owned by root.root and be copied
to /tmp.
[Press RETURN to try again, 'no' + RETURN to abort] no
Abort installation of J2SDK documentation
dpkg: error processing sun-java5-doc (--configure):
subprocess installed post-installation script returned error exit status 1
Errors were encountered while processing:
sun-java5-doc
E: Sub-process /usr/bin/dpkg returned an error code (1)
Brut.all said:
@k50aker
Hiding Wifi and other things should be quite easy task, but... how do you want to protect against system reinstallation? They could download any ROM from internet and install it in just 10 minutes. Backuping is easy too, so they could have 2 systems installed and switch between them when their dad comes home.
Android phones aren't desktops. You can't have root and don't give it to other users of a device.
Click to expand...
Click to collapse
You are right, but one of the later steps I thought about would be a custom boot and custom or no recovery. But I will figure that out later in the project.
But i will probably change my direction on this (wifi etc.) based on what you guys say.

Linux?

Is ubuntu possible on our u8800?
http://www.youtube.com/watch?v=xN4c61ETCWg maybe, try it
Without having seen the youtube vid that d3xtr0 linked, I'll post this link:
http://androlinux.com/android-ubuntu-development/how-to-install-ubuntu-on-android/
sebgus said:
Without having seen the youtube vid that d3xtr0 linked, I'll post this link:
http://androlinux.com/android-ubuntu-development/how-to-install-ubuntu-on-android/
Click to expand...
Click to collapse
lit's the same source
It will probably work if this device supports "loop devices" whatever that is? anyone know or tried it succsessfully?
skifyr123 said:
It will probably work if this device supports "loop devices" whatever that is? anyone know or tried it succsessfully?
Click to expand...
Click to collapse
I had no time to try it, maybe later in the week.
skifyr123 said:
It will probably work if this device supports "loop devices" whatever that is? anyone know or tried it succsessfully?
Click to expand...
Click to collapse
It supports loop device. I just tried to mount a loop device with a loop image and it worked.
EDIT: With flibblesan's r5 kernel but it should be supported by stock kernel anyway
You are aware that ubuntu has no proper support for touchscreens; even if it runs you won't gain anything by doing that. When I installed a linux a few months ago on another device it worked, then I was fascinated about one minute and then I decided that there is no use for it an deleted it eventually.
I just do not understand why it is so important to get a desktop-os running on a smartphone. Battery drains fast, no support for the radio etc.
XphX said:
You are aware that ubuntu has no proper support for touchscreens; even if it runs you won't gain anything by doing that. When I installed a linux a few months ago on another device it worked, then I was fascinated about one minute and then I decided that there is no use for it an deleted it eventually.
I just do not understand why it is so important to get a desktop-os running on a smartphone. Battery drains fast, no support for the radio etc.
Click to expand...
Click to collapse
Its not important, but funny and cool if it works (on this device). How did you do it?
Until recently I still had my old samsung-omnia-winmo6.5-phone. There was an app for linux available; you just had to install an imagefile to the sd-card. The fun did last for a minute and then I realized I cannot do anything with this small screen and that it was pretty much useless.
I think that a lot of people here will just read the topic and think "omg this is amazing, now I can have my desktop-os on the phone, great" and later they realize how much time they just wasted.
If it really is fun for you guys, I won't try and stop you
How about using linux programs? i think that it may be quite useful sometimes... Put honestly... it is just for funright now... but it may be helpful if we could dual boot.... maybe in the future
I got this working, it isn't that slow as you could imagine, firefox takes around 30 sec to start and load the front page. That said, the keyboard works but is way off and impossible to use (I push "d" and "f" shows up and so on).
if anyone understand this the keyboard will be fixed:
In VNC’s xstartup file: $HOME/.vnc/xstartup
You have to add the line export XKL_XMODMAP_DISABLE=1 before
/etc/X11/Xsession or gnome-session (in case you use GNOME)
Screenshot actually taken with an ubuntu tool, I have set the resolution to 1200*800 in the virtual enviriment.
Here is a video with Huawei Ideos X5 running Ubuntu: http://www.youtube.com/watch?v=8SaoneDtNqA&feature=BFp&list=WL01C152CD7D31A7C8&index=1
Will try this later tonight and let you guys know if it works. Just have to work first >.<
The significance of linux running is to have a backup operating system to use on the phone if the Oracle / Google dispute over Java begins to really disrupt the market.
Think also freedombox.org, your own personal, secure and anonymous cloud system as a refuge if a dictatorship emerges or particularly nasty rise of corporatism occurs.
At heart, our U8800's can easily be linux box server with up to 32Gb of onboard storage with wi-fi AND gsm network connections. Being battery operated, if the thought police decend upon your community, you could take it to another place, unknown to the nasty guys, and re-establish mesh network connection to get reports of civil rights abuses out to the rest of the world.
Reason enough to have the capability to run Ubuntu Server edition (or any other Linux Server flavour)?
If you're interested to see what's already possible, even within Android (Linux will deliver more power), install "File Expert" from the market to get your very own web file server, right there in your phone.
-- wrong post just ignore --
XphX said:
Until recently I still had my old samsung-omnia-winmo6.5-phone. There was an app for linux available; you just had to install an imagefile to the sd-card. The fun did last for a minute and then I realized I cannot do anything with this small screen and that it was pretty much useless.
I think that a lot of people here will just read the topic and think "omg this is amazing, now I can have my desktop-os on the phone, great" and later they realize how much time they just wasted.
If it really is fun for you guys, I won't try and stop you
Click to expand...
Click to collapse
You didn't Found a better ubuntu boot-file, x5 faster, keyboard works, WIFI, pre-installed with many programs ( Open Office for work.. etc) easy to use with touch screen. here is how it works: http://www.youtube.com/watch?v=KUG9aC_tH5s
And the files/instructions: http://forum.xda-developers.com/showthread.php?t=962023

[App] Proposal - Android TV web console

I just got a Shield TV, and I love it. I'm probably going to root it tonight to tinker further.
One issue I have with it is how annoying it is to configure, side-load apps, upload files to, etc. I'd love to have a web console for it, and I'm willing to do most/all of the heavy lifting for the front-end and server-side web development perspective. I'm going to need help on other fronts, however.
I'm a full-stack web developer. Most of what I've done professionally is PHP, but I'm not married to that. I'm also pretty good at configuring apache/nginx/ha-proxy/etc. Though once upon a time, I wrote front-end applications in Java and C++, that's ancient history, and I don't really have time to re-learn those skills and the Android SDK. Also, I'm not much of a designer, so unless I'm just using a pretty stock framework like Bootstrap, I'll need someone else to provide the art.
What I'm envisioning is an app that we can have in the play store that has a very simple UI to:
- install an SSH server
- install bash
- install web server/app server
- install DDNS client
- launch server on boot
- check server for new versions of the software it installed
Stuff I want the web interface to do:
- install/uninstall apps (file submission, URLs, etc.)
- 1-click installs of common things people want (Kodi, Amazon Prime Video, etc.)
- start/stop sshd
- manage mounting/unmounting NFS/AFS/CIFS/etc. shares (is this even possible on Android?)
- restart the device
- configure most settings on the device, including some hidden stuff
- file management
So, what I can do:
- script the download/install/upgrade of stuff on already rooted box in bash
- write back-end web code in PHP, Python, or Go
- write HTML/CSS/JS for front-end
What I need help with:
- writing the Android TV app to trigger the install script
- some help understanding/bootstrapping the process (what's installed by default on Android? What's the minimum we can get away with? Do we need Python?)
- someone to design the app (honestly, this can wait until we've got a baseline functionality if we like)
Anyone interested in joining me?
I'm leaning towards Go for the web app, because the binary can (in theory) be deployed standalone, and can be its own web server, obviating the need for apache or nginx or whatever. Also, performance and memory utilization -- PHP and Python are fairly expensive to run, and this is a really minor background thing.
This would be open source on Github.
While I unfortunately don't have a machine to helpwith code, nor the time for the code, I thought I'd give you a dev/modders look on the possibility/dificulty of things. Please don't think that I am discredditing this idea, in fact, I like it. Just want to passibly help you consider dev order and dificulty oy each item as listed, and hopefully add my own as others may have interest.
- install/uninstall apps (file submission, URLs, etc.) <-- Would be pretty easy. Users should provide apks, or you'll need a site that stores a lot of them.
- 1-click installs of common things people want (Kodi, Amazon Prime Video, etc.) <-- Similar to last point. You'll have to have a mirror of updated apks, weather you or another host provides it. You'll probably need a web scraper if going to an external host.
- start/stop sshd <-- I suggest dropbear, even if it's not my cup of tea. It can be easily found in other apps and should find code in open source ones to get you started.
- manage mounting/unmounting NFS/AFS/CIFS/etc. shares (is this even possible on Android?) <-- can be done. Check Kodi or other open source apps for code, though there are usually caviats to each approach. Luckly Android has fuse in most kernels these days.
- restart the device <-- Very easy
- configure most settings on the device, including some hidden stuff <-- Gonna be a long process, but you can probably reverse engeneer the apks and parse the XML files for a shortcut.
- file management <-- Super easy. Use the ssh server, or adb connection.
Over all, I think a lot of this is possible. Luckly these machines have the beef for a web server, and several are ported last I checked, though they may be out of date. Even still, check their codebase for a massive head start as they are mostly required to keep open source by licence (Apache excluded, though some still are). I would also suggest these features as they would be somewhat easy to imprement once the base file management is started, and would broaden the scope to bring in more users, support and interest, and hopefully devs.
-Rom Manager for emulators.
Mass File Renamer based on Filebot (Both are java, so should not be TOO hard to port) as many buy this box for Kodi.
I'll think of more.
I'm not an app dev, though I do rom modding and sometimes porting, and I can offer insite to things, so if you have questions on specifics, please pm me. If I get some free time, and a dev machine, I'll let you know antd get things going in the right direction. May also want to, once this idea is flushed out, post something in a more general android TV/ App Development thread for cleanness and to get devs on board (don't post in dev till there is code to show on github though please.
Something like remix os would be nice, this x1 has a lots of power
Sent from my trltetmo using Tapatalk
This is a great idea. This device is in serious need of developer attention. Im not a dev at all but Ive gotten pretty familiar with this device and Android OS in general, especially after spending so much time digging around trying to make android things happen that apparently were not indended for Android TV. I will be more than happy to be a tester and keep up so as to offer any ideas and some of the ways Ive found to do stuff.
@kdb424 - Thanks for the info. I'm working on a prototype right now. First build is going to list a bunch of stuff from the setting status, and allow you to reboot the device. I'll post the Github repo when I have that.
Great ideas!
There is a tool sorta in development already that does a lot of this (I've mentioned it on the Shield Zone a couple of times)
https://sites.google.com/site/nvidiashieldtvutilityapp/home/
My main needs (personally) is a means to move files to and from and my current solution is a free FTP server that works even when the Shield TV is sleeping.
https://play.google.com/store/apps/details?id=com.theolivetree.ftpserver
... works very well despite having to side load, has a terrible interface, etc. Set and forget. What's great is, I can use my file-manager-on-steroids Directory Opus to manage files since it is a standard FTP connection.
@darkuni - Yeah, I saw that, but I've got no Windows PC's in the house -- 2 Macs, a Chromebook, a Linux server, phones and tablets. I'm an old-school UNIX guy, and Windows doesn't strike my fancy. Plus, it seems like the sort of thing a web app is best for. No need for a fat client.
darkuni said:
Great ideas!
My main needs (personally) is a means to move files to and from and my current solution is a free FTP server that works even when the Shield TV is sleeping.
https://play.google.com/store/apps/details?id=com.theolivetree.ftpserver
... works very well despite having to side load, has a terrible interface, etc. Set and forget. What's great is, I can use my file-manager-on-steroids Directory Opus to manage files since it is a standard FTP connection.
Click to expand...
Click to collapse
Thanks for that I'll give it a go. I use ES file manager currently but it closes the server when you exit the app. Will also try this on a couple of FireTV Sticks I have dotted around the house as Kodi boxes :good:

Getting your android app to communicate with a pc app.

Hi guys,
So recently I've come up with what I guess is an idea that may or may not have been achieved done before. The app I'd like to create is fairly simple right now and literally consists of a tally counter. Actually, very simple.
I'd like to also make an adjacent PC app that's also a tally counter... Very simple.
However, I'd like them to communicate with each other. Why and how you may ask?
First, the why. I knit as a form of relaxation as it's quite therapeutic for me and if you don't know how knitting works, let's just say there's a lot of counting rows. A few rows is easy to remember, but when you start getting closer to 128 rows and take a break for a couple days, you forget.
Anyway, I digress. I currently have a tally counter on my phone but... That's just it, it's on my phone and I constantly have to unlock it as I don't want to leave the screen on so it can drain my battery quickly. So I thought that it might be a good idea to have an app on my phone which I can use when I'm not near my PC, but when I am, I can plug in my phone launch the app on both devices and they communicate with each other.
So if I have say 18 on my PC because that's where I left it the other day, and 48 on my phone, when I launch both apps, the PC receives that the value has changed to 48 and updates to that number. Ditto for the other way around.
Is this possible? If so, how can I get both apps to communicate with each other?
Thanks.
Jamie.
10 Apps To Connect Your Computer To Android Devices -
1. AirDroid
2. Airstream
3. Polkast
4. Desktop Notifications
5. Pushbullet
6. Message Beam
7. MightyText
8. TeamViewer QuickSupport
9. Mobizen
10. Splashtop 2 Remote Desktop.
Just had a look for any form of source code I could have a look through and there's nothing...
All I know is it can be done but not how it could be done.
Bump...
Anyone got an idea of how I could do this?
Hello Jamie,
I am with Zco Corporation, we would be happy to help with your idea. Please give me a call 603.718.3616 or email [email protected]
George Markwell
603.718.3616
Zco Corporation
zco.com
Jamie_Edwards said:
Just had a look for any form of source code I could have a look through and there's nothing...
All I know is it can be done but not how it could be done.
Click to expand...
Click to collapse
The most used method is using one socket connection between your phone and pc.

Linux On Dex - First Impressions

So, I am at work and I showed off Linux on Dex to some other Developers and Engineers here.
Impressed they were, but it's time to really dig in.
Here is what I love about it on first look:
Great to have a fleshed Linux experience on my phone
Great dev tools come with the image (IntelliJ and also Visual Studio Code and more)
Has plenty of apps to get you started and it's pretty thoughtful
Looks great at 1920x1080 as well as 2560x1440 resolutions on a monitor
Switching between Dex and Ubuntu is pretty snappy
Things I didn't like:
Just a LITTLE bit laggy sometimes
Need to either use ARM compiled apps or compile them yourself
The Default 10GB partition size was too small, so I would suggest using 15GB at least, after updates/upgrades (Ubuntu OS updates that is), you'll still have about 35% free space with 15GB disk
You cannot "install" this on the SDCard, only internal memory, so keep that in mind if you have the 128GB model and tons of apps
Once installed, you cannot delete the 3GB+ zip file you downloaded, so there is that wasted space as well (ok, I have not tried REALLY hard to delete it yet, but Google Files won't delete it, nor do I know the repercussions of deleting this file too)
I'm still trying to work out how to access the files on the device (outside the Linux container), not sure if it is possible, but I have not had a lot of time with it as of now
BONUS!!
When you are not in Dex mode (normal handset mode), you can still launch Linux on Dex, but you cannot get the full desktop experience.
Click on the Terminal icon under the RUN button and you can drop into the Ubuntu Shell and still use commands (like SSH-ing to servers using your certs and stuff).
Of course, the down side, small screen. Hey, in a pinch, when I am on the road and needs to SSH into an AWS instance and run a couple commands, I won't complain!!
All in all, I think this will be great for Dev's to play with, not sure how useful it REALLY will be, but I know from a DevOps/Architect/Engineer, it's nice to have as a backup to be able to actually take care of things without having to drag out the whole laptop.
All this, with a $20 adapter.
Any other thoughts for those that have used it?
Hello friend, I have mine installed on my 128gb Sdcard.
How did you get it on your SD Card?
Thanks!
Talderon said:
How did you get it on your SD Card?
Thanks!
Click to expand...
Click to collapse
Move the file from LoD folder to the SD card and reassign the file location in the Linux on Dex app, it worked for me but moved it back to internal storage to ensure best performance .
My impression? They will poorly maintain it and I suspect it will be discontinued without any real notice. Registration was broken for well over a week before signups ended. You cannot get in contact with anyone from the team. Care doesn't even know it exists.
I am yet to find a use case that improves upon remote access to an Ubuntu 18.04 VM running on a cloud or at home, but I'm not a developer.
Perhaps if you are stuck somewhere without an Internet connection and feel like coding somewhere in the mountains or in the jungle.. But then you would need a handy monitor, keyboard, mouse and a power source..?
I think I can sum this up in one simple sentence - "Because I can..."
It's like having linux on a PS3, because it could.
Haven't had a chance to use it yet but looks promising. That doesn't mean it will be supported very well, time will tell.
Hardware wise it should work very well, and there is ALWAYS a good reason to have a handy (mostly) self-contained PC with you in case you CAN'T access the net...
Would be great to get an idea of some real life use cases..
Would be very happy to see this project pick up some community developer attention, the platform is only as good as the tools developed for it.
In the absence of an official LoD forum for developers perhaps that community should be developed here.
p33l05 said:
In the absence of an official LoD forum for developers perhaps that community should be developed here.
Click to expand...
Click to collapse
https://developer.samsung.com/forum/board/thread/list.do?boardName=SDK&searchSubId=0000000051
I got this installed on my 8GB Note 9 today. I didn't get registered for the beta, but download the app and the Ubuntu image and got it all up and running today. My only complaint so far is it won't run full screen on Dex. That may be because I'm running the Pie Beta. Not sure how it operates on Oreo Dex.
I'll play around with it more later. I basically just plugged into my monitor and opened it up today.
Well, here is a real-life use case that saved me a TON of time and effort.
I set up the Linux on Dex with many tools and configs I need to be able to do my work (Sr. DevOps Architect/Engineer) on my AWS servers. I had an instance that was having some issues and was notified via the monitoring platform and was able to get my phone out, run the Ubuntu Shell and SSH/Fix the issue without ever having to pull out the laptop and tether it while on the train headed home.
There ARE some use cases where this will come in handy, but I do agree that these are real "edge" cases too. No "normal" user will ever really find this helpful.
Mr. Orange 645 said:
I got this installed on my 8GB Note 9 today. I didn't get registered for the beta, but download the app and the Ubuntu image and got it all up and running today. My only complaint so far is it won't run full screen on Dex. That may be because I'm running the Pie Beta. Not sure how it operates on Oreo Dex.
I'll play around with it more later. I basically just plugged into my monitor and opened it up today.
Click to expand...
Click to collapse
Full screen on oreo.. Have you tried Dex max app?
planning to install LoD and curious if it can actually decompile and recompile apk's as a laptop would..?! mostly I'm interested in Themes for Samsung.. using few apk as templates to swap files, images and recompiling the apk, will it be able and will it properly sign it ?! and if so which way should I go?! do I need to install java, SDK, plugin I saw there ?!
any advice would be great.. thanx..
Can you use any Type c to HDMI or has to be an special cable?
darkriff said:
Can you use any Type c to HDMI or has to be an special cable?
Click to expand...
Click to collapse
I think you need powersupply as well in the adapter for it to work.

Resources