CHDK Forum

CHDK Development => General Discussion and Assistance => Topic started by: muttley on 26 / December / 2007, 16:59:42

Title: A550 Porting...
Post by: muttley on 26 / December / 2007, 16:59:42
I made dump of firmware many times and now it's stable and don't change...I used blink g7.

Now i would compile CHDK source, but i don't understand how modify boot.c file, lib.c, stubs_entry_2.S and others file.

I have ARM compiler, CHDK source code, IDA and firmware dump...
How to use IDA for find part of code needed for compilation ?!?  :'(

I have read: Adding support of a new camera - CHDK Wiki (http://chdk.wikia.com/wiki/Adding_support_of_a_new_camera) and Loading dump to IDA - CHDK Wiki (http://chdk.wikia.com/wiki/Loading_dump_to_IDA)

but don't understand WHERE and WHAT find with ida?!? :o

I try to compile with folder of a630 (similar p-id) but don't find many function at the end of compilation time 

i had made also a wiki page: A550 - CHDK Wiki (http://chdk.wikia.com/wiki/A550)

HELP...PLEASE!!

p.s. sorry for my english  :P

Title: Re: A550 Porting...need help
Post by: GrAnd on 26 / December / 2007, 17:33:27
I made dump of firmware many times and now it's stable and don't change...
Where can I have it? :) Please upload it somewhere and post the link here.
Title: Re: A550 Porting...need help
Post by: Divalent on 27 / December / 2007, 00:27:59
I made dump of firmware many times and now it's stable and don't change...
Where can I have it? :) Please upload it somewhere and post the link here.

And also put a link to the FW on the Wiki page that you created so that others can find it (and know that it exists)
Title: Re: A550 Porting...need help
Post by: muttley on 27 / December / 2007, 07:03:19
this is the link: http://rapidshare.com/files/79372562/OriginalFirmware_a550v100c.rar.html

