Author Topic: 550D/T2i raw video recording port official thread  (Read 771165 times)

dlrpgmsvc

  • Senior
  • ****
  • Posts: 398
  • The 7D and 50D Robin Hood
Re: 550D raw video recording port official thread
« Reply #300 on: June 01, 2013, 03:43:37 PM »
I think we just need these addresses to make it fit our firmware, if I am right?
#define HIJACK_CACHE_HACK_BSS_END_ADDR   0xFF01109C
#define HIJACK_CACHE_HACK_BSS_END_INSTR  0xFF010134

If you have Windows, follow my advice in the head post here (I keep it updated very frequently!!) , in order to disassemble directly from Windows !

Also, i found these instructions in our ROM1.BIN that "1%" user says are the start and end of allocation memory: i hope they are what we are searching for :

0xFF011CB4     E3A0160D     MOV R1,#0xD00000 (start address of allocation memory ?)
0xFF011CB8     E3A0083D     MOV R0,#0x3D0000 (end address of allocation memory ?)

So 1% says to subtract the value 0xA0000 (640k) to both 0xD00000 and 0x3D0000 values
0D00000 - A0000 = C60000

From tragic lantern for 600D we have :
---------------------------------------------------------------------------------
//MOV     R1, #0xD00000 C60000
// load ML in the AllocateMemory pool
#define HIJACK_CACHE_HACK_BSS_END_ADDR 0xFF0123E4
//0xA0000 - 640K Should Be enough for everyone
#define HIJACK_CACHE_HACK_BSS_END_INSTR 0xE3A018C6


 //~ MOV     R0, #0x3D0000 330000
//~ fixup start address of AllocateMemory pool 0x8F0000
#define HIJACK_CACHE_HACK_ALLOCMEM_SIZE_ADDR 0xFF0123E8
//0x7D0000
#define HIJACK_CACHE_HACK_ALLOCMEM_SIZE_INSTR 0xE3A00833
-----------------------------------------------------------------------------------

So, for us, we should have :
#define HIJACK_CACHE_HACK_BSS_END_ADDR 0xFF011CB4           <- Our address of the first instruction
#define HIJACK_CACHE_HACK_BSS_END_INSTR 0xE3A018C6   <- The machine code of new value (start value)
#define HIJACK_CACHE_HACK_ALLOCMEM_SIZE_ADDR 0xFF011CB8  <- Our address of the second instruction
#define HIJACK_CACHE_HACK_ALLOCMEM_SIZE_INSTR 0xE3A00833  <- The machine code of new value (end value)

The machine-codes of 600D and 550D are the same, because they have the same processors and so same instructions-sets and coding for them.

And don't forget this value also, specific for our 550D :

#define HIJACK_CACHE_HACK_INITTASK_ADDR             0xFF018D1C     
If you think it's impossible, you have lost beforehand

sonic

  • New to the forum
  • *
  • Posts: 23
  • 550D
Re: 550D raw video recording port official thread
« Reply #301 on: June 01, 2013, 03:51:12 PM »
Do you have found the disassembly start address of both ROM files ? And what they are ?
Do you have found what is the rom file where there is the stuff we are searching for ? ROM0.BIN or ROM1.BIN ?

Neither of them, I think. I modified debug.dump_rom_task() to dump another ROM2.BIN
Then do
Code: [Select]
./disassemble.pl 0xFF000000 ROM1.BIN
But I didn't investigate further, since xaint has already solved it, hasn't he?

mk11174

  • Contributor
  • Hero Member
  • *****
  • Posts: 809
Re: 550D raw video recording port official thread
« Reply #302 on: June 01, 2013, 04:11:21 PM »


