Related
Hey everybody. I'm on windows and adb's shell just keeps on pissing me off. Mainly, how pressing tab actually inserts a tab rather than tab completion . I'd really like to do something about this.
Here's a list of the things i've tried to get rid of this super-annoying behaviour.
-rolled a cross-compiler toolchain (glibc-based) for my phone (HTC Magic) and cross-compiled bash (in a vm). I actually made this work even with dynamic linking, and can start bash from within an instance of "adb shell". Unfortunatly, this doesn't change the tab behaviour, which appears to be baked into adb rather than a problem with the default shell.
-I thought i'd try something fancy by doing...
adb shell mkfifo /fifo
adb shell "bash > /fifo < fifo 2> /fifo"
adb forward tcp:9001 dev:/fifo
and starting putty in raw mode, connecting to localhost:9001. Unfortunatly, all is what happens is i get an echo of what i type and if i press enter a few times putty spits out ": command not found". I can't see why this shouldn't work but I suspect i'm Doing It Wrong.
-Searching the forum revealed puttycyg, which is actually really handy but unfortunatly suffers from the same tab completion problem as using adb shell in cmd.exe
How do you guys do it? Am I onto something with the adb forward thing? If so, how do I make that work?
I have also compiled bash but I have tab completion though adb. I do however use Linux as my desktop OS and am connecting through Konsole. So you could just try to install KDE for Windows. I know that I've looked for good terminal applications for windows but found none. They're all **** compared to what's available on nix.
This is my simple bashrc:
Code:
# If interactive do nothing.
[ -z "$PS1" ] && return
export HOME="/sdcard/"
PS1='[email protected]\h:\w\$ '
Also it's full of aliases for busybox. By replacing built in ls and similar you even get nice colors But still no line editing for some reason. I figure I might just need a proper libreadline or similar for that.
If anybody's interested in how I got this working, i cross-compiled socat for the droid. Required configuring with --disable-termios and manually editing config.h to set the #define for CRDLY_SHIFT and a couple other *_SHIFT macros to some values i found in Config/linux-2.6.24.h (or something similar, posting from memory here)
Once socat is on the phone, I made it pipe data from a bash shell to a unix socket it is listening on:
socat unix-listen:/dev/adbsock,fork exec:"/bin/bash -li",pty,stderr,setsid,sigint
(command shamelessly copied from http://superuser.com/questions/123790/socat-and-rich-terminals-with-ctrlc-ctrlz-ctrld-propagation ).
Then, on the pc i run adb forward tcp:9001 localfilesystem:/tmp/adbsock
And if i connect putty to localhost:9001 in raw mode (disabling line editing and local echo) I get a fairly complete bash shell that you can not only use tab completion on but even vi works
Again, posting from memory here so if anyone wants to try this and is running into problems i can dig it up from my ~/.bash_history.
Any chance you can post your socat port?
The tab completion thing is driving me insane! I don't understand why the ADB shell in *nix is proper, but the windows version sucks so much hairy donkey balls.
I've been using Ansicon so I at least get color in my shell, but ADB still mangles tab, and I don't even want to talk about what it does to Nano. Ugh!
Oh wow, this takes me back. I don't even have my android phone anymore (cancelled the contract due to terribly crap network service, and (unfortunately) the iPhone was the best phone in its price range from my new carrier).
So I don't have any files to give to you...
But, from what I can remember, to make it work, I built a cross binutils and gcc loosely following the instructions from the LFS book, compiled glibc + a few other libs socat wanted with it, and then socat itself, and then bash. I then copied the cross libc.so.6, ld-linux.so.2 (or whatever it's called on ARM) and all the libs socat wanted to /lib on the phone, and the socat and bash binaries to /bin. It's convenient that android keeps its important stuff in /system because it means you can avoid screwing around with your toolchain to make it look for a dynamic linker in some location other than /lib.
From memory socat was the only thing I had problems compiling, and thankfully I've already posted roughly what i had to do to it to make it build (because there's no way I remember lol)
Sorry I can't be more helpful!
hey everyone,
so i finally got the dock for my TF a couple weeks ago.. i have several friends that are not as tech savvy as i am, but still like android, well i want to offer to root their devices for them. more out of curiosity then need i was wondering if it is possible to unlock and push the recovery from a TF? i know that the TF has ADB on it, but i havent really started any development on the TF its more for fun, i use my nexus 1 for development.. any light you can share on this would be appreciated.
Interesting...
Nice thread i hope some one comes up with further info about this idea i would like to do this too!!!! I have sold mi laptop TF can do everything... And soon W8 will be possible on it and STABLE Ubuntu!!!
I was contemplating this also since a girl I work with wanted me to root her Galaxy S1 but I only had my TF with me and we can't install drivers on the work computers.
I assume it should be possible, you just may need more of the Linux binaries, for example you may need to do it via a chroot install of Ubuntu or as a native (dual-boot) system. Look at the shell scripts and see what binary tools they require (cp, mv, cd etc...), you may be able to do it with Android's toolchain.
There's something in the market called "remote adb" which "might" be of use, but I kind of doubt it. It could also be one of those adbwireless versions of adb where you still do the heavy lifting from the PC.
My take would be to look at the results of google "+source +adb +android" and you'll get a couple of hits that point at adb repos in git format.
Then use a linux box to clone one and point it at some crossbuild tools (see for example the howto build kernel threads that are here and there) and built it for our architecture (arm{le}). I've done this for the bash shell and a few other things I liked in linux and it should be possible. One built, push it into /system/xbin, chmod 755 adb and see how things go.
I don't have the keyboard dock or the OTG dongle so no point in my doing it since I can't test.
Good luck -
edit: http://lackingrhoticity.blogspot.com/2010/02/how-to-build-adb-android-debugger.html seems like as good a place as any since it has source, instructions, etc. So probably all you have to do (if this nutty project will work at all) would be to modify the Makefile so that it's pointing to the toolchain for armv7le (or that's what uname -a shows on my eeepad).
edit: Another one that's already been built for android (I tested it), is sshd or dropbear and here is a link: http://jhulst.com/c/dropbear-ssh-android .
The main thing is being able to hit the device you want to setup using either ssh or scp, and functionally this'll do most if not all or more than adb will. What won't work are any scripts written that are already using adb commands.
thanks for the input originally i was thinking being able to use terminal inside honeycomb, but i suppose the easier (or perhaps better stated, the "road more traveled") route would be dual booting linux and just setting up the dev kit on there..
Latest version of ubuntu by little stevie is your best bet
Stuff that doesn't work: 3G/LTE, accelerometer, GPS, camera, and maybe some other stuff that I'm not remembering
Stuff that does work: GPU (full OpenGL 4.5 and Vulkan), sound, USB device and host, WiFi, Bluetooth, touchscreen (including stylus), SD/USB install
Downloads:
Linux4Tegra R24.1 beta (mirror) (updated on February 18th 2016)
Linux4Tegra R23.1 (mirror) (updated on November 21st 2015)
Linux4Tegra R21.4 (mirror) (updated on July 21st 2015)
Linux4Tegra R21.3 (mirror) (updated on March 9th 2015)
Installation instructions:
Install MultiROM (+ TWRP + touch support + patched kernel)
Download Linux4Tegra and install it through TWRP (Advanced -> MultiROM -> Add ROM)
Tips/notes:
To enable the on-screen keyboard during setup or login, press the blue icon in the corner and select on-screen keyboard from the menu that appears.
To enable the on-screen keyboard on desktop, run Onboard.
If your touch input becomes misaligned, install and run xinput-calibrator.
I am *very* interested in knowing which kernel you have used for this. Upstream, L4T, Android? This looks very promising in any case.
Gnurou said:
I am *very* interested in knowing which kernel you have used for this. Upstream, L4T, Android? This looks very promising in any case.
Click to expand...
Click to collapse
I've tried L4T 21.2, 19.3 and Lollipop. All of them need a small kernel patch (which might break HDMI, I have no idea) for the graphics to work, but apart from that they should all work fine for the most part.
Code:
In drivers/video/tegra/dc/dc.c, in tegra_dc_probe, after "int i;" add:
static int num_probed = 0;
if (++num_probed > 1) return -ENOENT;
Edit: this actually isn't needed, I was just using the wrong cmdline
Getting Started
THESE INSTRUCTIONS ARE OUTDATED. CONSIDER USING THE PREBUILT INSTALLER FROM THE MAIN POST INSTEAD!
You need a computer with Linux installed and some free space (I don't have the exact numbers, but 5GB would probably be enough). On the tablet, you need 2-3GB of free space (on the internal memory), an unlocked bootloader , root and you need Busybox installed too.
On the computer, you'll need to compile your kernel first (this guide includes the compiler, and there's a prebuilt boot.img in the attachments if you want to skip this part). I recommend using https://github.com/Bogdacutu/STLinux-Kernel, with st8_linux_defconfig.
The initramfs is pretty simple, it just mounts the relevant system partitions and loads Linux from them: https://github.com/Bogdacutu/STLinux-Initramfs. You'll need to edit KERNEL_PATH in build.sh and make the kernel beforehand, then running build.sh will result in a boot.img which you can boot with fastboot:
Code:
fastboot boot new_boot.img -c "console=tty1 fbcon=map:10 fbcon=rotate:2 fbfix"
For the rootfs, Linux4Tegra is the easiest place to start from. All the Tegra K1 versions should work fine. For example, with R21.2: (the sudo is necessary there)
Code:
$ wget http://developer.download.nvidia.com/mobile/tegra/l4t/r21.2.0/pm375_release_armhf/Tegra124_Linux_R21.2.0_armhf.tbz2
$ tar xfvj Tegra124_Linux_R21.2.0_armhf.tbz2
$ cd Linux_for_Tegra
/Linux_for_Tegra$ wget http://developer.download.nvidia.com/mobile/tegra/l4t/r21.2.0/pm375_release_armhf/Tegra_Linux_Sample-Root-Filesystem_R21.2.0_armhf.tbz2
/Linux_for_Tegra$ cd rootfs
/Linux_for_Tegra/rootfs$ sudo tar xfvj ../Tegra_Linux_Sample-Root-Filesystem_R21.2.0_armhf.tbz2
/Linux_for_Tegra/rootfs$ cd ..
/Linux_for_Tegra$ sudo ./apply_binaries.sh
/Linux_for_Tegra$ cd rootfs
/Linux_for_Tegra/rootfs$ sudo tar cfvj ../rootfs.tar.bz2 .
The resulting rootfs.tar.bz2 you'll need to somehow get on the device. For the next part, I'll assume it's in /sdcard/rootfs.tar.bz2. You'll need to do this on the device (through ADB or through Terminal Emulator)
Code:
$ su
# cd data
/data# mkdir linux
/data# cd linux
/data/linux# tar xfvj ../media/0/rootfs.tar.bz2
Enabling Bluetooth with brcm_patchram_plus:
Code:
$ sudo brcm_patchram_plus -d --patchram /system/etc/firmware/bcm43241.hcd --baudrate 3000000 --enable_lpm --enable_hci --use_baudrate_for_download --no2bytes --tosleep 1000 /dev/ttyTHS2
Prebuilt boot images:
new_boot(80).img - working WiFi and sound
new_boot(90).img - added pointer emulation to touchscreen driver
new_boot(94).img - fixed Bluetooth stability
new_boot(114).img - fixed HDMI, added support for non-LTE partition table, my tegra driver patch is now optional (without it fbcon doesn't work properly, enable by adding fbfix to cmdline)
new_boot(123).img (newest at the moment) - fbfix isn't needed anymore, added support for tmpfs ACLs, enabled XZ compression (because after reaching a certain size, the kernel wouldn't find the initramfs anymore), enabled KVM
Bogdacutu said:
Code:
In drivers/video/tegra/dc/dc.c, in tegra_dc_probe, after "int i;" add:
static int num_probed = 0;
if (++num_probed > 1) return -ENOENT;
Click to expand...
Click to collapse
Won't this code always return - ENOENT?
Sent from my Xperia Z1 Compact using Tapatalk
_TB_TB_ said:
Won't this code always return - ENOENT?
Sent from my Xperia Z1 Compact using Tapatalk
Click to expand...
Click to collapse
It will always return -ENOENT except for the first time the function gets called (which is enough for the screen to get initialized).
Unless you are looking to completely break the Ubuntu install, do not perform a release upgrade to 14.10.
Everyone here probably already knows this but I wanted to see what would happen, which was rendering the x-server unusable. These results did not surprise me but hopefully this will save someone else who has the same idea as I did some time.
joshtheitguy said:
Unless you are looking to completely break the Ubuntu install, do not perform a release upgrade to 14.10.
Everyone here probably already knows this but I wanted to see what would happen, which was rendering the x-server unusable. These results did not surprise me but hopefully this will save someone else who has the same idea as I did some time.
Click to expand...
Click to collapse
Try doing
Code:
sudo apt-mark hold xserver-xorg-core
before doing the upgrade, to prevent the driver from being overwritten.
Bogdacutu said:
Try doing
Code:
sudo apt-mark hold xserver-xorg-core
before doing the upgrade, to prevent the driver from being overwritten.
Click to expand...
Click to collapse
Thanks, that was the command I couldn't remember. Let me do a backup of it first then I will try again to see if the outcome is any different, I'll let you know how it goes once I have a chance.
Great i need a dual boot Android/Linux
Bogdacutu said:
What works:
Audio
WiFi
Click to expand...
Click to collapse
Bogdacutu said:
Got it working thanks to /u/GenuineAster, will post a full guide in a day or two.
Click to expand...
Click to collapse
Bogdacutu said:
Photos:
https://s3.amazonaws.com/pushbullet...OAfew/Screenshot from 2014-12-28 12:51:51.png
Click to expand...
Click to collapse
I got my tablet 2 days ago, and I'm already trying to mess up with it... I decided to try to install Ubuntu on my Shield Tablet (WiFi only, EU model).
So basically, I managed to boot it up thanks to you tutorial. It seems to be working well, but there are some things that does not work, and I see you apparently solved those issues already...
The issues I have are the following, ordered by priority:
- No WiFi (I see that you apparently solved this issue, can you please explain how you managed to do that?)
- While I was writing this message, I went to keyboard layout options, and the OS crashed, it went back to login screen twice (I was on the same window each time, it showed nvidia black screen, then the login screen)
- No audio (I only have a device named "Dummy audio input/output", you seem to have audio, can you confirm that?)
- Graphics flickering on some textures, for example, on the main sidebar menu, when my mouse pointer is over an icon, there is a background on that icon, but the background is flickering, that's weird...
- No touchscreen (But you don't neither)
For the moment, I think the most important thing is WiFi, since I can't do anything without network connexion. Can you help me with that? Thank you!
etienne51 said:
I got my tablet 2 days ago, and I'm already trying to mess up with it... I decided to try to install Ubuntu on my Shield Tablet (WiFi only, EU model).
So basically, I managed to boot it up thanks to you tutorial. It seems to be working well, but there are some things that does not work, and I see you apparently solved those issues already...
The issues I have are the following, ordered by priority:
- No WiFi (I see that you apparently solved this issue, can you please explain how you managed to do that?)
- While I was writing this message, I went to keyboard layout options, and the OS crashed, it went back to login screen twice (I was on the same window each time, it showed nvidia black screen, then the login screen)
- No audio (I only have a device named "Dummy audio input/output", you seem to have audio, can you confirm that?)
- Graphics flickering on some textures, for example, on the main sidebar menu, when my mouse pointer is over an icon, there is a background on that icon, but the background is flickering, that's weird...
- No touchscreen (But you don't neither)
For the moment, I think the most important thing is WiFi, since I can't do anything without network connexion. Can you help me with that? Thank you!
Click to expand...
Click to collapse
I just updated the boot.img from post #4, WiFi and sound work now, Bluetooth works if you load firmware but it's pretty unstable at the moment.
Ok, I just tested it, and I confirm it works! I haven't tried bluetooth for the moment, but I have WiFi and audio now with v80. Thank you for the update!
I have another question, I saw your previous screenshot showing glxgears running at around 900-1000fps. Since I have some small lags sometimes, I decided to try glxgears and I'm running at around 450fps, that's less that half the framerate you have on your Shield Tablet. Did you do something special with the drivers after the tutorial you wrote?
etienne51 said:
Ok, I just tested it, and I confirm it works! I haven't tried bluetooth for the moment, but I have WiFi and audio now with v80. Thank you for the update!
I have another question, I saw your previous screenshot showing glxgears running at around 900-1000fps. Since I have some small lags sometimes, I decided to try glxgears and I'm running at around 450fps, that's less that half the framerate you have on your Shield Tablet. Did you do something special with the drivers after the tutorial you wrote?
Click to expand...
Click to collapse
Not really, you can try messing with the governors and max frequency, iirc there's a script in the driver package that automatically sets the CPU frequency lower on boot.
Update: I got the touchscreen to work with the Android drivers! I will upload the changes to my kernel repo soon (as soon as I figure out which of all the changes I did are actually required).
How is HDMI out? I find it mildly function on Android, can I expect the same from Ubuntu? Also, I didn't see if LTE is supported.
adampdx said:
How is HDMI out? I find it mildly function on Android, can I expect the same from Ubuntu? Also, I didn't see if LTE is supported.
Click to expand...
Click to collapse
No idea if HDMI works, I don't have a cable (my patch might break it though, in which case we'll probably need to change it). And it works on LTE tablets, but mobile data doesn't work (at least for now).
adampdx said:
How is HDMI out? I find it mildly function on Android, can I expect the same from Ubuntu? Also, I didn't see if LTE is supported.
Click to expand...
Click to collapse
I just ordered a Mini HDMI to HDMI cable, it will arrive in less than a week. As soon as I get it, I'll tell you guys how it works!
/u/GenuineAster confirmed that HDMI isn't working. I'm going to get an Ethernet adapter for netconsole soon, so that I can find out why it doesn't work with my patch to the tegra driver (which I'm sure is the reason HDMI isn't working). I'm also working on a way to get libGL.so to work in an i386 chroot (so that we can try to play desktop games that aren't compiled for ARM yet).
I'm impressed that this actually works so well. Makes what I have on my Shield Portable look pitiful. No sound, no video acceleration, etc. Now the question is, what changes have to be made to a mainline kernel to get similar results? Well, minus the video acceleration that's likely hard-coded to a specific kernel version. Bogdacutu, do you have a patch of your changes? Your github repo isn't a forked copy of the kernel, so it's hard to see the initial changes. I'd like to get a copy of Fedora running. Also looking forward to your touchscreen fix. My usb-otg cable is flakey to the point it causes Ubuntu to reboot if I bump it too much...
Question to the larger community: Anyone know how to get the wireless controller to work with this? I poked at wpa_cli and a couple of the p2p_ commands, but so far haven't picked up anything from the controller when it's searching.
Edit: Seems the otg charging thing doesn't work either. Makes long-term use impracticle when an input device has to be plugged in. Any of the kernel hackers know the bits that changed in nvidia's lollipop kernel to allow this?
Following much of moonbutt74's advice and using the sources from his kernel (thank you so so so much!)
https://github.com/moonbutt74/kernel_sxz5p_aosp_4square
I was able to modify
https://github.com/moonbutt74/kerne...rm/boot/dts/qcom/dsi-panel-satsuki.dtsi#L1107
and create what I believe to be the first working truly 4k always on kernel for the z5p
I say what I believe to be because honestly I can't really tell.
I reset my wm density and wm size from the "emulated 4k thread" http://forum.xda-developers.com/showpost.php?p=64587441&postcount=13
Screenshots taken appear to be in 4k
The phone seems to switch into 4k much in the way it would if it were "emulated" after the window manager loads
1440p video appears to be available on YouTube
And honestly it looks really sharp and everything seems to be rather tiny
As of right now I only have this build for the E6853, as it is the only device I own, and I've literally just managed to get this "working"
I'll consider trying to build this for the dual if the feedback here seems good and if people can actually confirm whether this is working or not.
I also don't even guarantee this loads on any device but my own. (This could be 100% a fluke)
Also also, if it does work, it'll probably destroy your battery.
Files
Android Filehost:
https://www.androidfilehost.com/?fid=24499762636004594
Google Drive:
https://drive.google.com/file/d/0BzP80_K1-cv2VVFUX1cybE9fc0k/view?usp=sharing
Click to expand...
Click to collapse
I flashed my file with fastboot
Code:
fastboot flash boot E6853-always4k.img
When it first boots the screen looks a little fudged up (for lack of a better word), but if you give it a little bit (for me at least, it boots and appears to be in 4k mode)
Please let me know what you find, and please don't blame me (but do let me know) if it doesn't work for you or breaks your device.
In other news,
At the time of writing this, I'm probably in possession of the only phone in the world natively running a 2160x3840 resolution right now, so that's pretty cool.
BustyLoli-Chan said:
Following much of moonbutt74's advice and using the sources from his kernel (thank you so so so much!)
https://github.com/moonbutt74/kernel_sxz5p_aosp_4square
I was able to modify
https://github.com/moonbutt74/kerne...rm/boot/dts/qcom/dsi-panel-satsuki.dtsi#L1107
and create what I believe to be the first working truly 4k always on kernel for the z5p
I say what I believe to be because honestly I can't really tell.
I reset my wm density and wm size from the "emulated 4k thread" http://forum.xda-developers.com/showpost.php?p=64587441&postcount=13
Screenshots taken appear to be in 4k
The phone seems to switch into 4k much in the way it would if it were "emulated" after the window manager loads
1440p video appears to be available on YouTube
And honestly it looks really sharp and everything seems to be rather tiny
As of right now I only have this build for the E6853, as it is the only device I own, and I've literally just managed to get this "working"
I'll consider trying to build this for the dual if the feedback here seems good and if people can actually confirm whether this is working or not.
I also don't even guarantee this loads on any device but my own. (This could be 100% a fluke)
Also also, if it does work, it'll probably destroy your battery.
Using google drive because I don't have a dev account on android filehost
I flashed my file with fastboot
Code:
fastboot flash boot E6853-always4k.img
When it first boots the screen looks a little fudged up (for lack of a better word), but if you give it a little bit (for me at least, it boots and appears to be in 4k mode)
Please let me know what you find, and please don't blame me (but do let me know) if it doesn't work for you or breaks your device.
In other news,
At the time of writing this, I'm probably in possession of the only phone in the world natively running a 2160x3840 resolution right now, so that's pretty cool.
Click to expand...
Click to collapse
nice work gonna give a try
edit: im using RomAur-v3.0 will this kernel work?? just asking before i flash thanks
BustyLoli-Chan said:
Following much of moonbutt74's advice and using the sources from his kernel (thank you so so so much!)
https://github.com/moonbutt74/kernel_sxz5p_aosp_4square
I was able to modify
https://github.com/moonbutt74/kerne...rm/boot/dts/qcom/dsi-panel-satsuki.dtsi#L1107
and create what I believe to be the first working truly 4k always on kernel for the z5p
I say what I believe to be because honestly I can't really tell.
I reset my wm density and wm size from the "emulated 4k thread" http://forum.xda-developers.com/showpost.php?p=64587441&postcount=13
Screenshots taken appear to be in 4k
The phone seems to switch into 4k much in the way it would if it were "emulated" after the window manager loads
1440p video appears to be available on YouTube
And honestly it looks really sharp and everything seems to be rather tiny
As of right now I only have this build for the E6853, as it is the only device I own, and I've literally just managed to get this "working"
I'll consider trying to build this for the dual if the feedback here seems good and if people can actually confirm whether this is working or not.
I also don't even guarantee this loads on any device but my own. (This could be 100% a fluke)
Also also, if it does work, it'll probably destroy your battery.
Using google drive because I don't have a dev account on android filehost
I flashed my file with fastboot
Code:
fastboot flash boot E6853-always4k.img
When it first boots the screen looks a little fudged up (for lack of a better word), but if you give it a little bit (for me at least, it boots and appears to be in 4k mode)
Please let me know what you find, and please don't blame me (but do let me know) if it doesn't work for you or breaks your device.
In other news,
At the time of writing this, I'm probably in possession of the only phone in the world natively running a 2160x3840 resolution right now, so that's pretty cool.
Click to expand...
Click to collapse
I have installed it and I have to say that is all too small , icons , options, keyboards, etc ... for everyday use would be very uncomfortable. I also noticed lag when accessing the application drawer in transitions panel and keypad ... I 've become the kernel of zacharias.maladroid , anyway thanks for your work . a greeting
B,
okay e6853
Fudgy at beginning as you said. :silly:
That's Sony's splash logo though, doesnt display right at 4k, and the boot animation as well, again Sony.
Gonna need 4k bootanimations!
Note : does not play well with Nova Launcher. xD
What is your screen density in the screen shots? At default I'm @
Code:
[email protected]:/ $ wm size
Physical size: 2160x3840
[email protected]:/ $ wm density
Physical density: 480
Override density: 560
I'd like to see the patch/mod you did to kernel , please post? I want to tuck that modification into a cm build to see what happens. NVM i missed the link in OP.
What are your obeservations on battery consumption?
On a side note this modification seems to break the booting to recovery via bootec setup.
m
raven213 said:
nice work gonna give a try
edit: im using RomAur-v3.0 will this kernel work?? just asking before i flash thanks
Click to expand...
Click to collapse
Honestly, I have no idea
Please let me know what you find though!
Rubensss said:
I have installed it and I have to say that is all too small , icons , options, keyboards, etc ... for everyday use would be very uncomfortable. I also noticed lag when accessing the application drawer in transitions panel and keypad ... I 've become the kernel of zacharias.maladroid , anyway thanks for your work . a greeting
Click to expand...
Click to collapse
Nothing is to prevent you from adjusting the DPI manually at this point. This was purely to see if 4k could be done. You can easily tweak it it to your liking from here either with builp.prop, wm density or some other app dpi changing app.
moonbutt74 said:
B,
okay e6853
Fudgy at beginning as you said. :silly:
That's Sony's splash logo though, doesnt display right at 4k, and the boot animation as well, again Sony.
Gonna need 4k bootanimations!
Note : does not play well with Nova Launcher. xD
What is your screen density in the screen shots? At default I'm @
Code:
[email protected]:/ $ wm size
Physical size: 2160x3840
[email protected]:/ $ wm density
Physical density: 480
Override density: 560
I'd like to see the patch/mod you did to kernel , please post? I want to tuck that modification into a cm build to see what happens. NVM i missed the link in OP.
What are your obeservations on battery consumption?
On a side note this modification seems to break the booting to recovery via bootec setup.
m
Click to expand...
Click to collapse
My density is the same as yours minus the override density, but I'm using action launcher. (I'll agree with Rubensss though some things are just too tiny. I'll probably start messing with my actual density later today)
Code:
[email protected]:/ $ wm density
vm density
Physical density: 480
[email protected]:/ $ wm size
vm size
Physical size: 2160x3840
The link in the original post is the original file. I've pushed the 4k modification(s) to here:
https://github.com/BustyLoli-Chan/k...arch/arm/boot/dts/qcom/dsi-panel-satsuki.dtsi
I've not had a real chance to take it out and test battery life yet, (I stayed up super late working on it and spent most of today sleeping)
Also I was worried about recovery. I haven't checked it yet, but I thought it might simply fail or look crazy because I took 1080p mode out entirely to force 4k to work. All my previous attempts to set 4k preferred and have it play nice with 1080p had failed, but I can mess around more with it today (or you can if you want now that you have the file.)
Everything else I tried seemed to cause serious problems and with this for some reason it just suddenly booted and worked.
might be able to add all the blocks mentioning 1080p back in under the ones that say 4k (since my first edit was to just leave 4k where it was and move the preferred mode flag which didn't seem to work)
Now that we know this is working I would like to seriously and formally thank you for all of your help and hard work with assisting me to the point where I could actually make this work. I'd also be lying if I said fesar's thread and AndroPlus'es post weren't huge inspirations for me to try to get this done.
@BustyLoli-Chan
Hey check /try this out modify build with 4k option WIP
The above commit modifies the kernel build with a 4k option in line with your experiment.
Instead of modifying arch/arm/boot/dts/qcom/dsi-panel-satsuki.dtsi
I added arch/arm/boot/dts/qcom/dsi-panel-satsuki-4k.dtsi , which contains your modifications so far.
When you run the build script and get to the menuconfig portion, going to
Platform selection ---> [ ] Impose 4k resolution on Satsuki Target
Permits you to build your 4k display experiment. This way you can work/mod arch/arm/boot/dts/qcom/dsi-panel-satsuki-4k.dtsi
and leave the orriginal [2k] version intact.
Currently in menuconfig
Boot options --->Build a concatenated Image.gz/dtb by default does select the new/correct dtsi's but still doesn't find the resulting dtb's though they DO build. I have a little work to do there. But zImage and dtb.img DO build. and do boot the device correctly.
The dtb's select based on whether the 4k option is enabled or not.
You don't actually need any of the above but it seemed like a less destructive way to care for your kernel source.
That and I was wondering if it would actually work, which it mostly does. If you're interested in this setup, I'll update you when i figure out why making the Image.gz-dtb doesn't find the 4k dtbs.
This is that portion of the build
Code:
make[1]: *** No rule to make target 'arch/arm64/boot/dts/msm8994-v2.0-kitakami_satsuki_generic-4k.dtb', needed by 'arch/arm64/boot/Image.gz-dtb'. Stop.
/storage/sxZ5_dev/kernel/aosp_4square/arch/arm64/Makefile:84: recipe for target 'Image.gz-dtb' failed
But other wise the normal dt.img does generate
Code:
DTB combiner:
Input directory: './arch/arm/boot/dts/qcom/'
Output file: 'build_satsuki/out/boot.img-dtb'
Found file: msm8994-v2.0-kitakami_satsuki_generic-4k.dtb ... chipset: 207, rev: 131072, platform: 8, subtype: 0
Found file: msm8994-v2.1-kitakami_satsuki_generic-4k.dtb ... chipset: 207, rev: 131073, platform: 8, subtype: 0
=> Found 2 unique DTB(s)
and the resulting kernel binary and dt.img
Code:
-rw------- 1 root root 784384 Apr 20 23:56 boot.img-dtb
-rwxr-xr-x 1 root root 19487944 Apr 20 23:56 boot.img-zImage
The normal [2k] build will run without issue
Code:
-rw------- 1 root root 788480 Apr 21 00:14 boot.img-dtb
-rwxr-xr-x 1 root root 19487944 Apr 21 00:14 boot.img-zImage
-rw-r--r-- 1 root root 8827937 Apr 21 00:14 boot.img-zImage_gz
m
moonbutt74 said:
@BustyLoli-Chan
Hey check /try this out modify build with 4k option WIP
The above commit modifies the kernel build with a 4k option in line with your experiment.
Instead of modifying arch/arm/boot/dts/qcom/dsi-panel-satsuki.dtsi
I added arch/arm/boot/dts/qcom/dsi-panel-satsuki-4k.dtsi , which contains your modifications so far.
When you run the build script and get to the menuconfig portion, going to
Platform selection ---> [ ] Impose 4k resolution on Satsuki Target
Permits you to build your 4k display experiment. This way you can work/mod arch/arm/boot/dts/qcom/dsi-panel-satsuki-4k.dtsi
and leave the orriginal [2k] version intact.
Currently in menuconfig
Boot options --->Build a concatenated Image.gz/dtb by default does select the new/correct dtsi's but still doesn't find the resulting dtb's though they DO build. I have a little work to do there. But zImage and dtb.img DO build. and do boot the device correctly.
The dtb's select based on whether the 4k option is enabled or not.
You don't actually need any of the above but it seemed like a less destructive way to care for your kernel source.
That and I was wondering if it would actually work, which it mostly does. If you're interested in this setup, I'll update you when i figure out why making the Image.gz-dtb doesn't find the 4k dtbs.
This is that portion of the build
Code:
make[1]: *** No rule to make target 'arch/arm64/boot/dts/msm8994-v2.0-kitakami_satsuki_generic-4k.dtb', needed by 'arch/arm64/boot/Image.gz-dtb'. Stop.
/storage/sxZ5_dev/kernel/aosp_4square/arch/arm64/Makefile:84: recipe for target 'Image.gz-dtb' failed
But other wise the normal dt.img does generate
Code:
DTB combiner:
Input directory: './arch/arm/boot/dts/qcom/'
Output file: 'build_satsuki/out/boot.img-dtb'
Found file: msm8994-v2.0-kitakami_satsuki_generic-4k.dtb ... chipset: 207, rev: 131072, platform: 8, subtype: 0
Found file: msm8994-v2.1-kitakami_satsuki_generic-4k.dtb ... chipset: 207, rev: 131073, platform: 8, subtype: 0
=> Found 2 unique DTB(s)
and the resulting kernel binary and dt.img
Code:
-rw------- 1 root root 784384 Apr 20 23:56 boot.img-dtb
-rwxr-xr-x 1 root root 19487944 Apr 20 23:56 boot.img-zImage
The normal [2k] build will run without issue
Code:
-rw------- 1 root root 788480 Apr 21 00:14 boot.img-dtb
-rwxr-xr-x 1 root root 19487944 Apr 21 00:14 boot.img-zImage
-rw-r--r-- 1 root root 8827937 Apr 21 00:14 boot.img-zImage_gz
m
Click to expand...
Click to collapse
I feel as though some if not all of this is over my head lol
I've been trying to get recovery and the pre-OS systems to work.
I added 1080p timings back into my script over here https://github.com/BustyLoli-Chan/k...arch/arm/boot/dts/qcom/dsi-panel-satsuki.dtsi
The device still boots, but there is no change over the 4k only version, which makes sense really because nothing ever tells the device to switch to 1080p over the preferred 4k. I realize there are a lot of "extra" things in the 4k timings that aren't present in the 1080p but I don't know if any of these settings will achieve what I am looking for.
I was going to try going through and changing each section of the dtsi file to be 4k in the hopes that maybe the pre OS parts of the code use a different sets of timings that the actually OS does (so it could default to 1080p until the OS boots and then start 4k mode) but truthfully, I don't know if any such an option/special timing at all exists.
I feel like the way the phone operates by default is that it stays in 1080p mode until some software in Sony's proprietary apps feeds it the right command to go 4k.
A more graceful way to implement 4k always on would probably be to wait until the OS boots and then feed the panel that command (that way all the pre OS systems still work fine). If we could find the code for that, such an implementation could probably allow you to toggle 4k on or off somewhere in the system settings or somewhere as accessible as the power menu, but such an implementation would be entirely outside the scope of files I'm currently trying to edit.
All in all, I've learned I really don't know a whole lot about any of this.
I hope to learn and figure out more, but documentation and resources seem scarce.
Hi moonbutt74
Do you think its possible to make a version of the kernel for the z5 Premium Dual (E6883)?
I'm a VR NERD.
I use my z5 premium only for VR because for all other things i use a Samsung S7.
I hope you can help me, because its a shame from Sony that the display are not usable in 4K with the Zeiss VR One. Its only possible without head tracking. with the sony movie player....
I start with test: S7+Gear VR vs. Z5premium Dual+VR One and today the best VR Phone is the S7
but only because the bad software from Sony.
Thank you
lotusalex2000 said:
Hi moonbutt74
Do you think its possible to make a version of the kernel for the z5 Premium Dual (E6883)?
I'm a VR NERD.
I use my z5 premium only for VR because for all other things i use a Samsung S7.
I hope you can help me, because its a shame from Sony that the display are not usable in 4K with the Zeiss VR One. Its only possible without head tracking. with the sony movie player....
I start with test: S7+Gear VR vs. Z5premium Dual+VR One and today the best VR Phone is the S7
but only because the bad software from Sony.
Thank you
Click to expand...
Click to collapse
It looks like the DTSI file for the Satsuki is the same regardless of whether you have the Dual or the Regular, so in theory you should just be able to run the build script for "./hmm-satsuki-dsds" pull the current kernel image from your device, replace the kernel, repack the image, and flash it and get 4k.
Thanks BustyLoli-Chan
i try it.
What about battery life?
EMJI79 said:
What about battery life?
Click to expand...
Click to collapse
Battery life is usually fine in my opinion if the phone screen isn't constantly on. If you are constantly using the screen though, man does it drain. usually playing around with it though I can make it through about a full class day. I'd estimate 5-6 hours of regular use, but do not quote me on that.
Would be great to choose display app by app: for example, 4k on YouTube, Google +, instagram,... 2k on Chrome and 1080p everywhere else.
Something like that.
Would it be possible to have an Xposed module do that?
e6883 can be used?
github down?
I need some help with the compiler
Hi
I use a guide to compile the kernel. developer.sonymobile.com/knowledge-base/open-source/open-devices/how-to-build-and-flash-a-linux-kernel/how-to-build-and-flash-a-linux-kernel-from-sony-copyleft-archives
1. Unlock the boot loader : done
2. Download a cross compiler :
I use the /android.googlesource.com/platform/prebuilts/gcc/linux-x86/arm/arm-linux-androideabi-4.9/
because in the next step I use :
3. export CROSS_COMPILE=/android/prebuilts/gcc/linux-x86/aarch64/aarch64-linux-android-4.9/bin/aarch64-linux-android-
Done
4. Download the kernel source. Thanks for moonbutt74's : Done
5. Identify your device’s config file name : ??????? WITH buildprop Editor i find under BUILD INFO ro.board.platform: msm8994 and in the Kernel directory arch/arm64/ there is a file msm8994_defconfig :fingers-crossed: lets try it.
6. Configure the kernel
open Terminal and : make ARCH=arm64 CROSS_COMPILE=$CROSS_COMPILE msm8994_defconfig
now i see some bla bla and no errors
7. Build the kernel and needed modules
I try in Terminal: make ARCH=arm64 CROSS_COMPILE=$CROSS_COMPILE -j 1
Now i get:
#make ARCH=arm64 CROSS_COMPILE=$CROSS_COMPILE -j 1
#Makefile:605: Cannot use CONFIG_CC_STACKPROTECTOR_REGULAR: -fstack-protector not supported by compiler
# CHK include/generated/uapi/linux/version.h
# CHK include/generated/utsrelease.h
# CC kernel/bounds.s
#gcc: error: unrecognized command line option ‘-mlittle-endian’
#gcc: error: unrecognized command line option ‘-mgeneral-regs-only’
#/home/lotusalex2000/backup/android/kernel/./Kbuild:35: recipe for target 'kernel/bounds.s' failed
#make[1]: *** [kernel/bounds.s] Error 1
#Makefile:862: recipe for target 'prepare0' failed
#make: *** [prepare0] Error 2
what did I do wrong?????
:crying:
Maybe Satsuki?
I read some other guides and I think, its problem with my PC. I hope that i find someone that can compile the kernel.
@BustyLoli-Chan
BustyLoli-Chan can you please compile your kernel again, with the config satsuki-dsds in the Folder of moonbutt74? Thats the Config for the Z5 Premium Dual Sim
Thank you
lotusalex2000 said:
I read some other guides and I think, its problem with my PC. I hope that i find someone that can compile the kernel.
@BustyLoli-Chan
BustyLoli-Chan can you please compile your kernel again, with the config satsuki-dsds in the Folder of moonbutt74? Thats the Config for the Z5 Premium Dual Sim
Thank you
Click to expand...
Click to collapse
Can you please give link to other guides you found?
Sent from my LG-F460S using XDA-Developers mobile app
the best,
with Kernel from z5 Premium
http ://developer.sonymobile.com/knowledge-base/open-source/open-devices/how-to-build-and-flash-a-linux-kernel/how-to-build-and-flash-a-linux-kernel-for-aosp-supported-devices/
Hello. I'm trying to use Linux Deploy Framebuffer options, however it seems the framebuffer is not accessible starting with OnePlus 6T McClaren edition.
Normally, framebuffer is located at /dev/graphics/fb0.
Starting with (oneplus 3?), it is located at /sys/devices/virtual/graphics/fb0
On OnePlus 6T McClaren, OnePlus 7, and OnePlus 7 Pro, it is located in none of these locations.
Does any dev know where it is now?
I have exactly the same question LOL
Did you find it out yet?
I tried to use ls and grep to find graphics/fb and got no luck
on the oneplus 7 pro (android 10) stock, the framebuffer seems to be in /dev/fb0.
However, I do not manage to get anything else than a black screen (the back key gets you back to the terminal logs).
In vnc, everything works correctly (and the phone is fast). The only issue is access to some keys (windows...)
If anybody has succeeded in using the framebuffer on oneplus recent phones, I am interested too (which display, which fb ...).
[EDIT] For now success with the X11 output and xserver-xsdl. Works well.
I would be curious about the perf difference between xserver vs direct framebuffer