...but if you can...i would learn how to complete my port. Thanks...thanks!!!
Title: Re: A550 Porting...need help
Post by: ctrl-alt-canc on 30 / December / 2007, 10:54:19
Hi I'm new in this forum
I have an a550 and I'd like to contribute in porting the chdk to this camera.
Here's what I did until now:
-installed arm-elf-gcc
-downloaded the firmware
-created an a550 directory in /loader and /platform and copied the files from the a560 directory
-copied the firmware in /100c directory and renamed PRIMARY.BIN
-modified makefile.inc with 12624 (0x3150) as P-ID
-successfully compiled the trunk version for the a550
but when I put the files in the SD card and try to start the chdk the camera stops responding and I have to remove the batteries. I think it's normal, now it's time to disassemble the firmware.
ida does not work on my PC (don't know why) so I've used arm-elf-objdump to disassemble the firmware.

Now the questions:
-after rebooting the camera I find a file UpgradeLog.txt that contains 88 bytes of binary data, is that normal?
-now what I have to do? what I need to find in the disassembled firmware to get the chdk working?

Last thing:
When looking into the binary firmware with I found a link to a website hidden between binary data, to find it open the a550 firmware with an editor like khexedit and search "www.". Do somebody think it may be useful?
Title: Re: A550 Porting...need help
Post by: muttley on 04 / January / 2008, 17:23:56
I can't help, but try to respond:

-after rebooting the camera I find a file UpgradeLog.txt that contains 88 bytes of binary data, is that normal?

yes, it's normal...always you execute a fir on your canon this file is generated. I don't think is import for us.

-When looking into the binary firmware with I found a link to a website hidden between binary data, to find it open the a550 firmware with an editor like khexedit and search "www.". Do somebody think it may be useful?

It's present in all others canon's firmware, it's only an about/help or like this...

Is there anyone that help us to understand the code disassembled by IDA...
I know enought ASM x86 (ARM...no problem), but in 4 MB i don't know WHERE & WHAT search!

While I'm waiting...I have redumping the firmware and find some error in previous!

THIS IS THE FINAL...I HOPE: http://rapidshare.com/files/81300076/dump0xFFC00000.rar.html
(four dump with blink g7, always the same)
Title: Re: A550 Porting...need help
Post by: muttley on 06 / January / 2008, 17:43:36
boot.c is now ok...i hope! :xmas
I'm start from kernelinit and walking back in IDA...

Quote
void boot()
{
    long *canon_data_src = (void*)0xFFEEB4D0;
    long *canon_data_dst = (void*)0x1900;
    long canon_data_len = 0xB540;
    long *canon_bss_start = (void*)0xCE40; // just after data
    long canon_bss_len = 0x9F2B0 - 0xCE40;
    long i;

  ...


void h_usrInit()
{
    asm volatile (
      "STR     LR, [SP,#-4]!\n"
      "BL      sub_FFC01968\n"
      "MOV     R0, #2\n"
      "MOV     R1, R0\n"
      "BL      sub_FFCC1CEC\n"      //unknown_libname_201
      "BL      sub_FFCB6DB8\n"      //excVecInit
      "BL      sub_FFC011C4\n"
      "BL      sub_FFC01728\n"
      "LDR     LR, [SP],#4\n"
      "B       h_usrKernelInit\n"
    );
}

void  h_usrKernelInit()
{
    asm volatile (
      "STMFD   SP!, {R4,LR}\n"
      "SUB     SP, SP, #8\n"
      "BL      sub_FFCC21EC\n"      //classLibInit
      "BL      sub_FFCD2318\n"      //taskLibInit
      "LDR     R3, =0x4E60\n"
      "LDR     R2, =0x9C4C0\n"
      "LDR     R1, [R3]\n"
      "LDR     R0, =0x9D010\n"
      "MOV     R3, #0x100\n"
      "BL      sub_FFCCDF08\n"      //qInit
      "LDR     R3, =0x4E20\n"
      "LDR     R0, =0x51C0\n"
      "LDR     R1, [R3]\n"
      "BL      sub_FFCCDF08\n"      //qInit
      "LDR     R3, =0x4EDC\n"
      "LDR     R0, =0x9CFE4\n"
      "LDR     R1, [R3]\n"
      "BL      sub_FFCCDF08\n"      //qInit
      "BL      sub_FFCD66D4\n"      //workQInit
      "BL      sub_FFC012B0\n"
      "MOV     R4, #0\n"
      "MOV     R3, R0\n"
      "MOV     R12, #0x800\n"
      "LDR     R0, =h_usrRoot\n"
      "MOV     R1, #0x4000\n"
      "LDR     R2, =0xCF2B0\n"   // 0x9F2B0 + 0x30000
      "STR     R12, [SP]\n"
      "STR     R4, [SP,#4]\n"
      "BL      sub_FFCCF558\n" //kernelInit
      "ADD     SP, SP, #8\n"
      "LDMFD   SP!, {R4,PC}\n"
    );
}
...

void  h_usrRoot()
{
    asm volatile (
      "STMFD   SP!, {R4,R5,LR}\n"
      "MOV     R5, R0\n"
      "MOV     R4, R1\n"
      "BL      sub_FFC019D0\n"
      "MOV     R1, R4\n"
      "MOV     R0, R5\n"
      "BL      sub_FFCC6CA4\n"      //memInit
      "MOV     R1, R4\n"
      "MOV     R0, R5\n"
      "BL      sub_FFCC771C\n"      //memPartLibInit
      //"BL      sub_FFC017E8\n"      //nullsub_1
      "BL      sub_FFC01704\n"
      "BL      sub_FFC01A0C\n"
      "BL      sub_FFC019F0\n"
      "BL      sub_FFC01A38\n"
      "BL      sub_FFC019C4\n"
    );

    _taskCreateHookAdd(createHook);
    _taskDeleteHookAdd(deleteHook);

    drv_self_hide();

    asm volatile (
      "LDMFD   SP!, {R4,R5,LR}\n"
      "B       sub_FFC0136C\n"      //IsEmptyWriteCache_2
    );
}



Well, lib.c and stubs_entry_2.S...I don't know how to find the missing fuction:

stubs_entry_2.S
Quote
#find in IDA
NHSTUB(Close,  0xFFCC5108)
NHSTUB(Remove, 0xFFCC549C)
 
#near unmount
NHSTUB(Mount_FileSystem, 0xFFE214C4)

#there are readv and writev?! ...is it the same?
NHSTUB(Read,   0xFFCC5334)
NHSTUB(Write,  0xFFCC53B0)

NHSTUB(kbd_read_keys_r2, 0xFF???????)
NHSTUB(DisplayImagePhysicalScreen, 0xFF???????)
NHSTUB(free, 0xFF???????)
NHSTUB(SetZoomActuatorSpeedPercent, 0xFF???????) //null stub

...for lib.c nothing...nothing...nothing  :'(
Title: Re: A550 Porting...need help
Post by: stranger on 09 / January / 2008, 18:36:45
First of all, I'm working on porting the A530.

muttley, your XREF hint on the wiki page was very helpful. ^_^  I think I have boot.c right now, though I was unsure about the boot() function, so I followed your example.  So hopefully you were right. ;)
Quote from: A530 boot.c

void boot()
{
    long *canon_data_src = (void*)0xFFEDE3C0;
    long *canon_data_dst = (void*)0x1900;
    long canon_data_len = 0xB8D0;
    long *canon_bss_start = (void*)0xD1D0;
    long canon_bss_len = 0x91C70 - 0xD1D0;

[...]
The line for canon_data_src looked like this, so I'm not sure. :(:
Quote from: A530 IDA disassembly
ROM:FFC0017C off_FFC0017C    DCD unk_FFEDE3C0        ; DATA XREF: ROM:FFC0010

Other than that, I'm now in the same boat.  I don't know where to start with lib.c, and I haven't found anything with IDA so far.  the lib.c from the A540 source code has some helpful-looking comments, but I still can't figure out how to find the right values.  (Some of them were commented out for some reason.  :-[)
Quote from: A540 lib.c
[commented out]
char *hook_raw_image_addr()
{
    return (char*)0x105B8AC0; // OK (find on ".crw")
}

long hook_raw_size()
{
    return 0x75A8F0; // OK (find on ".crw")
}

[commented out]

void *vid_get_bitmap_fb()
{
    return (void*)0x103C79A0; // OK (find in _CreatePhysicalVram)
}

void *vid_get_viewport_fb()
{
    return (void*)0x105F17A0; // OK (find on "VRAM Address  : %p")
}

void *vid_get_viewport_fb_d()
{
    return (void*)(*(int*)0x60BA0); // OK (find on "WBTblAdj.c")
}
[...]


Here is my stubs_entry_2.S, I guess I was lucky.  (It does look very much like stubs_entry_2.S from the A540 source.)  But I can't find free.  I know there is information about it in signatures.h and IDA looks for it.
Quote from: A530 stubs_entry_2.S

#include "stubs_asm.h"

NHSTUB(VbattGet,  0xFFC1C000) //found w/ IDA
NHSTUB(free,  0xFFC0A748) //not found yet (used FreeMemory)

//null stub (S2/S3 only apparently)
NHSTUB(SetZoomActuatorSpeedPercent, 0xFFC017E8) //used nullsub_1

I've modified things similarly to how muttley has (A550 wiki page (http://chdk.wikia.com/wiki/A550) has more detail), and the rest is A560 code.  When I compile it and try to load it the LCD turns off, the power led blinks off briefly, the green viewfinder led blinks on briefly, then the LCD comes on again with the regular firmware.

Could someone perhaps give us some hints on how to find these things for lib.c and stubs_entry_2.S? :)  And muttley, if you've made any further progress or have any further insight I'd love to hear it.  I have a friend who is also interested in your A550 port for his camera.
Title: Re: A550 Porting...need help
Post by: muttley on 10 / January / 2008, 06:27:40
i'm very happy that my work is helpful for someone... 8)

...I hope someone help us for complete the porting  :'(  :'(  :'(

Quote
Could someone perhaps give us some hints on how to find these things for lib.c and stubs_entry_2.S?


I would add only some word: pleaseeeeeeeeeeeeeeeee!!!
Title: Re: A550 Porting...need help
Post by: muttley on 10 / January / 2008, 12:48:12
for stranger:

If you wanna find the canon_data_src address without error, it's enought a HexEditor.

Open your firmware (.bin) and search in ASCII-mode this string: start of data

example:

if you find the string at the address: 0x002EB4D4  (address of the lecter 's')
then the canon_data_src is: 0x002EB4D0

good luck!

p.s. I hope my senteces are right  :P
Title: Re: A550 Porting...need help
Post by: muttley on 11 / January / 2008, 05:47:03
I have FINISHHH my port!  :D :D :D

http://www.zshare.net/download/640141362c95c5/ (http://www.zshare.net/download/640141362c95c5/)

...but don't run  :o

I don't know why, i have complete boot.c, I have found all missing function and insert them in stubs_entry_2.S...

...lib.c is incomplete i have found 3 address:

Quote
void *vid_get_bitmap_fb()

void *vid_get_viewport_fb()

void *vid_get_viewport_fb_d()

loader is copyed by a560 as a rest of file in platform/a550 (less boot.c, makefile.inc, lib.c, stubs_min.S and stubs_entry_2.S)

BUT DON'T WORK!!!!
when i launch 'firmware update' my camera just switch off...

WHY!?!?

QUESTIONS:

- Is there a 'debug mode' or similar method to find the location of the error?!
- Am I forgetting something...some files??! u
Unfortunately the article Adding support of a new camera is incomplete and I don't know were broken my head  :(
Title: Re: A550 Porting: Update
Post by: muttley on 14 / January / 2008, 17:49:51
Only an update:

makefile.inc, boot.c, lib.c, stubs_min.S and stubs_entry_2.S are modified!
...and firmware was trimmed.

all procedure is on Wiki page http://chdk.wikia.com/wiki/A550
Title: Re: A550 Porting...need help
Post by: muttley on 21 / January / 2008, 05:07:09
NOW CHDK RUN!!  :D :D :D

...the problem was capt_seq.c, nobody say me it's necessary for start...and there isn't doc that say this!

THANK ROSSIG, for all support !!

now...another problem: i can't enter in ALT mode...eheheh, is there a function o part of code that i can view for resolve problem? 
Title: Re: A550 Porting...need help
Post by: JTLG on 21 / January / 2008, 18:32:17
Got a link to the firmware?
Or all the bits in the code that were changed?
Maybe update the wiki page with the new snippet that makes it run now.

and also: Congrats, Nice work!!

Tom
Title: Re: A550 Porting...need help
Post by: dusk on 22 / January / 2008, 23:46:36
First of all a huge congrats and "thank you!!!" for making this wonderful mod possible on A550. CHDK was something I really wanted to have for a long time.

Now what I understand is there is a working version available, right?

I really would like to try it here with my A550 and probably be some kind of help by writing my experience with it.

So if possible do you think you could provide us the files?

Thanks again. Great job.
Title: Re: A550 Porting...need help
Post by: synthesilica on 23 / January / 2008, 08:18:37
Hey, what happened to the Wiki page? Everything's been blanked out and the discussion says "Porting process is blocked". Please don't tell me you're giving up! You've been making so much progress!
Title: Re: A550 Porting...need help
Post by: Barney Fife on 24 / January / 2008, 00:56:04
Deleted
Title: Re: A550 Porting...need help
Post by: synthesilica on 24 / January / 2008, 12:15:54
You said porting process was blocked. Care to post what you've come up with so far? Someone might be able to continue it.
Title: Re: A550 Porting...need help
Post by: dusk on 24 / January / 2008, 18:14:05
Previous posts indicate a successful firmware, with little problems.

I believe wiki was restored by someone else, not by muttley.

He said:

"NOW CHDK RUN!!  Big Grin Big Grin Big Grin

...the problem was capt_seq.c, nobody say me it's necessary for start...and there isn't doc that say this!

THANK ROSSIG, for all support !!

now...another problem: i can't enter in ALT mode...eheheh, is there a function o part of code that i can view for resolve problem? "

I think when he comes back we'll have a somehow working version. :)
Title: Re: A550 Porting...need help
Post by: JTLG on 25 / January / 2008, 11:55:44
Actually, if you view the history of the A550 page, Muttley removed all the info ???
However, one wonderful thing about wikis, is all previous revisions are saved, so you can still get the full info.

I'd use that info and look into capt_seq.c myself, but I don't want to be bothered with compiling gcc for ARM processors.
But perhaps I will anyway...

Jarod (wonder if theres gcc-arm in portage...)

EDIT: wow, that was surprisingly easy to get as far as the capt_seq.c issue, I have a compiled firmware, however my camera has been borrowed (I'll get it back by monday or tuesday), and I have my doubts that it will work without knowing what capt_seq.c does, or what to change in it.

Wow that I've bothered to do this, muttley will release it within minutes of me getting this to work  :lol

(I had exact versions of binutils and gcc hiding in my src dir, handy, but its a way old version of gcc, 3.4.6, I'm using 4.1.2 now)

Any suggestions on capt-seq.c, let me know, if we can get that sorted, I'll compile it, and someone can test it.
Title: Re: A550 Porting...need help
Post by: ctrl-alt-canc on 25 / January / 2008, 13:02:33
Hi all, I've been away from this forum for a while, and now I no longer understand what's happening...
The last thing I did was to modify files as muttley said, and in the end my camera swithced off every time I started the firmware upgrade. Now I've seen the post where muttley said that chdk was working, but on the wiki there's "porting process is blocked". Do somebody know what to modify in capt_seq.c to run the chdk??
Title: Re: A550 Porting...need help
Post by: JTLG on 25 / January / 2008, 13:17:14
<snip>
Do somebody know what to modify in capt_seq.c to run the chdk??
</snip>

Thats what I'm looking for also, I got to the same point that you have, except I have no camera to test on right now, and capt_seq.c seems very confusing to me.

Muttley said:
"THANK ROSSIG, for all support !!"

Maybe we need to find who ROSSIG is?
Title: Re: A550 Porting...need help
Post by: synthesilica on 26 / January / 2008, 04:27:57
I'm an A550 user and I'd be glad to help test out. Unfortunately, I don't have any experience in coding or compiling so please post some of your compiled work and I can try it out.
Title: Re: A550 Porting...need help
Post by: JTLG on 26 / January / 2008, 14:46:28
http://rapidshare.com/files/86842785/Archive.zip

I highly doubt that this will work, due to not having the capt_seq.c issue taken care of, but its worth a shot, let me know what you get, until my camera gets back, I cant test any progress I may make.

Thanks, the .fir file may have to be renamed to match what the camera looks for.
Title: Re: A550 Porting...need help
Post by: hejm on 26 / January / 2008, 17:39:10
I've tested ...camera switched off. No led blinking ...nothing. Not working.
Title: Re: A550 Porting...need help
Post by: dusk on 26 / January / 2008, 18:12:34
NOW CHDK RUN!!  :D :D :D

...the problem was capt_seq.c, nobody say me it's necessary for start...and there isn't doc that say this!

THANK ROSSIG, for all support !!

now...another problem: i can't enter in ALT mode...eheheh, is there a function o part of code that i can view for resolve problem? 

Can someone include this file and recompile?

I believe problem with this file is only its absence, all needed is to "include" it somewhere and recompile. Or put it at the boot. Whatever...

btw god knows what "ALT mode" is...
Title: Re: A550 Porting...need help
Post by: synthesilica on 26 / January / 2008, 23:11:11
ALT mode is the mode you're in when CHDK is in effect. You open it by pressing the print button (blue led on A550) which opens up a bunch of menus where you can do all the adjustments. Apparently, Muttley was able to get CHDK running but couldn't enter ALT mode which is practically the main part of CHDK. Booting it doesn't seem to be a problem anymore but the actual operation of CHDK.
Title: Re: A550 Porting...need help
Post by: muttley on 27 / January / 2008, 13:48:56
WWWAOOOooooo!!!!!!

The comunity is alive!!   :D  :D

...i had starting to think that a550 porting don't interesting anyone!

There are still "good people"!! ...but not good programmers  :P  ...I hope good testers!!

Sorry guys, but i was busying with my work...

I see your hard work for take to end the porting !

...I hoped someone of folk (programmer had just porting) said me how to resolve ALT-mode problem...
And Rossig help me again!!

Now you have to help me for find all problems, bugs and strange behaviors of Canon with my CHDK porting...and there are many!

I'll make just some revision and coming soon I'll post binary on ZShare!
Title: Re: A550 Porting...need help
Post by: dusk on 27 / January / 2008, 18:00:23
Hell yeah!  :D :lol :xmas

Dude, you rock.

Thank you. Great.  :)
Title: Re: A550 Porting...need help
Post by: JTLG on 27 / January / 2008, 22:10:25
but not good programmers

I'm definitely not a good programmer lol.
I can manage to fix what prevents me from compiling something, but thats about it.

Glad to see you're making progress, my cam will be back tomorrow, waiting for that binary to test!
Title: !!Release Date!!
Post by: muttley on 28 / January / 2008, 10:12:50
The time is come!!  :D

Some changes from my last update:

1- The CHDK Porting now run!  :)
2- Modified capt_seq.c with correct fuction take by IDA.
3. The same with movie_rec.c, now work video recording with quality or bitrate variable (i think).
4- Property case are equal to a560/a570...I'll verify several.
5- Keymap it's ok...based on a540.
6- Modemap is 'working in progress', now it's copied form a560. Modified mode_get() in main.c...
8- Others don't remember.
7- Fixed some small bugs.

IT'S VERY IMPORTANT YOUR UTILIZATION REPORT FOR FIND BUGS, PROBLEM AND STRANGE BEHAVIORS!
POST HERE ALL YOUR COMMENT, THANK!

...now enjoy with your new chdk features: CHDK for a550.rar - 0.19MB (http://www.zshare.net/download/6954355b8ccc62/)

Title: Re: A550 Porting...need help
Post by: JTLG on 28 / January / 2008, 10:29:15
Sweet, I'm still waitin for my cam to get back, but I'll start testing as soon as it does.

Thanks a ton, Maybe now its possible to see everything that needs to be changed for CHDK to run, so maybe the wiki can get a proper porting guide that is complete.

Tom
Title: Re: A550 Porting...need help
Post by: synthesilica on 28 / January / 2008, 11:02:41
Great job! Too bad it's around midnight in my country. I was able to save it and take a few shots. I'll do a lot more testing tomorrow. Thanks a lot!
Title: Re: A550 Porting...need help
Post by: synthesilica on 28 / January / 2008, 11:54:52
Still fiddling around with the camera. Has anyone tried getting scripts to work? I get this red error on top that says "uBasic:1 Unk stmt" whenever I try some of the bracketing scripts on the wiki.

edit: Some of the bracketing scripts work but they don't change the exposure at all.
Title: Re: A550 Porting...need help
Post by: muttley on 28 / January / 2008, 16:26:10
Quote
Thanks a ton, Maybe now its possible to see everything that needs to be changed for CHDK to run, so maybe the wiki can get a proper porting guide that is complete.

Thank, thank JTLG  8) ...but test my realease before express gratitude :P

I hope finish soon my wiki/porting page...but I'm very busy at the moment...and I also would study some guide "photography for dummies" because i'm a classical user that set his cam in AUTO mode   :lol

synthesilica is it no too late for try chdk?!  :haha
sorry, but in italy (my country) was 4:00 PM...

mhhh... thank for error reporting!

I tried some script and many worked fine. For bracketing i see also focus don't work...I'm sure that work ISO bracketing at the moment!

one hit:
try bracketing in Extra Photo Operations > Bracketing in Continuous Mode (firmware is Allbest)

a last thing:
I have created a section named 'Bugs Report' in a550 wiki page and add your report.
For next one everyone can add it to wiki and then explain in detail on this forum
 
Title: Re: A550 Porting...need help
Post by: JTLG on 28 / January / 2008, 18:17:57
Got it up and running about 1/2 hour ago, looks good sofar, I'm working on any bugs, haven't found any yet though.

NICE!!!

I was playing the games a minute ago, it seems kind of funny, playing games on a camera.  :D

Great job Muttley!!!

Tom
Title: Re: A550 Porting...need help
Post by: synthesilica on 29 / January / 2008, 05:59:08
found another bug. The zebra stripes are shifted off to the side. They're not aligned properly with the image. Just put it on the wiki.
Title: Re: A550 Porting...need help
Post by: ynaig on 29 / January / 2008, 15:26:45
Another bug, I don't know if that can be classified as a bug.

When enabling the macro mode, and trying to run the interval or interval-video scripts, it won't run correctly, meaning it won't take shots.

Ynaig
Title: Re: A550 Porting...need help
Post by: ctrl-alt-canc on 30 / January / 2008, 07:11:37
THANKS muttley!!!
it works :)

If possible post your modified capt_seq.c :)
Title: Re: A550 Porting...need help
Post by: muttley on 30 / January / 2008, 09:55:58
Good works!

Give me some times for solve bugs!

I had posted on ZShare and add in Wiki page, archive with Source of my porting...if someone would help the comunity...

Always report all progress!

APPEAL: If there is anyone that have good know of CHDK and He can suggest WHERE (point of source, function or any idea) the bug creep inside!  :'(
Title: Re: A550 Porting...need help
Post by: ctrl-alt-canc on 31 / January / 2008, 05:58:15
Thanks for the source code, I compiled it and it works ;)