So, for us, we should have :
#define HIJACK_CACHE_HACK_BSS_END_ADDR 0xFF011CB4           <- Our address of the first instruction
#define HIJACK_CACHE_HACK_BSS_END_INSTR 0xE3A018C6   <- The machine code of new value (start value)
#define HIJACK_CACHE_HACK_ALLOCMEM_SIZE_ADDR 0xFF011CB8  <- Our address of the second instruction
#define HIJACK_CACHE_HACK_ALLOCMEM_SIZE_INSTR 0xE3A00833  <- The machine code of new value (end value)
That leads to no boot with just red flashing light.
500D/T1i  550D/T2i  600D/T3i  700D/T5i

dlrpgmsvc

  • Senior
  • ****
  • Posts: 398
  • The 7D and 50D Robin Hood
Re: 550D raw video recording port official thread
« Reply #303 on: June 01, 2013, 04:14:00 PM »
That leads to no boot with just red flashing light.

have you added also : #define HIJACK_CACHE_HACK_INITTASK_ADDR             0xFF018D1C       ?
If you think it's impossible, you have lost beforehand

mk11174

  • Contributor
  • Hero Member
  • *****
  • Posts: 809
Re: 550D raw video recording port official thread
« Reply #304 on: June 01, 2013, 04:32:14 PM »
have you added also : #define HIJACK_CACHE_HACK_INITTASK_ADDR             0xFF018D1C       ?
That boots cam but ML doesnt load at all.
500D/T1i  550D/T2i  600D/T3i  700D/T5i

dlrpgmsvc

  • Senior
  • ****
  • Posts: 398
  • The 7D and 50D Robin Hood
Re: 550D raw video recording port official thread
« Reply #305 on: June 01, 2013, 04:33:44 PM »
That boots cam but ML doesnt load at all.

Ok, you have to go to the ML source directory PLATFORM/550d.109 and edit the file named "Makefile" : find the line "#RESTARTSTART = 0xC80100" and change the old pre-existent value to the new value (HIJACK_CACHE_HACK_BSS_END_INSTR + 100)

So we know that :
#define HIJACK_CACHE_HACK_BSS_END_INSTR 0xE3A018C6   
And hence :
0xE3A018C6 + 100 = 0xE3A019C6
And so, finally :
#RESTARTSTART = 0xE3A019C6  (into Makefile)
If you think it's impossible, you have lost beforehand

a1ex

  • Administrator
  • Hero Member
  • *****
  • Posts: 12360
  • Quarantined
Re: 550D raw video recording port official thread
« Reply #306 on: June 01, 2013, 04:43:39 PM »
Why are you messing with this in the first place?!

dlrpgmsvc

  • Senior
  • ****
  • Posts: 398
  • The 7D and 50D Robin Hood
Re: 550D raw video recording port official thread
« Reply #307 on: June 01, 2013, 04:45:03 PM »
Why are you messing with this in the first place?!

? what is wrong ?  :o
If you think it's impossible, you have lost beforehand

shawnwytch

  • New to the forum
  • *
  • Posts: 28
Re: 550D raw video recording port official thread
« Reply #308 on: June 01, 2013, 04:46:37 PM »
That boots cam but ML doesnt load at all.

Im noticing that when u go up in resolution it records in a higher bitrate would telling the camera to record at a certin bitrate change how much buffer is needed? Just wondered if that would help any?

mk11174

  • Contributor
  • Hero Member
  • *****
  • Posts: 809
Re: 550D raw video recording port official thread
« Reply #309 on: June 01, 2013, 04:57:28 PM »
Why are you messing with this in the first place?!
lol, we have been trying to get more memory to make ML load all features with Raw rec so we don't have to disable features just to get it to load. Right now we are trying to figure out Hijack Cache
500D/T1i  550D/T2i  600D/T3i  700D/T5i

dlrpgmsvc

  • Senior
  • ****
  • Posts: 398
  • The 7D and 50D Robin Hood
Re: 550D raw video recording port official thread
« Reply #310 on: June 01, 2013, 04:59:31 PM »
Right now we are trying to figure out Hijack Cache

Have you done my last hint ? Do it works ?
If you think it's impossible, you have lost beforehand

dlrpgmsvc

  • Senior
  • ****
  • Posts: 398
  • The 7D and 50D Robin Hood
