CHDK firmware hack discussion (9)

Started May 25, 2007 | Discussions
harvester
Contributing MemberPosts: 693
Like?
CHDK firmware hack discussion (9)
May 25, 2007

This is a sequel to the old threads discussing the CHDK firmware.

The CHDK fw is a hacked firmware for DIGIC II cameras. Currently supported cams are A610, A620, A630, A640, A710 IS, S2 IS and S3 IS (see the FAQ for a complete list).

The CHDK fw implements new features like RAW, battery indicator, live histogram (RGB/luminance), zebra mode (blinking areas of over- underexposure), DOF calculator, scripts (intervalometer, exposure/focus ... bracketing etc.), text reader, file browser, calendar, games and much more. New features get implemented frequently, so check the timeline for the latest changes, or the FAQ for a complete list.

The CHDK firmware does not touch the original firmware of your camera. It is an additional program which gets loaded into the memory of the cam. If you have a problem, just turn your cam off or remove the batteries, and the CHDK fw is gone.

For further information, a guide, download links and FAQ see the english WIKI:
http://scratchpad.wikia.com/wiki/CHDK

Timeline:
http://tools.assembla.com/chdk/timeline

Dear Vitalyb, GrAnd and all the others: Thank you so much for creating this wonderful piece of software!
Some screenshots:

Main menu

Histogram (Blended) and Zebra overexposure indicator

Script menu

Link to the previous thread:
http://forums.dpreview.com/forums/readflat.asp?forum=1010&thread=23288927

microfunguy
Regular MemberPosts: 234
Like?
Re: Enumerating Integer options in menus
In reply to harvester, May 25, 2007

I do not like to ask programming questions but need to get this sorted-out quickly.

My function "const char* gui_range_enum(int change, int arg)" returns a 'step' value as a string of characters ("1","10","100","1000","10000").

Menu item {"Distance-setting step size", MENUITEM_ENUM, (int*)gui_range_enum } displays all the step values and allows you to select one.

I need to use that value as the step increment in the next menu item :-

{"Set focused distance",MENUITEM_INT~MENUITEM_ARG_ADDR_INC, &conf.distance_setting,(int)&gui_range_enum}

(int)&gui_range_enum does not work and neither does anything else that I have tried.

What am I doing wrong ?

Thanks.

Reply   Reply with quote   Complain
harvester
Contributing MemberPosts: 693
Like?
Re: CHDK firmware hack discussion (9)
In reply to harvester, May 25, 2007

GrAnd wrote:

On the other hand in expressions no relation operations can be used. Dead end.

Sorry for the newbie question, but what does this mean?

"Relation operations" are these things, I guess:

less than

= equal
& and
~ or
^ xor

But what is an "expression"?

Reply   Reply with quote   Complain
harvester
Contributing MemberPosts: 693
Like?
Re: CHDK firmware hack discussion (9)
In reply to harvester, May 25, 2007

bfollet wrote:

I believe the S2 port is still a work in progress, so I'm not sure its appropriate to post suggestions yet, but I've installed the last 2 builds for the S2 port and they both have the same visual quirk and it might be a quick fix in the next build. Both the text and graphical LCD displays for the battery status overwrite part of the standard S2 display if you have the full display on.

Have you tried to move OSD elements? You can configure the OSD how you like it:
http://scratchpad.wikia.com/wiki/CHDK/HDK_firmware_usage#Layout_editor

Reply   Reply with quote   Complain
GrAnd
Regular MemberPosts: 325
Like?
Re: Enumerating Integer options in menus
In reply to microfunguy, May 25, 2007

microfunguy wrote:

I do not like to ask programming questions but need to get this
sorted-out quickly.

My function "const char* gui_range_enum(int change, int arg)"
returns a 'step' value as a string of characters
("1","10","100","1000","10000").

Menu item {"Distance-setting step size", MENUITEM_ENUM,
(int*)gui_range_enum } displays all the step values and allows you
to select one.

I need to use that value as the step increment in the next menu
item :-

{"Set focused distance",MENUITEM_INT~MENUITEM_ARG_ADDR_INC,
&conf.distance_setting,(int)&gui_range_enum}

(int)&gui_range_enum does not work and neither does anything else
that I have tried.

What am I doing wrong ?