I haven't found any bug, raw pictures are good, and all the menus seems working correctly.
I don't have much time nor much experience, but I'd like to contribute. Now I'm just looking at the source code to try understanding how it works.
Title: Re: A550 Porting...need help
Post by: hejm on 01 / February / 2008, 08:07:35
When making chdk load automatically you need to press 2x fast on/off button or replay button. Either way, camera starts in playback mode.

Dof calculator ...i always get S/R1/R2: inf/inf/inf
Title: Re: A550 Porting...need help
Post by: Dapjazz on 02 / February / 2008, 07:00:58
 :)
At last! a550 working chdk! I've tested, it works ok, great job!!

but I have some questions:

1. I can't work the raw files taken by this model.. no software recognize it (acdsee pro, DNG4PS-2...)  :( any advices?

2. Can't use the pc remote shooting.. cam4you doesn't detect the camera.. How can I use my pc to take pictures directly to hard drive?

thanks!!
Title: Re: A550 Porting...need help
Post by: synthesilica on 02 / February / 2008, 09:47:58
I'm using DNG for Powershot with EXIFTool. I end up with a .DNG file I can edit with Photoshop.
Title: Re: !!Release Date!!
Post by: hucht on 02 / February / 2008, 15:52:55
The time is come!!  :D

Some changes from my last update:

