extra long exposures (split from: Hardcore modding on a A530, thanks to CHDK! - page 14 - General Discussion and Assistance - CHDK Forum  

extra long exposures (split from: Hardcore modding on a A530, thanks to CHDK!

  • 184 Replies
  • 82823 Views
Advertisements
(...)
You feed it a disassembly snippet originating from Chr's disassembly perl script and it spits out something that is hopefully very close to being acceptably formatted for direct inclusion in CHDK platform source code. I used it with the a650 long exposure port above (which remains untested) and it seemed to work rather fine, but make sure you read all the comments in the script.. it's not a particularly smart one and likely requires some tuning/additions for each firmware but ought to make ones life easier nonetheless...
Hoo yes...
There are some errors in compilation:
Quote
../platform/ixus860_sd870/sub/100c/libplatformsub.a(capt_seq.o): In function `loc_FFC97404':
capt_seq.c:(.text+0x3f0): undefined reference to `sub_FFC17B08'
../platform/ixus860_sd870/sub/100c/libplatformsub.a(capt_seq.o): In function `loc_FFC9744C':
capt_seq.c:(.text+0x44c): undefined reference to `sub_FFC17884'
../platform/ixus860_sd870/sub/100c/libplatformsub.a(capt_seq.o): In function `loc_FFC97498':
capt_seq.c:(.text+0x488): undefined reference to `sub_FFC178B8'
../platform/ixus860_sd870/sub/100c/libplatformsub.a(capt_seq.o): In function `loc_FFC974E8':
capt_seq.c:(.text+0x4e0): undefined reference to `sub_FFC178B8'
../platform/ixus860_sd870/sub/100c/libplatformsub.a(capt_seq.o): In function `loc_FFC9752C':
capt_seq.c:(.text+0x510): undefined reference to `sub_FFC0BDB8'
../platform/ixus860_sd870/sub/100c/libplatformsub.a(capt_seq.o): In function `sub_FFC94E94_my':
capt_seq.c:(.text+0x988): undefined reference to `sub_FFC178B8'
../platform/ixus860_sd870/sub/100c/libplatformsub.a(capt_seq.o): In function `loc_FFC94F48':
capt_seq.c:(.text+0xa7c): undefined reference to `sub_FFC0BDB8'
../platform/ixus860_sd870/sub/100c/libplatformsub.a(capt_seq.o): In function `loc_FFC94FA0':
capt_seq.c:(.text+0xaa8): undefined reference to `sub_FFC0BDB8'
../platform/ixus860_sd870/sub/100c/libplatformsub.a(capt_seq.o): In function `sub_FFC7654C_my':
capt_seq.c:(.text+0xacc): undefined reference to `sub_FFC0BDB8'
capt_seq.c:(.text+0xae8): undefined reference to `sub_FFC0BDB8'
capt_seq.c:(.text+0xb10): undefined reference to `sub_FFC0BDB8'
collect2: ld returned 1 exit status
E:\softs\canon\CHDK_dev\gcc4\bin\gmake[1]: *** [main.elf] Error 1
gmake: *** [all-recursive] Error 1
T.T
I think it's 'cause I put many lines in the file "stubs_auto.S" and someones else are needed...

*

Offline reyalp

  • ******
  • 14080
Yes, full version of IDA is not free..
But, as you say; I don't need IDA 'cause I just want to modify some parts of the code and compile it.
So, I'll use my usual editor and I'll see.

Thanks for informations -.^
To implement long exposures, you need to disassemble a large chunk of your cameras firmware code, in a format similar to that used by IDA. You cannot copy this from another camera, and you can't just make it with a text editor. If you have sufficient knowledge, you can do it with the GPL tools rather than IDA. The stuff fudgey linked will help.

regarding your compile errors, it looks like stubs_auto.S was not generated correctly.
Don't forget what the H stands for.

Ah.. Oki, sorry. I was not there, I thought all parts of the disassembly are in sources when you download full sources from the SVN-repository.

I start to understand what's wrong: I have to know what are "sub_name" calls for the SD870 by seeking it in the disassembly dump file. Am I right?

However, I think it's over of my PHP/AS coder capability... T.T
Any help can be expected?

*

Offline fudgey

  • *****
  • 1705
  • a570is
You should never need to edit stubs_auto.S manually (and if you do it should have no effect). You may need to delete it manually to force regeneration, though (happened to me once from svn trunk for one of these long exposure things; someone committed code that didn't include updated stubs_auto.S and my make didn't recreate it for some reason... I have no clue why).

stubs_auto.S is generated build-time thanks to an infernally beautiful chunk of regexp shell stuff in platform/makefile_sub.inc. For what I can understand of that, it looks for strings of format 'sub_xxxxxxxx' in platform code files (STUBS_AUTO_DEPS as defined in platform/*/sub/*/Makefile, I suppose) and creates stubs for all matches.


Oki, I was wrong in all the line..
I did not know what the file "stub_auto.S" is auto-generated.
Thanks for this information, and yes, I'll regenerate all files.

Can you tell me what files I have to modify and don't modify?

*

Offline reyalp

  • ******
  • 14080
Can you tell me what files I have to modify and don't modify?
I already told you. Look at one of the previous checkins that added long exposure support. Then do the equivalent thing, by disassembling the corresponding part of your cameras firmware and adding exp_drv_task to your cameras port.

All the autogenerated files have a comment at the top warning you that they are generated.
Don't forget what the H stands for.

(...)
All the autogenerated files have a comment at the top warning you that they are generated.
Oops, sorry, I did not saw it.

*

Offline mngc

  • ***
  • 113
  • a590is fw 1.0.1b & sx110is fw 1.0b
Now some test with a590is fw 1.0.b

- Extra long exposure test with autobuild 778 => OK
- 460 sec. exposure ok, but 470 sec. or more exposure not ok (totally black image, time is ok)

I try generate dark frame(s) with 460 sec. This is difficult. The optical element very weak, do not use any lens cap! I try use "black box", with 10 sec timer, the camera now in the "black box". The dark frame image very bad, very bright, non-usable. I think the problem, the camera own light, the two blinking LED and the black, but not totally black LCD screen. The best method to record dark frame, the canon ring and wide angle converter with own lens cap of wide angle converter. Now the dark frame near ok, only small exposured circle the problem (i think, the canon ring or the wide angle converter not 100% block the external light.
Of course the single dark frame noisy, i see number of hot spot, and have amplifier glow. (possibly the ccd amplifier on/off with CHDK?, amplifier glow strong, but not fatal)

Next i try record set of dark frame, with internal canon function (user timer). The 1. picture recording, the two leds blinking, but if 2. picture recording the two leds not blinking, i think, the camera is freeze, but no, both picture recorded correctly. I not understand. Currently i have not fully processed images to master dark.

I have some test images, if anybody interested, the test picture upload to forum is correct?
Real astrophotography test images not available yet, many night rainy or cloudy. :(

I try this ugly,and risky script, see under. I want to write the script, with user selectable long exposure time in sec. I not understand, how i do it. I find some information on forum. This script takes 150 sec. = 150* 1 000 000 uSec. image. I think apex2us convert it, but i not know how it. What formula used to convert seconds to this value (-694). Or this script idea bad, more elegant function to control exposure time for this script available? 

rem Tested on A590IS
@title Extra Long Exposure - Test

@param a Value
@default a -694

set_tv96_direct a

shoot


*

Offline nonno

  • *
  • 15
I've just tested the a650 with the experimental code: the exposure limit is still 64sec even if i set the time to 80 and 101 in a second try.
I'm sorry that i can't help you in the development of the code (i'm not a very skilled programmer) but if i can help in some way I'm here, just tell me what to do (i study electronic engineering so i understand the matter but i really don't know how to dirt my hands - i hope i'll find the time to learn something on chdk coding this summer)


 

Related Topics