Look at "Voltage MAX" menu item. You have to specify pointer to int, not to function in the second case.

Reply   Reply with quote   Complain
GrAnd
Regular MemberPosts: 325
Like?
Re: CHDK firmware hack discussion (9)
In reply to harvester, May 25, 2007

harvester wrote:

GrAnd wrote:

On the other hand in expressions no relation operations can be used. Dead end.

Sorry for the newbie question, but what does this mean?

"Relation operations" are these things, I guess:

less than

= equal
& and
~ or
^ xor

But what is an "expression"?

The first three are relation operators. http://en.wikipedia.org/wiki/Relational_operator
The last three are binary.
Expression is just... expression. Like this: a = b+c
http://en.wikipedia.org/wiki/Expression_%28programming%29

Reply   Reply with quote   Complain
Chem
Junior MemberPosts: 46
Like?
Re: CHDK firmware hack discussion (9)
In reply to GrAnd, May 25, 2007

@GrAnd

For the S series, In build 72 you disabled the shortcut button so the original setting assigned to this button won't change every time you enter ALT mode, but in build 73 you enabled it again I suppose because not having a shortcut button is worse than having one that changes the settings when it's not supposed to right? Isn't it better to make it so that ALT mode is entered when the flash button is pushed if that's possible? Because I think that that's the button which is least used. It only has the original function when the flash is up and even then only in P, Auto and the scene modes. It has no function in Tv, Av and M which I suspect are the modes most used by S series owners.

Reply   Reply with quote   Complain
microfunguy
Regular MemberPosts: 234
Like?
Re: Enumerating Integer options in menus
In reply to GrAnd, May 25, 2007

GrAnd wrote:

You have to specify pointer to int, not to function

Thanks.

I have that working now.

This is a good way of learning 'C' , though a bit painful

Reply   Reply with quote   Complain
dinny66
Regular MemberPosts: 248
Like?
CHDK loaded
In reply to microfunguy, May 25, 2007

Can I just drop in a big thanks to the guys who wrote this.
Loaded on my A710IS today, wow what a difference.
The live histogram feature is fantastic without the other cool stuff.

Thanks again!

Mike

Reply   Reply with quote   Complain
Mato34
Contributing MemberPosts: 873
Like?
I've received my A640 today
In reply to harvester, May 25, 2007

I bought it only for the CHDK software. What else can I say? Oh, well: thanks!!

I also bought a KonicaMinolta Z2 a couple of years ago just because of the hacked RAW-firmware, and I enjoyed a lot learning and practicing. Some cameras later I hope I'll enjoy the same.

Un saludo!

-- hide signature --

Please, excuse my poor english...

Reply   Reply with quote   Complain
trainzmvk
Forum MemberPosts: 73
Like?
Re: CHDK and Canon reaction
In reply to dinny66, May 25, 2007

Has there ever been any reaction, official or not, from Canon on this hack issue?

It would seem with all the people heaping praise on the code that someone over there would wake up and smell the coffee. They have some hot properties on their hands in terms of hardware. All it needs is some better software and they could sell even more of them.

As for the loss of DSLR sales answer, if someone really needs changeable lenses, bigger sensors, etc, they would be buying a DSLR and not P&S with all that that implies.

Reply   Reply with quote   Complain
Marty Too
Senior MemberPosts: 1,000
Like?
Print magazine reaction?
In reply to trainzmvk, May 25, 2007

I doubt Canon can deal with this publicly. They could follow the lead of this software quite easily. Implementation of advanced functions could even be optional based on the needs and desires of the users.

So just as I can decide not to load the firmware extension of Vitaly and Grand, Canon could allow a switch (software or hard wired) that would add advanced functions for those who want them.

I'll ask a different question.

Will print magazines ever (or have they already) publicize this or similar hacks? It would make a nice story showing links to the wiki, etc.

Reply   Reply with quote   Complain
owenjm
Regular MemberPosts: 110
Like?
Re: CHDK and Canon reaction
In reply to trainzmvk, May 26, 2007

trainzmvk wrote:

Has there ever been any reaction, official or not, from Canon on
this hack issue?

It would seem with all the people heaping praise on the code that
someone over there would wake up and smell the coffee. They have
some hot properties on their hands in terms of hardware. All it
needs is some better software and they could sell even more of them.

