yashsingh1/xdaforums huggingface dataset:
[One (M7) Original Android Development] Cotulla:
Well MAGLDR will be in the right boot.img format, so HBOOT will boot it like kernel.

Then MAGLDR will load Linux kernel in case of Android boot.

I think It's not good idea to touch HBOOT at all. So MAGLDR should run after it.

1)Android: HBOOT -> MAGLDR -> Linux kernel

2)Windows: HBOOT -> MAGLDR -> UEFI -> Windows kernel

During start up MAGLDR will read stroage config from eMMC and put it into ram.

So Android or UEFI will able to use it for detecting userdata partition bounds.
[One (M7) Original Android Development] Stephen:
Would it be possble for International HTC One M7 32gb to be able to dual boot eg: have Windows 8 and android running so while in MAGLDR we could have a option menu to boot which ever one we want.

If this is the case would the user data partition need to be split into two partitions or could it run on one?

Also will off mode charging be an issue with MAGLDR like it was in the HD2 days?

The other thing I was wondering is from MAGLDR if running androild would recovery be accessable eg TWRP?
[One (M7) Original Android Development] zyy757:
Hi Cotulla, miss you so much. I have a question: as you said, MAGLDR was put in mmcblk0p33 and grab space from mmcblk0p37, is that mean we will need another recovery put in the space you grabbed?
[One (M7) Original Android Development] melando:
Hope so as I have one but storage is constrained as we already start with only about 25G available (on my hd2 I have a 64G card on top of WP7.8 in separate NAND)

Surely windows will need a different format still?
[One (M7) Original Android Development] Cotulla:
Well, after installation Windows RT 8.0 takes 8Gb :mad: (no idea about 8.1RT yet)

Probably it's possible to strip something out. Maybe someone will look in the future after DFT release and make custom "cleared" versions.

Yes I am going to divide eMMC space to be able store Android and WRT.

I will try to make it as close as possible to original.

I didn't write MAGLDR to eMMC yet, it's booting from RAM.

Only boot.img is going to be moved and userdata splitted.

I want to divide userdata partition:

1. original userdata

--------------- sector X
| |
| |
| EXT4 |
| "userdata" |
| for |
| Android |
| |
--------------- sector X + N

2. modified userdata

--------------- sector X
| |
| |
| MAGLDR | FAT or Raw, small size,
| data | holds {sector P0, P1 and P2}
| |
| |
| |
--------------- sector X + P0
| |
| |
| Android | Raw boot.img
| kernel | loaded by MAGLDR to boot Android
| |
| |
| |
--------------- sector X + P1
| | has own GPT at the beginning
| |
| WRT |
| region |
| |
| |
| |
--------------- sector X + P2
| |
| |
| EXT4 |
| "userdata" |
| for |
| Android |
| |
--------------- sector X + N
[One (M7) Original Android Development] solbirn:
You may want to look at "Features on Demand" in Win8+ . I think it does exactly that, and can clean a wim file prior to (or after) install.

Features can also be reinstalled later if wanted (downloaded via Windows Update or from original full install image).
[One (M7) Original Android Development] lolerpro8:
So you are going to reformat the userdata partition for magldr's system partitions for android/wimmo. But can you include a feature inside magldr to repartition that reserved space so you can increase/ decrease it for the needs of the user?
[One (M7) Original Android Development] the_scotsman:
I'm moving this to the Development forum as there's mostly development/technical discussion going on now, which is good. So please keep idle chit chat out of the thread, and only about technical aspects of this development.
[One (M7) Original Android Development] zyy757:
How about put the android kernel or WRT kernel into the unused partitions like mmcblk0p29/30/32 ? Just put MAGLDR in mmcblk0p33.
[One (M7) Original Android Development] compact_bijou:
Were you serious about WM6.5?

Dual booting that and droid on the One would be awesome.

Or how about a Cotulla emulator for WM6.5?
[One (M7) Original Android Development] csoulr666:
Even if we get WM6.5 working, we would require some sort of a display hack because I'm pretty sure it doesn't support 1080p resolutions.

And [MENTION=600525]Cotulla[/MENTION], does the Htc one max have similar partitions to the One?? Considering both of them having almost similar specifications? Also there are rumours regarding Microsoft asking HTC to provide WP8 as a "Secondary OS", will it make it a whole lot easier if HTC actually does that?