1- The CHDK Porting now run!  :)
2- Modified capt_seq.c with correct fuction take by IDA.
3. The same with movie_rec.c, now work video recording with quality or bitrate variable (i think).
4- Property case are equal to a560/a570...I'll verify several.
5- Keymap it's ok...based on a540.
6- Modemap is 'working in progress', now it's copied form a560. Modified mode_get() in main.c...
8- Others don't remember.
7- Fixed some small bugs.

IT'S VERY IMPORTANT YOUR UTILIZATION REPORT FOR FIND BUGS, PROBLEM AND STRANGE BEHAVIORS!
POST HERE ALL YOUR COMMENT, THANK!

...now enjoy with your new chdk features: CHDK for a550.rar - 0.19MB (http://www.zshare.net/download/6954355b8ccc62/)



Could you please post the instructions please???
Title: Re: A550 Porting...need help
Post by: muttley on 02 / February / 2008, 16:24:25
Instruction for what?!

if you intend, INSTALL instruction   :blink: ...read this http://chdk.wikia.com/wiki/FAQ (http://chdk.wikia.com/wiki/FAQ)   ???
Title: Re: A550 Porting...need help
Post by: hucht on 03 / February / 2008, 06:54:11
Instruction for what?!

if you intend, INSTALL instruction   :blink: ...read this http://chdk.wikia.com/wiki/FAQ (http://chdk.wikia.com/wiki/FAQ)   ???

Hi, I've installed the firmware. The thing is thar I tries to make the firmware bootable but after locking the SD card it doesn't get on (if I retire the SD or unlock the SD it works as usual with the official firmware).

Could anybody help me?
Title: Re: A550 Porting...status: bugs hunters
Post by: muttley on 03 / February / 2008, 14:08:39
hucht, the firmware is in beta...You have a problem that we know, and we are working to resolve!
...if you want help us, download also the source!

p.s. read old post...

Last Update:

- Dof calculator solved!  :D

I know is it few...but I' don't have time (and help)  :(

for denvelopers:

The problem was GetFocusLensSubjectDistance bad address, update stubs_entry_2.s...

but I'm confused... :blink:

well, i have found correct address: 0xFFE43B08

and see that function GetCurrentTargetDistance is:

STR     LR, [SP,#-4]!
BL      sub_FFE43B08   <-- call to GetFocusLensSubjectDistance
MOV     R0, R0,LSL#16
MOV     R0, R0,LSR#16
LDR     PC, [SP],#4


mhhhh....what are the difference by GetFocusLensSubjectDistance and GetCurrentTargetDistance??
I think GetCurrentTargetDistance call only GetFocusLensSubjectDistance! is it true?!

I had verified also with other firmware (ex. a610) and is the same!  :blink:

i test in debug and for my cam GetCurrentTargetDistance result = GetFocusLensSubjectDistance result!

hi guys!



Title: Re: A550 Porting...status: bugs hunters
Post by: hucht on 03 / February / 2008, 15:29:14
hucht, the firmware is in beta...You have a problem that we know, and we are working to resolve!
...if you want help us, download also the source!

p.s. read old post...

Last Update:

- Dof calculator solved!  :D

I know is it few...but I' don't have time (and help)  :(

for denvelopers:

The problem was GetFocusLensSubjectDistance bad address, update stubs_entry_2.s...

but I'm confused... :blink:

well, i have found correct address: 0xFFE43B08

and see that function GetCurrentTargetDistance is:

STR     LR, [SP,#-4]!
BL      sub_FFE43B08   <-- call to GetFocusLensSubjectDistance
MOV     R0, R0,LSL#16
MOV     R0, R0,LSR#16
LDR     PC, [SP],#4


mhhhh....what are the difference by GetFocusLensSubjectDistance and GetCurrentTargetDistance??
I think GetCurrentTargetDistance call only GetFocusLensSubjectDistance! is it true?!

I had verified also with other firmware (ex. a610) and is the same!  :blink:

i test in debug and for my cam GetCurrentTargetDistance result = GetFocusLensSubjectDistance result!

hi guys!



I have solved the problem of the SD card (1GB kingston). I formated it with 64kb as allocated unit size and it works (I hope it would helps to anybody). Also I have a question... Is there any script for have a screenshot of the camara's screen?
Title: Re: A550 Porting...status: bugs hunters
Post by: muttley on 03 / February / 2008, 15:58:39
ahaha...good work!

i thought that boot problem was another bug!  :haha

it's enough read FAQ:

Quote
Note2: 4 GB cards can support the autoload feature if they are formated in FAT16 manually. To format SD-card in Windows command line just type 'format X: /fs:fat' (where X: - a drive letter of mounted SD-card). But be aware that the formatting of 4 GB cards in FAT16 leads to non-standard 64K cluster size. The correct support of such cluster size is not guaranteed.

thank hucht!

for the LCD screenshot...i don't know, i'm sorry!

why have you need this features?!
Title: Re: A550 Porting...status: bugs hunters
Post by: mx3 on 03 / February / 2008, 16:23:07

for the LCD screenshot...i don't know, i'm sorry!

why have you need this features?!

I think it would be useful for tutorials/FAQs (so people would not need second camera to shoot display :-) )
Title: Re: A550 Porting...status: bugs hunters
Post by: Dapjazz on 03 / February / 2008, 23:04:13
the lcd screenshot is a good idea!


please help me connecting my a550 to pc and take pictures directly to hard drive? how can I do this?
Title: Re: A550 Porting...status: bugs hunters
Post by: muttley on 04 / February / 2008, 06:02:37
Quote
the lcd screenshot is a good idea!

mhhh...yes good idea, but i don't have big know of chdk source!  :-[

for now I suggest to put this request feature on: http://chdk.setepontos.com/index.php/board,9.0.html (http://chdk.setepontos.com/index.php/board,9.0.html)

otherwise, some developers can show the way to follow...and I'm very happy to try!!   :)

Quote
please help me connecting my a550 to pc and take pictures directly to hard drive? how can I do this?

I don't try this features, you can use it and report how cam respond  :D

You can read this, if is it interesting for you: http://chdk.setepontos.com/index.php/topic,332.msg2243.html#msg2243 (http://chdk.setepontos.com/index.php/topic,332.msg2243.html#msg2243)

Title: Re: A550 Porting...status: bugs hunters
Post by: Dapjazz on 04 / February / 2008, 07:35:21
The A550 doesn't support remote pc control to take pictures directly to hard drive, but I'm just wondering if chdk can change it... but it seems to be an option our a550 will never have  :(

it's a good idea what user haunma says on http://chdk.setepontos.com/index.php?PHPSESSID=49b85ccccd3660f4cf534d2bcb796bc4&/topic,332.msg2243.html (http://chdk.setepontos.com/index.php?PHPSESSID=49b85ccccd3660f4cf534d2bcb796bc4&/topic,332.msg2243.html), "is it possible to kick the camera back and forth between picture-taking and downloading modes from a USB-connected PC, without pressing any buttons on the camera" ?

btw it's a really good job to have chdk on a550!
Title: Re: A550 Porting...status: bugs hunters
Post by: muttley on 05 / February / 2008, 15:45:33
Update: Restore, Modified and Add some parts in wiki page!  :D
Title: Re: A550 Porting...status: bugs hunters
Post by: muttley on 09 / February / 2008, 18:26:21
Update:


I'm very interested to AllBest Build 31 release for the manual focus! Soon on a550...

if someone would add a550 porting to CHDK trunk...it's good thing  :)

...here the last bin: http://www.zshare.net/download/7363464f461fa5/ (http://www.zshare.net/download/7363464f461fa5/)
Title: Re: A550 Porting...status: bugs hunters
Post by: Barney Fife on 09 / February / 2008, 18:48:40
Deleted
Title: Re: A550 Porting...status: bugs hunters
Post by: muttley on 09 / February / 2008, 19:27:20
AHAHahahAH   :lol

Ok, you have convinced me!

You are right...in this porting, zebra mode don't still work, but I want absolutely flashlight!  8)
Title: Re: A550 Porting...status: bugs hunters
Post by: Barney Fife on 09 / February / 2008, 21:14:11
Deleted
Title: Re: A550 Porting...status: bugs hunters
Post by: synthesilica on 10 / February / 2008, 07:04:17
great work muttley, keep it up!
Title: Re: A550 Porting...status: bugs hunters
Post by: muttley on 10 / February / 2008, 13:39:53
Update: Zebra mode now work!   :P

Problem was in lib.c, bad address for vid_get_viewport_fb

...here the last chdk: http://www.zshare.net/download/7395778a8dcccd/ (http://www.zshare.net/download/7395778a8dcccd/)

Title: Re: A550 Porting...I see the end!
Post by: muttley on 12 / February / 2008, 11:14:01
I have need some help !

There are some problem in bracketing...It's needed find factory value for:

thanks to ewavr and Porting the ixus70_sd1000 ver 102a to CHDK Post: http://chdk.setepontos.com/index.php/topic,300.msg2515.html#msg2515 (http://chdk.setepontos.com/index.php/topic,300.msg2515.html#msg2515)

p.s. for see property case ALT->menu->debug->Show PropCases and set prop Case page for what you want see (ex. pag. 26 for propcases 262, 264)

thanks men!  :xmas
Title: Re: A550 Porting...status: bugs hunters
Post by: hucht on 12 / February / 2008, 19:50:50
Update:

  • Add Support: USB Remote Button
  • Add: Mode Screen Rotated / Flashlight LCD (enable it's in misc and rotate 270 in alt mode) silly mod for test Rotated Screen

I'm very interested to AllBest Build 31 release for the manual focus! Soon on a550...

if someone would add a550 porting to CHDK trunk...it's good thing  :)

...here the last bin: http://www.zshare.net/download/7363464f461fa5/ (http://www.zshare.net/download/7363464f461fa5/)

What do you mean about "USB Remote Button" I don't know what does it mean, could you explain me?
Title: Re: A550 Porting...status: bugs hunters
Post by: muttley on 13 / February / 2008, 04:14:35
there are many doc in chdk wiki and in forum...  ::)

btw, you can make a simple remote-wire to do shoot.

you can find more info here: http://hem.passagen.se/fsmmal/chdk2.html (http://hem.passagen.se/fsmmal/chdk2.html)
Title: Re: A550 Porting...status: bugs hunters
Post by: synthesilica on 22 / February / 2008, 22:17:00
Any new progress? The manual settings for shutter speed, image distance, and ISO don't work.
Title: Re: A550 Porting...status: bugs hunters
Post by: ynaig on 29 / February / 2008, 14:06:41
One bug is that when I enable the Video mode by the dial, and I push the  ALT button, it doesn't switch to ALT mode, just it keeps switching to Night scene, and then pressing again ALT button, it goes back to Movie mode (obviously also the ALT mode will be enabled, but the mode will be Night Scene, not the Video Mode which is what I want). The only one way to get the ALT menu to show is to enter the play mode and then press the ALT button to switch to ALT mode.

Another bug, when I try to use high quality mode for video (99), I select 640x480x30fps, and when I start recording, the camera shuts down. The High quality (99) works in 320x240x30fps.

I hope I'm clear enough with these bugs.

Ynaig
Title: Re: A550 Porting...status: bugs hunters
Post by: Barney Fife on 29 / February / 2008, 14:23:17
Deleted
Title: Re: A550 Porting...status: bugs hunters
Post by: ynaig on 29 / February / 2008, 15:14:18
Barney Fife,

I stand corrected, thank you.

Today I purchased a Patriot Extreme Performance 2GB Read Speed up to 133X Secure Digital SD (PEF2G133SD) and benchmarked it. It seems to be not that different from the old Kingmax 1GB I had before. I think there is a hardware limitation in the IO bandwidth between the SD card reader and the rest of the camera logistics.

So in future I'll just use 3x bitrate mode for video.

Ynaig
Title: Re: A550 Porting...status: bugs hunters
Post by: dusk on 03 / March / 2008, 05:56:58
I've been looking for manual focus in my A550 for almost a year now, without success. The strange thing is that both in dpreview and in the instruction manual it was stated manual focus IS possible on this device.

So does anyone know a way to do that, without CHDK? Or can CHDK do it, if so, how?

Thank you.
Title: Re: A550 Porting...status: bugs hunters
Post by: muttley on 03 / March / 2008, 06:06:06
I don't think is possible with original firmware...

...and also impossible with chdk for now.  :(

It's needed implement the last Allbest build with Pseudo MF-mode, it could solve your problem.
Title: Re: A550 Porting...
Post by: muttley on 11 / March / 2008, 08:46:30
Update: Release last source and binary:

Some bugs solved...and more important: it's been compiled with last Allbest 37 build (http://chdk.setepontos.com/index.php/topic,645.msg5235.html#msg5235) (trunk 320)

See a550 wiki page  (http://chdk.wikia.com/wiki/A550) for files!

I hope to insert soon my porting in official trunk...
Title: Re: A550 Porting...
Post by: muttley on 12 / March / 2008, 06:21:56
Update: Release new source and binary

new trunk (322) => new release  8)

See a550 wiki page  (http://chdk.wikia.com/wiki/A550) for files!

Title: Re: A550 Porting...
Post by: ynaig on 15 / March / 2008, 18:39:53
Has the ability to set manually the aperture values been removed with the recent build for A550?

Ynaig
Title: Re: A550 Porting...
Post by: muttley on 15 / March / 2008, 22:02:00
yes...replaced with ND filter!

...the same with a560 and ixus family.
Title: Re: A550 Porting...
Post by: ynaig on 15 / March / 2008, 22:34:08
Can this ability to set manually the aperture values be available again?

Thanks,
Ynaig
Title: Re: A550 Porting...
Post by: muttley on 15 / March / 2008, 23:37:04
of course....

but i don't know because this features was disabled  :blink:

are you sure av ovveriding working good before?!

i can do this mod...but it's better to know the reasons, and after edit the built (trunk)..

you can ask in forum...
Title: Re: A550 Porting...
Post by: ynaig on 16 / March / 2008, 08:33:58
Well for me setting the aperture values worked fine with the previous builds. I did have better control when used in pair with shutter speeds for doing high speed shutter photography.

Ynaig
Title: Re: A550 Porting...
Post by: muttley on 16 / March / 2008, 11:59:39
mhhh...

I don't know enough good features of a550  :( 
...and for this I use in release the same features of a560 so equal to our A550  :P

It's needed ask why av overriding is not more supported in a560 and ixus family  :blink:
Title: Re: A550 Porting...
Post by: synthesilica on 17 / March / 2008, 12:51:09
Great job on another build!
But where'd the aperture override go? It worked fine on the last build. I don't know what ND filter means but when it's in, the photo just ends up darker. Off and out end up the same. I also have this gray rectangle on the lower right corner of the screen.
Title: Re: A550 Porting...
Post by: muttley on 17 / March / 2008, 13:36:57
thanks thanks!  :D

ehm...for the questions:

ND filter: Neutral density filter (http://en.wikipedia.org/wiki/Neutral_density_filter)
"Gray rectangle on the lower right corner of the screen": Allbest build 37 (http://chdk.setepontos.com/index.php/topic,645.msg5235.html#msg5235) and  Allbest build 34 (http://chdk.setepontos.com/index.php/topic,590.0.html) see here for the new features.


p.s. there are many things to do (see wiki page)...and nobody do it  :(
Title: Re: A550 Porting...
Post by: GrAnd on 18 / March / 2008, 05:25:25
but i don't know because this features was disabled  :blink:

are you sure av ovveriding working good before?!

Does A550 have iris diaphragm?
Title: Re: A550 Porting...
Post by: muttley on 18 / March / 2008, 06:13:00
Does A550 have iris diaphragm?

this is a good question!!   :)

I don't know where can i get characteristic and features (to insert in include/camera.h) of Canon PowerShoot a550...and I use the same features of a560 so equal to A550  :blink:

n.b. I'm an happy geek, not a photographer  :P
Title: Re: A550 Porting...
Post by: synthesilica on 18 / March / 2008, 06:21:47
The Aperture override seemed to work. The pictures did get darker when the number was increased. I'll test the old build if it actually affects the depth of field or if it really is just an ND filter.
Title: Re: A550 Porting...
Post by: GrAnd on 18 / March / 2008, 06:40:52
Does A550 have iris diaphragm?

this is a good question!!   :)

Usual, the diaphragm can be visible (especial in action) through lenses.
Title: Re: A550 Porting...
Post by: muttley on 18 / March / 2008, 06:49:06
I hope a photographer more expert of me can verify THIS and OTHERS cam features (now i don't have cam with me).

so we can update include/camera.h!

thanks a lot GrAnd!

p.s. however if a560 don't have diaphragm i don't think a550 have it...it's younger sister (less expensive...and less features)
Title: Re: A550 Porting...
Post by: synthesilica on 18 / March / 2008, 07:01:57
I just tested the old build. The aperture can only be set between 2.6 and 7.1. It seems like it really is just an ND filter. The DOF doesn't change at all either.

(https://chdk.setepontos.com/proxy.php?request=http%3A%2F%2Fimg177.imageshack.us%2Fimg177%2F2158%2F30897191tj1.jpg&hash=acfc56afee6e06a3eea7f34e5ca4f9cb)

Here are the comparison shots. The first 5 values are rounded down to 2.6 while all the others are brought to 7.1. What's strange though is that the first 2 shots (2.61 and 2.82), the EXIF says 2.6 which is correct but for the other shots, it says 7.1 which is wrong for the last 3 brighter shots (3.17, 3.56, and 4.00) which are clearly supposed to be 2.6.
Title: Re: A550 Porting...
Post by: muttley on 18 / March / 2008, 07:29:21
good work!! your test is very clear!

so the a550 don't have diaphragm...

well, the last release in trunk it's correct!

For EXIF porblem i don't know, but if you have a time test ND filter with latest release and verify EXIF and AV...

thanks!

Title: Re: A550 Porting...
Post by: synthesilica on 18 / March / 2008, 07:48:59
Just tested the latest build.

ND filter Off, Out, In, respectively
(https://chdk.setepontos.com/proxy.php?request=http%3A%2F%2Fimg186.imageshack.us%2Fimg186%2F1428%2Fimg0001em7.jpg&hash=bb25ef2b90b1b20db26b49675ff1cb32)

It's just like the one above but the EXIF says all were exposed at f2.6. It's as if the aperture doesn't change at all, it's just an ND filter. The only way for the aperture to change is by zooming in.
Title: Re: A550 Porting...
Post by: muttley on 18 / March / 2008, 08:27:04
it seem me ok  :blink:

mhhh...but...from off to out are there differences?  ???

btw, thanks again!

p.s. you are a good photographer not me  :o ...ehm..read this Would you help (http://chdk.wikia.com/wiki/A550#Would_you_help.3F)  :P
Title: Re: A550 Porting...
Post by: ynaig on 18 / March / 2008, 20:27:14
a550

property 23
f2.6 -> 277
f3.2 -> 308
f3.5 -> 336
f4.0 -> 388
f5.0 -> 439
f5.5 -> 480

Ynaig
Title: Re: A550 Porting...
Post by: muttley on 20 / March / 2008, 11:07:28
f2.6 -> 277
f3.2 -> 308
f3.5 -> 336
f4.0 -> 388
f5.0 -> 439
f5.5 -> 480

good work Ynaig!  :)

well, p.c. #23 is ApertureSize

there is the current configuration for a550 (platform/a550/shooting.c) below:

Code: [Select]
const ApertureSize aperture_sizes_table[] = {

    {  8, 273, "2.6" },
    {  9, 288, "2.8" },
    { 10, 320, "3.2" },
    { 11, 352, "3.5" },
    { 12, 384, "4.0" },
    { 13, 416, "4.5" },
    { 14, 448, "5.0" },
    { 15, 480, "5.6" },
    { 16, 512, "6.3" },
    { 17, 544, "7.1" },
    { 18, 576, "8.0" },
};

it's seem all wrong  ??? ...and it's smaller set :blink:

now i don't have time for see better your result, sorry!!  :-[

thanks!
Title: Re: A550 Porting...
Post by: synthesilica on 14 / April / 2008, 17:01:57
Hey there, been a while. I just remembered I haven't tested shutter speed. I decided to try chasing my monitor's scanlines.

Image on the right is at 1/2000, the specified limit and the image on the left is maxed out by CHDK
(https://chdk.setepontos.com/proxy.php?request=http%3A%2F%2Fimg443.imageshack.us%2Fimg443%2F3192%2Fspeedcomparisonbo0.th.jpg&hash=d394ee94c36ff19d06b79138db9134a3) (http://img443.imageshack.us/my.php?image=speedcomparisonbo0.jpg)

The real maximum shutter speed looks close to 1/4000 or 1/6000!! Canon never meant for their camera to be used this fast so be careful, forcing it that fast too often will probably break your shutter! I'll do tests again later to try and narrow it down.
Title: Re: A550 Porting...
Post by: Barney Fife on 14 / April / 2008, 17:59:05
Deleted
Title: Re: A550 Porting...
Post by: waterwingz on 08 / February / 2014, 12:30:13
If you are the owner of an A550 we need your help improving the manual focus / subject distance override capability of CHDK.

Please read the instructions posted here < Link to Testing Instructions (http://chdk.setepontos.com/index.php?topic=11078.msg108859#msg108859) > and test your camera.

TIA.
Title: Re: A550 Porting...
Post by: nafraf on 15 / December / 2014, 19:42:46
a550 patch: simpler loader code, remove autodetected entries from stubs_entry_2.S and stubs_min.S
Title: Re: A550 Porting...
Post by: koshy on 15 / December / 2014, 20:51:07
a550 patch: simpler loader code, remove autodetected entries from stubs_entry_2.S and stubs_min.S
Generally it works but you still cannot power on A550 using power button. Only via play button, but that was the case prior to this patch, too. So I guess the patch is fine.

We worked on the power on failure for this and three other cams elsewhere and did not get into finding the required information by trial and error as suggested here:
Unfortunately, (to my knowledge) none of the Vx ports implement special support for boot-time mode detection. That means someone would have to find it (mostly trial & error), as it is different from the method used in DryOS cameras. Doing this without physical access to the cam would be very painful and slow...