Hmmm ... I would imagine that if there was a response from Canon, it wouldn't be favourable. Canon has been deliberately crippling its cameras' firmware for years (e.g. lack of RAW on recent offerings, lack of a live histogram on Digic II cameras other than the S80 (which demonstrated that it was an available Digic II function), not to mention the EOS 300D debacle) - they're not going to be happy about software that makes the A640 a more powerful camera than the G7. This is going to be even more of an issue now that we've reached the megapixel saturation point, and the only selling points of new cameras will be features, not resolution.*

Hopefully they haven't noticed, though. Because if they do, you can be sure that they'll try to prevent these sorts of hacks from working on future processors ...

  • although the new 12mp 1/1.8" and 8mp 1/2.5" cams almost suggest that manufactures will keep cramming more pixels onto sensors, oblivious to diffraction and sensitivity ... The S5IS with its 8mp 1/2.5" CCD deserves some sort of prize - it's the first camera to be diffraction limited over its entire aperture range!

Reply   Reply with quote   Complain
GrAnd
Regular MemberPosts: 325
Like?
Build #86
In reply to harvester, May 26, 2007

Build #86:
(Fixes for S-series mostly)

  • S-series: Zoom rocker controls manual focus only if [mf] button is pressed

+ S-series: Various buttons to enter in mode: [shortcut], [flash], [timer], [iso], [video]

  • S-series: Short press of -button - enter to mode; long press - original behaviour

+ S-series: Extended buttons support in script (function 'click') - "iso", "flash", "mf", "macro", "video", "timer"

  • Made the circle of confusion information more precised for each camera model

+ Sokoban: Added undo/redo feature controlled by zoom rocker

Reply   Reply with quote   Complain
microfunguy
Regular MemberPosts: 234
Like?
Re: Build #86
In reply to GrAnd, May 26, 2007

GrAnd wrote:

  • Made the circle of confusion information more precised for each

camera model

Even though the value is very subjective, varying over quite a large range, I have used 0.006 for 1/1.8" sensors and 0.0048 for 1/2.5" sensors.

Basically, sensor-width/1200.

What values did you use ?

David

Reply   Reply with quote   Complain
harvester
Contributing MemberPosts: 693
Like?
Re: Build #86
In reply to GrAnd, May 26, 2007

Very nice! I'm not a S-series owner, but the new features really sound very useful!

Reply   Reply with quote   Complain
Marty Too
Senior MemberPosts: 1,000
Like?
Classic?
In reply to harvester, May 26, 2007

harvester wrote:

Very nice! I'm not a S-series owner, but the new features really
sound very useful!

Anyone besides me think that the CHDK software is making the S3IS even more desirable - almost cementing its place as a classic?

Reply   Reply with quote   Complain
GrAnd
Regular MemberPosts: 325
Like?
Re: Build #86
In reply to microfunguy, May 26, 2007

microfunguy wrote:

GrAnd wrote:

  • Made the circle of confusion information more precised for each

camera model

Even though the value is very subjective, varying over quite a
large range, I have used 0.006 for 1/1.8" sensors and 0.0048 for
1/2.5" sensors.
What values did you use ?

I used the info from here: http://www.dofmaster.com/digital_coc.html

Reply   Reply with quote   Complain
bfollett
Regular MemberPosts: 472
Like?
Re: Build #86
In reply to GrAnd, May 26, 2007

I posted a question to GrAnd about the S2 build which unfortunately ended up being the 150th message in its thread and I never saw a response to it in the next rehash of this thread. I basically asked if the new onscreen displays for battery status (both text and graphical) might be moved a bit, because they currently sit right on top of data already displayed by the camera.

Thanks,

Bob

Reply   Reply with quote   Complain
microfunguy
Regular MemberPosts: 234
Like?
Displaying logos with transparency
In reply to harvester, May 26, 2007

I am displaying a logo on top of a coloured rectangle.

The areas that should be transparent have a value of 0 (zero).

They are displayed as black (same as value 255).

Do I have to use 'MAKE_COLOR' rather than directly providing unsigned short integers ?

Thanks.

David

Reply   Reply with quote   Complain
Keyboard shortcuts:
FForum MMy threads