Sorry for so many questions, I really learning about this stuff more and more :D
[One (M7) Original Android Development] gilbert32:
Twitter.com/cotullacode

He said earlier that he would "double pixel" it for example

also, this is just like hd2 days, people asking port to phones of similar specs. i doubt he would do anything, for a phone other than this. this is just not the DFT way of working. Even if similar specs, his code is not something universal. Very device specific. That is the reason he went HD2 -> ONE
[One (M7) Original Android Development] csoulr666:
I must've missed that, plus I'm actually not requesting it......hell I wouldn't even by the Max, it's just in "the more the better" sense
[One (M7) Original Android Development] Cotulla:
Don't think so. Resizing without data lost is very hard and long operation - you need resize EXT4 for Android and resize NTFS for windows and etc.

But if someone want and can he/she can implement it in the recovery and share results with community.

Or maybe make android use NTFS instead of EXT4 and use shared partition.

there are no "WRT kernel", it's like PC - system disk C:\ and etc. In common it's around 8 Gb :crying:

In attachment screenshot from LEO (32 Gb microSD).

It doesn't run yet, I am working on it.

Yes, I was pretty serious, I have few ideas in that direction.

I can use hardware scaling from 960x540 or ever smaller - from 480x800 which is the highest WM65 supported resolution.

No idea about HTC One Max...probably it's similar in something, if community will provide device for development it probably can be done.

DFT team is not related with that MS idea, but it will be good to get some kind of support from them.
[One (M7) Original Android Development] Stephen:
OT posts have been cleaned. Please remember this is for development only.
[One (M7) Original Android Development] lolerpro8:
It's not possible. NTFS doesn't support linux symlinks and/or other features I missed.
[One (M7) Original Android Development] Cotulla:
Well, after many attempts I am going to pay primary attention for dividing eMMC space to be able store files inside device.

Otherwise it's very hard to debug and annoying start up. You need switch USB cables as hell :eek:

I really miss a microSD slot :mad::mad::mad:

But do Android and applications really need that functions?

I know that /etc/ is linked to /system/etc and many other things, but is it really needed for /data?
[One (M7) Original Android Development] hillbeast:
Well the /data/media partition is in there and people may do weird stuff on their media directory. As well as that we don't know what bizarre hacks some applications could try using. You're best sticking with EXT4 as that's what Android was designed around.
[One (M7) Original Android Development] formula84:
I believe there is alot of symlinks on the data partition... I have seen a few using root explorer, SD card since this device does not have one is linked to data/media/0
[One (M7) Original Android Development] DeSaint2:
Starting with 4.2 Google added 3 places where the data/media is linked. This was so there could be multiple users per device similar to the way Windows is. Each user gets their own folder for data. Though the weird part is, if you delete from any of the symlinks it deletes it from data/media as well. Hope that helps.
[One (M7) Original Android Development] lolerpro8:
Going trough data partition only thing I found is data/user/0 is symlinked

To data/data . I'm not going to delete it for test for boot loops...

And PS is it going to have tetris?
[One (M7) Original Android Development] pandaball:
Thread cleaned. As mentioned before, this is a pure development thread. As such, requests, opinions etc go elsewhere. If you have nothing concrete to contribute, forever hold your peace ;)
[One (M7) Original Android Development] donmarkoni:
DeSaint2, mate, you are... erm... wrong. Well, you are thinking straight, but your symlinks got mixed-up. ;) Those symlinks you mentioned are there for compatibility reasons, not for multi-user environment. They are all connected to same place, that's why stuff gets deleted "everywhere" when you delete it from one directory. Users should have each ones own directory (/data/media/0, /data/media/1, /data/media/2, etc...)
[One (M7) Original Android Development] Cotulla:
Tetris needs proper control. We have only 3 real harware button.

So it needs redesign...

Well it won't solve a problem :) I already can connect USB Stick 32Gb via USB Hub and etc. But this prevents me from debugging cuz it's also done by USB.
[One (M7) Original Android Development] lolerpro8:
I got an idea:

Back button left

Home right

Vol - accelerate

Vol + exit (or maybe it will be better for power button for that)