Re: 550D raw video recording port official thread
« Reply #311 on: June 01, 2013, 05:01:31 PM »
Right now we are trying to figure out Hijack Cache

Also, very important :

don't forget to replace ifdef 6D with
#ifdef HIJACK_CACHE_HACK_ALLOCMEM_SIZE_ADDR in boot-hack.c and get rid of allocate mem in internals.h
If you think it's impossible, you have lost beforehand

mk11174

  • Contributor
  • Hero Member
  • *****
  • Posts: 809
Re: 550D raw video recording port official thread
« Reply #312 on: June 01, 2013, 05:03:04 PM »
Have you done my last hint ? Do it works ?
not yet, Alex scared me when he came in at that point.
500D/T1i  550D/T2i  600D/T3i  700D/T5i

dlrpgmsvc

  • Senior
  • ****
  • Posts: 398
  • The 7D and 50D Robin Hood
Re: 550D raw video recording port official thread
« Reply #313 on: June 01, 2013, 05:08:03 PM »
not yet, Alex scared me when he came in at that point.

Don't worry, what I'm sayng to you are hints directly from 1% that replied to me in a private msg !  ;)

So, proceed with my last hint about makefile and take note about the #ifdef of my last post... we are so close !  8)
If you think it's impossible, you have lost beforehand

xaint

  • New to the forum
  • *
  • Posts: 46
Re: 550D raw video recording port official thread
« Reply #314 on: June 01, 2013, 05:12:00 PM »
Hi guys, you can find the cache_hack i've made, in my repo, if you wanna try:
I think it is here: https://bitbucket.org/xaint/ml/commits/f3631da68349f1dda86ee136bbddc5a3c4efc9bc
Try it on your own risk (for me it's pretty stable) :D:D




(I'm just now editing the test shots, what i've made)

mk11174

  • Contributor
  • Hero Member
  • *****
  • Posts: 809
Re: 550D raw video recording port official thread
« Reply #315 on: June 01, 2013, 05:13:41 PM »
Hi guys, you can find the cache_hack i've made, in my repo, if you wanna try:
I think it is here: https://bitbucket.org/xaint/ml/commits/f3631da68349f1dda86ee136bbddc5a3c4efc9bc
Try it on your own risk (for me it's pretty stable) :D:D

Ahh, there we go, cool, thanks man!

Update: Yep, 640k cool!! Thanks again xaint
500D/T1i  550D/T2i  600D/T3i  700D/T5i

dlrpgmsvc

  • Senior
  • ****
  • Posts: 398
  • The 7D and 50D Robin Hood
Re: 550D raw video recording port official thread
« Reply #316 on: June 01, 2013, 05:25:16 PM »
Hi guys, you can find the cache_hack i've made, in my repo, if you wanna try:
I think it is here: https://bitbucket.org/xaint/ml/commits/f3631da68349f1dda86ee136bbddc5a3c4efc9bc
Try it on your own risk (for me it's pretty stable) :D:D

Whoa ! BINGOOO !!! Great work !!! Here we  are !!! Finally !!!  ;)   8)
If you think it's impossible, you have lost beforehand

xaint

  • New to the forum
  • *
  • Posts: 46
Re: 550D raw video recording port official thread
« Reply #317 on: June 01, 2013, 05:25:24 PM »
Ahh, there we go, cool, thanks man!

Update: Yep, 640k cool!! Thanks again xaint

If the changes what i've made are working, how can i push it to the main repo? Only the three affected files, without having to spoil something? :) Pull request?)
Thanks in advance ;)

dlrpgmsvc

  • Senior
  • ****
  • Posts: 398
  • The 7D and 50D Robin Hood
Re: 550D raw video recording port official thread
« Reply #318 on: June 01, 2013, 05:27:41 PM »
If the changes what i've made are working, how can i push it to the main repo? Only the three affected files, without having to spoil something? :) Pull request?)
Thanks in advance ;)

