CHDK firmware hack discussion (13)

Started Jun 29, 2007 | Discussions
Shop cameras & lenses ▾
rlx
rlx Regular Member • Posts: 304
Re: Additions: edit number and print_screen

Russel_Sprouts wrote:

rlx wrote:

There is one problem with print_screen. If the file PR_SCREEN.TXT
already is on the card, when the camera is turned on, it seems that
the 'open file' does not write over the existing file. After

I wondered earlier, but didn't ask, why the (one) static filename
instead of writing to a sequential name? Or, a filename derived frorm
the datestamp? I guess the principal use of printing the screen is to
dump the "benchmarks" results page, eh?

There are many possibilities here, and one wants to keep that as simple
as possible and with a minimum number of additions to UBASIC. So,
as a first step I did the simplest thing.

Following your suggestion, one needs a file counter. So that would be
one couter per SD card I guess.

Regarding the problem I mentioned, I don't know why it was not raised before.

Richard

fingalo Junior Member • Posts: 44
Re: Additions: edit number and print_screen

I merged all changes, all is OK, working as expected!

I tested the problem you experience with open PR_SCREEN.TXT, but as far as I can see I do not get that problem?!

I turn on the camera, execute the script, all new info is written to the file, every time. I tested with a script where I can change the info written.

In MSDOS you would use create instead of open if you would overwrite an existing file always (if I remember correctly such ancient technology...).

And again, the number edit function is REALLY useful.

fingalo

rlx
rlx Regular Member • Posts: 304
Re: Additions: edit number and print_screen

fingalo wrote:

I merged all changes, all is OK, working as expected!

I tested the problem you experience with open PR_SCREEN.TXT, but as
far as I can see I do not get that problem?!

The problem bacame apparent to me when I overwrote a larger file with
a smaller file. The fix is to add 'O_TRUNC' to the 'open' call as follows,

print_screen_d = open(print_screen_file, O_WRONLY~O_CREAT~O_TRUNC, 0777);

I uploaded the corrected code in the tar file. Everything should be fine now.

Russel is suggesting that newly created files be numbered. What is your feeling?

Thanks again for the feedback

Richard

fingalo Junior Member • Posts: 44
Re: Additions: edit number and print_screen

I made a fast test of a cls command. Very promising.

Regarding memory consumtion, I do not know! My knowledge of the inner workings of the SW is very limited.
I think GrAnd would have an idea of the memory constraints for adding features.

fingalo

John NA87 Senior Member • Posts: 1,643
Why aren't jpgs and raws numbered the same?

When I saved a pic with the A620, it saved the jpeg as img_0001.jpg and the raw as crw_0009.crw. I would think the two numbers should match up when saved. I emptied the card but left the 100CANON folder there and shot 3 more pictures. The jpegs were numbered 1,2,3 and the raws were numbered 2,3,4. I deleted all but the first jpeg and the first raw and renamed them both to 0001 and then shot a bunch of pictures and the jpegs and raws both ended up getting numbered the same this time. Seems like if you start with a blank card or turn on raw when there are a number of jpegs already on the card, the raw filename numbers won't match up exactly to the jpeg filename numbers. I find that really confusing.

GrAnd Regular Member • Posts: 325
Re: Additions: edit number and print_screen

rlx wrote:

I have implemented a couple of additions to the CHDK.
EDIT NUMBERS. When editing a number in a menu,
PRINT SCREEN. I added function 'print_screen' to UBASIC.

fingalo wrote:

I have been working on the task to fix the problem of Ubasic
if ... then gosub ... else gosub ...
as decsribed on CHDK wiki, and also added a few more logical operators.

Your additions will be added in the next build.
Richard and fingalo - thank you for the great effort.

GrAnd Regular Member • Posts: 325
Re: Why aren't jpgs and raws numbered the same?

John NA87 wrote:

When I saved a pic with the A620, it saved the jpeg as img_0001.jpg
and the raw as crw_0009.crw. I would think the two numbers should
match up when saved. I emptied the card but left the 100CANON folder
there and shot 3 more pictures. The jpegs were numbered 1,2,3 and
the raws were numbered 2,3,4. [snip]

Try to set "File No. Reset" option in the camera menu to "Off".

GrAnd Regular Member • Posts: 325
Build #144

Build #144
+ Added new RAW support (from test branch)
+ Grid colors overridding

+ Menu: Increment for numbers is controlled by zoom rocker (1,10,100,1000,10000).

+ uBasic: Added "print_screen" command. Following "print_screen 1" whatever the script prints on the screen is also written to file ' CHDK/SCRIPTS/PR_SCREEN.TXT'. (Author: rlx)
+ uBasic: Added "cls" command. Clears mini-console.

  • uBasic: Fixed "if" "else" issue. (Author: fingalo)

+ uBasic: Added logical operations ("and", "or", "not"). Added relation operations ("=", ""). (Author: fingalo)

rlx
rlx Regular Member • Posts: 304
Re: Build #144