And i got to ask you. What was the hidden feature in magldr. Reaching 111111 is pretty impossible...
[One (M7) Original Android Development] MemoryController:
How do you access serial uart output on your bootloader? Do you run code to put usb into serial or are you using special cable, eg with resistor on ID-GND? I had one like this for my Galaxy S2 but it doesn't work anymore on my Galaxy S4.
[One (M7) Original Android Development] streetster:
NTFS supports symbolic links - from wikipedia, I've used them in the past...

e.g.

mklink /D "c:\link-here\" "c:\to-somewhere-else\"

I don't know how much effort would be involved using NTFS as the partition format over ext4, NTFS (read) support existed in the Linux kernel since 2.2.x. The NTFS-3G project supports symbolic links and looks to be the way forward.

Here's a thread by shardul_seth about his experience / progress on the matter.
[One (M7) Original Android Development] eXecuter.bin:
NTFS symlink are not the same as linux symlink, they're not compatible with one another.

Programs such as NTFS-3G simply allows you to access NTFS partitions once the system starts up, but that's about it. It does not allow you to install linux on a NTFS partition for a lot of different reasons, simply because NTFS does not support a lot of features such as linux permissions and etc.
[One (M7) Original Android Development] adwinp:
Do you really want to go to all that trouble for repartitioning?

I have a simpler solution: simply use a static lvm binary & cryptsetup if you want encryption, but if you want an automated solution, you need to have your key file somewhere on the device (for example repack it into the initrd, but then again, this defeats the purpose of encryption - it's like keeping your credit card & pin in the same place)

;]

1: manually pvcreate on mmcblk0p35-37 (for the international HTC One)

either create symlinks for the functions to the lvm binary or invoke it from the tool (lvm pvcreate /dev/block/mmcblk0p3x)

2: create the vg, add the 3 pvs, create your lv(s) + mkfs

You also need to modify the init.device.rc in the initrd (either directly or exec a script) accordingly to vary on the vg on boot before mounting

If you really need it, you can also modify your recovery to do the same instead of manually doing it from adb

Partitioning support via menu options for LVM would require more work though.

I've been using this since my days on the Desire HD with no issue.

I'm also using cryptsetup on my 64Gb microsdxc (on my tablet).

NOTE: you need to either add sleep for a few seconds in your script or invoke lvm vgscan & vgchange -ay early enough in order to allow the dm mappings to be created & settle

NOTE2 (off topic): For a lightning fast rom, you can also repackage it (/system) into a loop-mounted image which needs to be copied to a tmpfs.

The only downside is that you need to wait for the image to be copied on image boot (anywhere from 15-45s depending on the size of the system partition) & you need to remember to edit the image also if you're pushing anything to /system, otherwise the changes will disappear on the next reboot. Then again, this is only for purists ;]
[One (M7) Original Android Development] Cotulla:
I am not using UART, only USB Serial.

No, I don't want encryption.

I need solution to cut space from "userdata" for another purposes, like Windows RT.

Actually it's fake repartitioning, I am not going to modify main GPT, I am going to tell Limux/Android that it has less space in userdata than it is and use the rest for another purposes.

It should work I hope.
[One (M7) Original Android Development] lolerpro8:
But what about windows? Have you limited it also?
[One (M7) Original Android Development] munjeni:
First off all thank you for everything you done for HTC HD Mini and HTC HD2, I am glad to see a legend aka Cotulla here.

Thinking to buy One for my spare time, and I will make recovery for these purpose, but first of all waiting a result of Magldr, than for sure One is my next phone.

NTFS... do you mean about runing file based partitions (trought loop device) in NTFS?
[One (M7) Original Android Development] _kyo_:
I am not an expert but I know that in linux you can create a file and mount it as a partition.

Is it possible to create a file (with X size) in userdata , and then mount and use this file as a partition for your own purpose ?
[One (M7) Original Android Development] MemoryController:
Could you explain please the way to get debugging output?
[One (M7) Original Android Development] O_G:
Thread Cleaned​

Guys, this is a development thread, lets keep posts focused that way. I understand some are getting excited about this, but dont clutter the thread!​
[One (M7) Original Android Development] Cotulla:
I am working under USB MS (Mass Storage) support in MAGLDR.
[One (M7) Original Android Development] lolerpro8:
I will ask you something that crossed my mind. How are going to boot into recovery h-boot or magldr? I'm asking because we already need a recovery adapted to magldr since almost everything is changed.

