android
  #201  
Old 03-09-2011, 09:32 AM
SekraSoft SekraSoft is offline
Junior Member
 
Join Date: Mar 2011
Posts: 11
Default

Lorenz092, I tried to rewrite sources ( \ -> /, : -> / ) 10-15 minutes ago.
They are in code.zip

I do not know will it works or no. I changed sources using only intuition (without compiler and linux) so I recomend you DO NOT RUN IT on computer which have important data or you should deny acces to all important folders.
Attached Files
File Type: zip code.zip (5.0 KB, 2 views)
Reply With Quote

Advertisement [Remove Advertisement]

  #202  
Old 03-09-2011, 10:55 AM
Lorenz092 Lorenz092 is offline
Member
 
Join Date: Jan 2011
Location: Italy
Posts: 449
Default

Quote:
Originally Posted by SekraSoft View Post
Lorenz092, I tried to rewrite sources ( \ -> /, : -> / ) 10-15 minutes ago.
They are in code.zip

I do not know will it works or no. I changed sources using only intuition (without compiler and linux) so I recomend you DO NOT RUN IT on computer which have important data or you should deny acces to all important folders.
Good...but i tried befored you posted these
Results: I had to change something, but it worked. Not good because of the different path separators (i saw that you changed them, so now i'll try to recompile them )

In linux direct.h doesn't exists-> sys/stat.h instead

EDIT: it is better to use defines, so one source is good for many platforms
Reply With Quote

  #203  
Old 03-09-2011, 11:11 AM
SekraSoft SekraSoft is offline
Junior Member
 
Join Date: Mar 2011
Posts: 11
Default

Lorenz092: Good luck...
Reply With Quote

  #204  
Old 03-09-2011, 11:11 AM
Lorenz092 Lorenz092 is offline
Member
 
Join Date: Jan 2011
Location: Italy
Posts: 449
Default

Here the new source file (for now only unpacker as I've got no time ) and also the executable! No special libs are used...
(the code is to cleaned, like good identation, though)
Please see the changes because I've not tested it carefully...but the extraction works well!
Attached Files
File Type: zip unpacker.zip (6.2 KB, 11 views)
Reply With Quote

  #205  
Old 03-09-2011, 12:17 PM
SekraSoft SekraSoft is offline
Junior Member
 
Join Date: Mar 2011
Posts: 11
Default

Quote:
Originally Posted by Lorenz092 View Post
EDIT: it is better to use defines, so one source is good for many platforms
Yes... But when I wrote this programs I thinked "oh, it should work, it should work as fast as I can write, no matter how"
Quote:
Originally Posted by Lorenz092 View Post
Here the new source file
Good... But MSVS can't find stdint.h.
So I rewrote this file and now:
* MSVS can compile it
* you can see my russian comments (about file format) (you killed them when you opened my file in CP1251 using your encoding ) and english (very bad english) translations.
+ I returned macros GET(offset) to its old state because we defined "uint"

Lorenz092, new sysdata.bin equals to original after repacking cycle using your edition of unpacker. So it works under windows.
Attached Files
File Type: zip unpacker.zip (2.9 KB, 7 views)

Last edited by SekraSoft; 03-09-2011 at 12:29 PM.
Reply With Quote

  #206  
Old 03-10-2011, 05:55 AM
Lorenz092 Lorenz092 is offline
Member
 
Join Date: Jan 2011
Location: Italy
Posts: 449
Default

Quote:
Originally Posted by SekraSoft View Post
Yes... But when I wrote this programs I thinked "oh, it should work, it should work as fast as I can write, no matter how"

Good... But MSVS can't find stdint.h.
So I rewrote this file and now:
* MSVS can compile it
* you can see my russian comments (about file format) (you killed them when you opened my file in CP1251 using your encoding ) and english (very bad english) translations.
+ I returned macros GET(offset) to its old state because we defined "uint"

Lorenz092, new sysdata.bin equals to original after repacking cycle using your edition of unpacker. So it works under windows.
Good
Later I'll fix the packer

EDIT: hey slade! where are u? We need to test the new packer...or i can actually with linux try to repack the ROM file and then lebellium can test it! Right?

EDIT2:

Quote:
Originally Posted by slade View Post
Reserved for Changelogs

Last 4 Kernel builds failed. Still stuck on includes and porting MX37 to new Kernel
If I really understood, the main problem of running Android is the linux kernel that must be upgraded, right?
And with RockBox? What are the problems here? If I were able to flash and reflash without restrictions...This is the main issue testing I think.
But before that we need to mod some contents of the original firmware

EDIT3: i found something that could maybe be interesting! http://www.timesys.com/supported/processors/freescale
In this page you can find (for free??) some small linux images for freescale processors, and maybe an updated version of kernel for the mx37

Last edited by Lorenz092; 03-12-2011 at 01:52 PM.
Reply With Quote

  #207  
Old 03-13-2011, 09:29 AM
Lorenz092 Lorenz092 is offline
Member
 
Join Date: Jan 2011
Location: Italy
Posts: 449
Default

As I previously said, here the linux version of the packer! Tested with the original files and then compared both sysdata's (cmp linux cmd): they're the same!
@Sekra: i had to add some modifications, please see them

The usage is the same as the windows version...Included sources, object file (I don't know if it is really useful) and executable ready to use!

EDIT: the program works but maybe we should clean the sources a bit . I was thinking also to store them in google code (I...you must decide ), to keep track of changes and other things!
Attached Files
File Type: zip packer_linux.zip (26.8 KB, 13 views)
Reply With Quote

  #208  
Old 03-13-2011, 09:43 AM
SekraSoft SekraSoft is offline
Junior Member
 
Join Date: Mar 2011
Posts: 11
Default

Quote:
Originally Posted by Lorenz092 View Post
As I previously said, here the linux version of the packer! Tested with the original files and then compared both sysdata's (cmp linux cmd): they're the same!
@Sekra: i had to add some modifications, please see them
I will check you changes under Windows.
Quote:
Originally Posted by Lorenz092 View Post
EDIT: the program works but maybe we should clean the sources a bit .
Ohoho.
Quote:
Originally Posted by Lorenz092 View Post
I was thinking also to store them in google code (I...you must decide ), to keep track of changes and other things!
I think it is good idea. But I can only make programs and do not know what should I do. So you should publish sources in G.C.
----------------------
EDIT 1:
I saw your changes. All have started to work (MSVS) when I replace "#include <dir.h>" to "#include <direct.h>"
And I don't find whre you define "uint". I see only my "#define uint unsigned __int32" for Windows & MSVS and your "#define __int64 int64_t" for Linux. I think it is magic.
+ All is OK under Win32. New sysdata.bin is good.
----------------------
EDIT 2:
What should we change (places where we can optimize)
1. Packer: int read_dir(uint parent); I think we can rewrite code and it will work without uint str_offset;
(for people who count every byte in stack and have veeeeeery fast acces to files)
2. Unpacker: archive (packed file) is being loaded in memory entirely so we may rewrite it. (for people who thinks that 30+ Mb for sysdata.bin is very bad or for very big files) But program may work slowly (I think I read every byte olny one time so we should read file only one time and file don't need to be loaded in memory. But I use random acces so some of bytes will be read twice or more times (because we have HDD). But we have a cache. But it can "forget" something and read again... And we have a swap... So I stop to think and say "I don't know".)
3. Packer & unpacker are work with 32b sizes of file (because all offsets is 32b) So it can't unpack archive whitch size is more 2GB.
4. We can don't define "LOG_ALL" or disable logging
5. We can rewrite packer and set buf_size=(2^N) or change last number in pack.ini to (2^N). "2^N" is not expression "2^N", it is requirenemt for number. This magic is for best memory allocating, fastest working of fread & fwrite, for best interaction with cache. Because usually some buffers have size 2^N.
6..infinity. Somebody may find something to add to this list
But we should not change this because we will waste much time and not find visible changes of repacking time for sysdata.bin

Last edited by SekraSoft; 03-13-2011 at 11:44 AM.
Reply With Quote

  #209  
Old 03-13-2011, 11:54 AM
Lorenz092 Lorenz092 is offline
Member
 
Join Date: Jan 2011
Location: Italy
Posts: 449
Default

Quote:
Originally Posted by SekraSoft View Post
I will check you changes under Windows.

Ohoho.

I think it is good idea. But I can only make programs and do not know what should I do. So you should publish sources in G.C.
----------------------
EDIT 1:
I saw your changes. All have started to work (MSVS) when I replace "#include <dir.h>" to "#include <direct.h>"
And I don't find whre you define "uint". I see only my "#define uint unsigned __int32" for Windows & MSVS and your "#define __int64 int64_t" for Linux. I think it is magic.
+ All is OK under Win32. New sysdata.bin is good.
----------------------
EDIT 2:
What should we change (places where we can optimize)
1. Packer: int read_dir(uint parent); I think we can rewrite code and it will work without uint str_offset;
(for people who count every byte in stack and have veeeeeery fast acces to files)
2. Unpacker: archive (packed file) is being loaded in memory entirely so we may rewrite it. (for people who thinks that 30+ Mb for sysdata.bin is very bad or for very big files) But program may work slowly (I think I read every byte olny one time so we should read file only one time and file don't need to be loaded in memory. But I use random acces so some of bytes will be read twice or more times (because we have HDD). But we have a cache. But it can "forget" something and read again... And we have a swap... So I stop to think and say "I don't know".)
3. Packer & unpacker are work with 32b sizes of file (because all offsets is 32b) So it can't unpack archive whitch size is more 2GB.
4. We can don't define "LOG_ALL" or disable logging
5. We can rewrite packer and set buf_size=(2^N) or change last number in pack.ini to (2^N). "2^N" is not expression "2^N", it is requirenemt for number. This magic is for best memory allocating, fastest working of fread & fwrite, for best interaction with cache. Because usually some buffers have size 2^N.
6..infinity. Somebody may find something to add to this list
But we should not change this because we will waste much time and not find visible changes of repacking time for sysdata.bin
I agree haha...seriously good ideas and good it works...
For the google code is not a problem...I can do it, have you got a gmail access? To become the main developer...

I'm quite new to C++ and I don't know really how is the best solution to manage files but with python i used to define a BUFFER (like 1 MB), then read this amount of data, do what you have to do, and then read this data again until EOF.

Then another idea is to add some error codes (like you previous said)

Before that, we need to test if the basics work really in the real device (I mean a new modified sysdata...like my soundmod)
Oh man I should also port the python aui modder to C++! (I'll do it when I'll got some free time to learn also some C++ tricks)

All in all, nice!
Reply With Quote

  #210  
Old 03-13-2011, 12:26 PM
SekraSoft SekraSoft is offline
Junior Member
 
Join Date: Mar 2011
Posts: 11
Default

Quote:
Originally Posted by Lorenz092 View Post
I can do it, have you got a gmail access? To become the main developer...
I think I have: sekrasoft at gmail.com
Quote:
Originally Posted by Lorenz092 View Post
I'm quite new to C++ and I don't know really how is the best solution to manage files but with python i used to define a BUFFER (like 1 MB), then read this amount of data, do what you have to do, and then read this data again until EOF.
It is for unpacker, is not it? So we should keep filesystem (first kilobytes of sysdata.bin) in memory. Or do not making changes in program.
Quote:
Originally Posted by Lorenz092 View Post
Then another idea is to add some error codes (like you previous said)
Yes... Now they are only 0 (now errors) and 1...
Quote:
Originally Posted by Lorenz092 View Post
Before that, we need to test if the basics work really in the real device
I am speaking about running repacking under linux and about optimization... But nobody said that player is working...
Quote:
Originally Posted by Lorenz092 View Post
Oh man I should also port the python aui modder to C++! (I'll do it when I'll got some free time to learn also some C++ tricks)
I don't like object oriented programming so I use C every day but not C++
Reply With Quote

  #211  
Old 03-14-2011, 04:35 AM
slade slade is offline
Member
 
Join Date: Oct 2010
Posts: 118
Default

hey guys,
some good news.
Android did a boot and crashed right at the android booting screen. I somewhat managed to hack together a filesystem from other arm v6 phones. but I am still using the samsung kernel which i guess will make it impossible to boot android normaly. so now the bad news
kernel is still the old one and I haven't been able to compile a working one with the needed changes for imx37 architecture. I hope i will be able someday to get the kernel compiled. but i am unsure if i'll manage to keep the r0 samsung firmware intact. I need space loooots of space for android my best guess will be to kexec into the other kernel and load fs out of an image if thats even possible, but for now i was happy to see the booting screen for 1 second

have a good day guys
Reply With Quote

  #212  
Old 03-14-2011, 06:44 AM
MademoiselleGeek's Avatar
MademoiselleGeek MademoiselleGeek is offline
Junior Member
 
Join Date: Mar 2011
Location: Germany
Posts: 6
Default

Hey guys!
I've been following this thread since the very beginning. Just registered to tell you that you've got another cheerleader.
This is quite cool. I like the idea of using Android on my YPR0.
My C++ skills aren't good enough - or else I'd started contributing long ago. Sorry.
Reply With Quote

  #213  
Old 03-14-2011, 10:57 AM
Lorenz092 Lorenz092 is offline
Member
 
Join Date: Jan 2011
Location: Italy
Posts: 449
Default

Quote:
Originally Posted by slade View Post
hey guys,
some good news.
Android did a boot and crashed right at the android booting screen. I somewhat managed to hack together a filesystem from other arm v6 phones. but I am still using the samsung kernel which i guess will make it impossible to boot android normaly. so now the bad news
kernel is still the old one and I haven't been able to compile a working one with the needed changes for imx37 architecture. I hope i will be able someday to get the kernel compiled. but i am unsure if i'll manage to keep the r0 samsung firmware intact. I need space loooots of space for android my best guess will be to kexec into the other kernel and load fs out of an image if thats even possible, but for now i was happy to see the booting screen for 1 second

have a good day guys
Good good goooood
But for rockbox?
EDIT: ah and sekra have done a functional packager...both for win and linux! YOu should test to mod it with my previous default.aui modded and test if works...
Reply With Quote

  #214  
Old 03-14-2011, 05:10 PM
slade slade is offline
Member
 
Join Date: Oct 2010
Posts: 118
Default

ok guys, i am switching compiles now instead of code sourcery i am switiching to android compiler arm-eabi-4.4.0.
I think i am getting close to get the source code for the kernel done. I have only a few errors left but they are bugging me like crazy. Next step will be a full vendor setup and then figure out to a)how to make new rootfs work b) dual boot and c) where and how to store android so it could actually boot and be put inside the rom file
Reply With Quote

  #215  
Old 03-14-2011, 05:53 PM
SprayMyPerfume SprayMyPerfume is offline
Junior Member
 
Join Date: Dec 2010
Posts: 11
Default

Any images of android on the Samsung R0? I want to see the device in detail.
Reply With Quote

  #216  
Old 03-15-2011, 03:13 AM
slade slade is offline
Member
 
Join Date: Oct 2010
Posts: 118
Default

not that far yet to show anything really basically nothing is working
Reply With Quote

  #217  
Old 03-15-2011, 12:20 PM
Appick's Avatar
Appick Appick is offline
Junior Member
 
Join Date: Mar 2011
Location: France
Posts: 83
Default

Quote:
Originally Posted by MademoiselleGeek View Post
Hey guys!
I've been following this thread since the very beginning. Just registered to tell you that you've got another cheerleader.
This is quite cool. I like the idea of using Android on my YPR0.
My C++ skills aren't good enough - or else I'd started contributing long ago. Sorry.
We'll have to set up a cheerleading team ......... might have to shave my knees though if I have to wear a frilly skirt!
__________________
Appick
Reply With Quote

  #218  
Old 03-15-2011, 02:25 PM
MademoiselleGeek's Avatar
MademoiselleGeek MademoiselleGeek is offline
Junior Member
 
Join Date: Mar 2011
Location: Germany
Posts: 6
Default

Quote:
Originally Posted by Appick View Post
We'll have to set up a cheerleading team ......... might have to shave my knees though if I have to wear a frilly skirt!
lol, it's cooler if you don't. Besides, the hair and the frills will interlock and therefore keep your skirt down.
__________________
In my experience, guys like tech-savvy girls.
At least till the girl finds their fantasy-named account in a social network, just having known one of the guy's interests. Then it's suddenly considered stalking....
Reply With Quote

  #219  
Old 03-15-2011, 02:53 PM
Lorenz092 Lorenz092 is offline
Member
 
Join Date: Jan 2011
Location: Italy
Posts: 449
Default

Slade you're the best
But I think you lost my post where I found a site "offering" some linux kernel versions for the mx37...I don't actually explored it but it may be useful!

Good luck!!! (because also coding is sometimes questions of luck )
Reply With Quote

  #220  
Old 03-16-2011, 01:48 PM
Lorenz092 Lorenz092 is offline
Member
 
Join Date: Jan 2011
Location: Italy
Posts: 449
Default

Maybe I'm crazy but I was thinking about the sd card. Now I haven't any little sd but I use to boot linux on a fuc***ng ARM (Via WM8505) netbook (it is really slow...but i'm not here to speak about it ) via the SD card.
The card is simply formatted and splitted into 2 partitions (well I use a usb stick formatted in ext to do the trick but it is the same). The first is bootable fat that contains the kernel and boot related files (I'm not really expert in those things...) and the ext partition is the linux filesystem.
Turning device on, shows a half second the original ce bootscreen and then boots up the sd. I read that this device has U-BOOT, and it hasn't any bios.

Is the imx37 capable to boot from sd? if so is it really useful for us? I think yes! In particular it is useful to do every test without touching the internal flash (I'm really curios to experiment but i can't )

And now a question: in fact what does the bootloader do? Preload kernel? Or initialize hardware?

Some links:

- Discussion about sd booting (read between the comments)
http://imxcommunity.org/group/imx23/...3AGroup%3A1488

- Bentoo linux (fat part and ext part)
http://bento-linux.org/wiki/vt8505/wm8505/debian

If this could be useful, ok, otherwise no problem

EDIT: other links about mx37

http://www.google.it/url?sa=t&source...QC8O8A&cad=rja
Reply With Quote

Reply

Tags
r0, rockbox, samsung yp-r0

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump



All times are GMT -5. The time now is 08:27 PM.