Indeed, thanks to Fingalo for fixing the IF command.

alvevind Forum Member • Posts: 66
Will macro_DOFstacker work with S3IS too?

Russel_Sprouts wrote:

macro DOFstacker script (for A6xx series cameras)

The S3IS also has 1 cm macro.
Should this script work for that camera too?
Or will the DOFstacker only work on the A6xx series?

Russel_Sprouts Regular Member • Posts: 257
Re: Will macro_DOFstacker work with S3IS too?

alvevind wrote:

The S3IS also has 1 cm macro.
Should this script work for that camera too?
Or will the DOFstacker only work on the A6xx series?

Without modification, I cannot guess whether the script would support the S3IS.

AFAIK, the S3IS has two macro "modes". The "macro" mode can achieve focus down to 10cm. The "supermacro" mode can achieve focus down to 0cm (subject touching lens). So, unless you have the cam in supermacro mode, I'm not sure it will be able to address steps 0-100 (the nearest ten centimeters) and successfully achieve focus.

So, you'll try it out and let us know, eh?

microfunguy Regular Member • Posts: 234
Re: Build #144

GrAnd wrote:

+ Grid colors overridding

Thanks !

That will be very useful.

David

alvevind Forum Member • Posts: 66
3IS owners please test DOF stacker script

Unfortunately I do not own any Canon camera at this moment, but am about to buy one because of the features of the CHDK hack. Trying do decide between S3IS and A640, leaning towards S3IS.

It would be very helpful if someone owning an S3IS could test whether DOF stacker script will work for supermacro shots. (Hopefully resulting in a stack with focus bands from about 1 cm to infinity, if I've understood the functionality correctly.)

Fragglerock Forum Member • Posts: 68
Build 144

Hi All,

What is new in the last RAW version ? Noise reduction ?

The after Dark Frame... disapeared in build chdk ?

Thanks.

Russel_Sprouts Regular Member • Posts: 257
Re: 3IS owners please test DOF stacker script

alvevind wrote:

(Hopefully resulting in a stack with focus bands from about 1 cm to infinity,
if I've understood the functionality correctly.)

On the near end, the script will produce a stack which reflects apparent continuous DOF (not banding) if shot using an aperture setting in the f5.0 to f8.0 range. Banding (a bad thing) may be apparent if the subject distance is closer than 10cm or so and is shot using f2.8 or other small aperture setting (I didn't test the results at all aperture settings).

As I noted in the wiki docs, you would NOT want to use this script to shoot 0cm to infinity. First, obviously shots from all 65000 steps aren't going to fit on the storage card. Second, you NEED far fewer steps to cover the entire range. By step 400, the DOF for each frame is 5mm deep; past step 1500 or so (hyperfocal distance) one or two additional frames would be required.

A "zero to infinity" script certainly could be written, but plotted points along the DOF overlap scale (curve?) differ for each permutation of focal length x aperture. Even if you choose only one aperture to "support", that would require a table containing predetermined stepping points for each of the 9 variable focal lengths.

dennismullen
dennismullen Veteran Member • Posts: 8,996
Please include S80 in hack

One more plead for the S80, which is also DIGIC II, to be included in the hack.
--
See my gallery at http://www.pbase.com/dennismullen

“Those who would sacrifice liberty for safety deserve neither liberty nor safety.” - Ben Franklin.

fasted58 New Member • Posts: 10
Re: Can't figure out RAW workflow with A620

With the help on this forum I found a raw convertor that works on my macbook and I discovered how to copy the crw files from my memory card and open them. The convertor is called RPP and is a free download. You do your first adjustments right in this program and then save to a tiff file. Iphoto opens the tiff just fine. The detail is fantastic. I can really see why you might want the option of raw format. The 10 mb files are too much for everyday stuff for me but for pics of my family I want the best I can make.

Thanks again to the unselfish people who have written the programs and shared with everyone. I started out just wanting the battery indicator and now I can shoot RAW!!!!! Unbelievable.
EdM.

castaneda363 Junior Member • Posts: 46
Re: Can't figure out RAW workflow with A620

What is noise reduction in new release 144 of CHDK?
Is it Dark Frame Subtraction?

amit goyal Regular Member • Posts: 294
Re: CHDK firmware hack discussion (13)

hi all, i am a new user of s3is, i just read about CHDK firmware,can i use this firmware and how, is there a risk to use this and from where i download this and how upload to my S3IS .please tell me in detail .thanks in advance

melado New Member • Posts: 1
I want to dump A540 firmware

Hi.

I have seen recent GrAnd's work in the wiki, about dumping the firmware via the blue LED of some PowerShot cameras. I tried the ps_a540.fir file and it looks like it works fine (the LED flashes very fast, as I can see). What is the PS_A540_test.FIR file for?

So... I would like to dump the A540 firmware via this method, but once dumped... will someone try to adapt the CHDK to it? Because I know almost nothing about programming and locating memory positions and so on...

Thanks for reading.

Keyboard shortcuts:
FForum MMy threads