+ will you have to increase the size of boot partition?
[One (M7) Original Android Development] Cotulla:
recovery loaded from HBOOT.

HBOOT loads only one: recovery.img or boot.img.

So if I replace boot.img with MAGLDR, recovery still will be booted directly after HBOOT without MAGLDR execution.

I am going to put a custom regions header at the start of "userdata", like "region name | region type | start sector | size in sectors"

Linux kernel should be hacked to handle this information. Inside GPT parser it should read the first sector of "userdata" and add additional partitions.

It's my current idea.

I see installation like that:

1)install MAGLDR via

fastboot flash boot MAGLDR.img

command

2)user boots to MAGLDR

now it's time to repartition userdata.

it can be done (on PC) by

*modified fastboot with additional commands / CUI interactions

*custom program based on fastboot protocol.

*custom program based on custom protocol.

I didn't decided my way, but using ADB driver from Google should be the best idea.

3)user can flash Android/Linux kernel in MAGLDR via

fastboot flash boot boot.img

command.

4)user can flash WRT in MAGLDR via

custom program, cuz fastboot is very limited protocol and not suitable for flashing big files.
[One (M7) Original Android Development] criszz:
please make this in a way we can choose another partition layout, witch exist on dual sim variant's . thx
[One (M7) Original Android Development] Cotulla:
it looks like USB MS is working now.

Made USB RAM stick with 1.5Gb storage.
[One (M7) Original Android Development] Stephen:
Thread cleaned

Agan development posts only please.
[One (M7) Original Android Development] xplus93:
How will this be set up to handle things like the radio, camera modules and such? Would you be able to just swap them out for different versions of the device? Mainly would you be able to change the radio modules/drivers so you could use it on carrier branded phones or CDMA devices? You mentioned UEFI working, is everything implemented through that?
[One (M7) Original Android Development] Cotulla:
Still no idea. It's like "start and see", hard to tell anything about feature.

I am working under touchscreen driver in the MAGLDR.
[One (M7) Original Android Development] KidCarter93:
Thread Cleaned

As mentioned previously by other moderators, keep all posts in this thread on topic and therefore restricted to development related posts.

If someone posts something other than that, please report it to us so that we can deal with it, rather than mentioning it yourself.

Thanks,

- KidCarter93
[One (M7) Original Android Development] voltigeur:
As far as i know the HTC One and Windows Phone 8x by HTC share some hardware. But i think the biggest isue are the partition and drivers
[One (M7) Original Android Development] orangekid:
I don't think they have much in common; different SoC, resolution, etc.
[One (M7) Original Android Development] xplus93:
PDAdb doesn't list any windows phone devices with thee same SoC. The one good thing as that the HTC One MAX is almost identical. It won't be too hard to eventually port to that device.
[One (M7) Original Android Development] blaze_cv:
Windows Phone 8X by HTC has a 720p display and SoC Qualcomm S4 Plus MSM8960 @1,5 GHz Dual Core

HTC One has a 1080p display and Snapdragon 600, Max have the same hardware but 16gb rom....

they are the same architecture (krait), and are very similar, so that the port will not be so difficult.
[One (M7) Original Android Development] voltigeur:
we will see. i know that microsoft had askt HTC to make WP edtion of the one. Does WP support Multi core soc above dual core? :confused:

---------- Post added at 10:46 PM ---------- Previous post was at 10:39 PM ----------

Both the display's are from sharp mabey good to know :victory:
[One (M7) Original Android Development] blaze_cv:
yup, it seems wp8 has support for multicore SoC.