hg commit
then PUSH to your repo (if you have made a repo online with bitbucket)
then make a pull request from your repo to Hudson repo (the official one)
If you think it's impossible, you have lost beforehand

dlrpgmsvc

  • Senior
  • ****
  • Posts: 398
  • The 7D and 50D Robin Hood
Re: 550D raw video recording port official thread
« Reply #319 on: June 01, 2013, 05:28:58 PM »
If the changes what i've made are working, how can i push it to the main repo? Only the three affected files, without having to spoil something? :) Pull request?)
Thanks in advance ;)

Have you checked all the hints in the head post and the last I written to mk11174, so to be in phase with the mods ?  ;) They are 100% certified from... 1% !  ;D
If you think it's impossible, you have lost beforehand

mk11174

  • Contributor
  • Hero Member
  • *****
  • Posts: 809
Re: 550D raw video recording port official thread
« Reply #320 on: June 01, 2013, 05:33:40 PM »
For all you guys that can't wait for the pull to be added!

Thank Xaint for the mem fix!

http://www.mediafire.com/download/145ctnwr5de524c/ML_Mem_All.zip
500D/T1i  550D/T2i  600D/T3i  700D/T5i

dlrpgmsvc

  • Senior
  • ****
  • Posts: 398
  • The 7D and 50D Robin Hood
Re: 550D raw video recording port official thread
« Reply #321 on: June 01, 2013, 05:36:29 PM »
@xaint and @mk11174 : Very good work, boys !

Only one very important pray : do not erase your repos and modifications ! Don't think they are not useful because another programmer did it yet the same ! Keep all your work, because it may be useful to dig into the differences (if there are any) between your sources and the Others sources, in the case something wrong or bugs should arise in the next or long future !

Many thanks to all of you !!  ;)
If you think it's impossible, you have lost beforehand

mk11174

  • Contributor
  • Hero Member
  • *****
  • Posts: 809
Re: 550D raw video recording port official thread
« Reply #322 on: June 01, 2013, 05:38:16 PM »
@xaint and @mk11174 : Very good work, boys !

Only one very important pray : do not erase your repos and modifications ! Don't think they are not useful because another programmer did it yet the same ! Keep all your work, because it may be useful to dig into the differences (if there are any) between your sources and the Others sources, in the case something wrong or bugs should arise in the next or long future !

Many thanks to all of you !!  ;)
You too man! Without your posts things would have gone much much slower I am sure!
500D/T1i  550D/T2i  600D/T3i  700D/T5i

xaint

  • New to the forum
  • *
  • Posts: 46
Re: 550D raw video recording port official thread
« Reply #323 on: June 01, 2013, 05:44:53 PM »
Have you checked all the hints in the head post and the last I written to mk11174, so to be in phase with the mods ?  ;) They are 100% certified from... 1% !  ;D

Yes i've checked the hints in the head post, and i've used it really often, so thank you!

Also, very important :

don't forget to replace ifdef 6D with
#ifdef HIJACK_CACHE_HACK_ALLOCMEM_SIZE_ADDR in boot-hack.c and get rid of allocate mem in internals.h

I'm not sure if this is needed!


You too man! Without your posts things would have gone much much slower I am sure!

And that's very true! So thanks again :)

a1ex

  • Administrator
  • Hero Member
  • *****
  • Posts: 12360
  • Quarantined
Re: 550D raw video recording port official thread
« Reply #324 on: June 01, 2013, 05:57:41 PM »
I recommend keeping the classic boot method (I prefer to avoid cache hacks if possible); in theory, all you have to do is to adjust this:

Quote
    // change end limit to 0xc80000 => reserve 512K for ML
    // thanks to ARMada by g3gg0 for the black magic :)
    *addr_AllocMem_end = MOV_R1_0xC80000_INSTR; // <--- replace this with the new instruction (0xE3A00833), adjust RESTARTSTART, replace the 512's with 640 and that should do it
    ml_reserved_mem = 512 * 1024;

BTW, my plan is to keep ML slim and load things on demand, rather than just making it bigger and bigger.