dual core snapdragon and 1gb ram for 720p n` 512mb for WVGA, is a minimum requirements for wp8 (Wiki)
[One (M7) Original Android Development] hillbeast:
Windows Phone is now based on the NT kernel. I know the NT kernel theoretically supports hundreds of cores/threads, but they also impose limits, a least on the desktop and server editions, of a maximum number of threads to make it so people will buy the more expensive versions of Windows for their hardware. Whether this limit exists in Windows Phone, I can't say, but I do know RT supports quad core as the Surface RT and Surface 2 have them.
[One (M7) Original Android Development] EtherealRemnant:
WP8 Release 3 does:

"Windows Phone 8 is officially ready for phablets. Microsoft made the announcement Monday that an update to its operating system for mobile phones -- titled Windows Phone 8 Update 3 (in classically unimaginative Microsoft fashion) -- will now work on devices with screen sizes in the 5-inch-to-7-inch range.

In addition to scaling the OS for a larger screen, Windows Phone Update 3 will work for 1080p HD resolutions, the current favorite on big-screen smartphones.

Rounding out newfound hardware support is compatibility with quad-core processors, specifically Qualcomm's Snapdragon 800 workhorse. And there's very little besides."

http://reviews.cnet.com/windows/windows-phone-8-update/4505-3672_7-35829186.html
[One (M7) Original Android Development] gigsaw:
With the next WP release (GDR3, out during the first months of next year) will be supported more than two Cores. However HTC 8x and HTC one does have NOTHING in common, they are two totally different projects with almost no hardware in common. It we want to take two devices very similar but with different OS, we could look at Samsung galaxy s3 and samsung ativ s. But, As far As I know, is almost impossibile porting android on windows phone 8 not only because of MANY software issues (android totally lacks uefi support) but even because on windows phones 8 are blown some more fuses on the motherboard, so there is even an hardware protection. And I'm so sorry about that because till now only Cotulla (and Bepe, I say hello to him even he has gone away from the scene :) ) across the years have unlocked almost every windows mobile and windows phones on the earth, but, till now, cotulla isn' able to unlock Windows phones 8(I know he tried and probably he will try), and nobody else can (I consider reker's w1 a fortunate case lol). so no custom roms, no full unlock or anything else. Of course the biggest part of the people define the closed-source development a pain in the a*s because it's hard or almost impossible, but it's definetly more interesting than android developping. So I doubt that HTC one will become the new hd2. For sure many interesting things can be done, but nowdays the hardware (and the OSs that runs on the hardware) change more frequently than almost five years ago (consider that snapdragon 600 is already "old" in less than a year). Keep that in mind, now OEMs are aware that indipendent developers are playing a crucial role in marketing, more and more people before buying a phone look on xda to see how many roms support it. OEMs (especially HTC) can't let a phone live for 5 years. and they do have methos to make this not happen.
[One (M7) Original Android Development] xplus93:
We were talking about devices to use for cross-developing and apparently it turned into a debate. Mods we need another cleanup over here.
[One (M7) Original Android Development] gigsaw:
How can you talk about cross-developing when it isn't possibile at all?

Generally talking I see a poor knowledge of windows world because many things have been asked many many times in the past and answers are always the same, and there's nothing to debate about that:

-this kind of development is very DEVICE-specific. Not only SoC-specific, so no cross-development will be possible. HTC one max is an exception but no other devices that are now on the market could join the project.

-till now there's no public method to fully unlock WP8 (reker found a way for w1 but didn't release it)

-full unlock isn't necessary related to bootloader unlock. Full unlock is a kind of root for android, but in windows exsists different levels of root.

-android cannot be ported on WP8 devices because they have uefi boot and android doesn't support it, because there are even hardware protections

-WP8 and WRT can be ported to android but only cotulla knows how to manage uefi

-this project is STRICTLY closed-source because it's not legal. Microsoft and OEMs close their eyes on this even because DFT don't take money for that (in fact if you remember on hd2 you had to own a serial key to activate windows phone 7)
[One (M7) Original Android Development] jotha:
Guys we (you) are slowly drifting away from the purpose and topic of this thread. It is a development thread to bring forward cotulla's project, not a thread about the general possiblity of porting one OS or another. Please keep that in mind before posting.

Thanks
[One (M7) Original Android Development] Cotulla:
Well my current target is Windows RT.

gigsaw is telling right things in the general :)

"nobody knows who i am maybe you would understand"?

How do you know what I am doing? WTF :laugh: No, u don't.

Well, I can't call Android really open sourced system.

You often just can't get enough from those open sourced kernel drivers and etc.

Actually I wanna see running Windows PE (Setup) on HTC One and I am working in that direction at the current moment.
[One (M7) Original Android Development] munjeni:
Apsolutly TRUE! Oems doing these things about closig source code for us (definitely tricking changes in prebuilts for making them full non compatible with every new android version + android allso doing a bad things in api level by broking definitely support for old prebuilts) :(
[One (M7) Original Android Development] csoulr666:
I have a question, Why is Windows RT you main focus??? Why not WP8? Windows RT isn't well received and it will most probably merge with WP sometime in the future IMHO