Newbie trying to create new firmware version - page 2 - General Discussion and Assistance - CHDK Forum

Newbie trying to create new firmware version

  • 31 Replies
  • 12632 Views
Re: Newbie trying to create new firmware version
« Reply #10 on: 19 / April / 2010, 07:07:20 »
Advertisements


Start with spytask (which does the CHDK UI) and then physw_task (which does input). Once you have those working, you can enable capt_seq, movie_rec etc, one at a time.

OK - looks like I need to research the forum again as another quantum leap in my knowledge is needed...

Another question - when the camera boots I see the red box telling me that I'm running CHDK, camera firmware version etc. - but I don't see the 'control wheels' logo (like the one on the forum header) that I've seen on other cameras running CHDK. Is this normal?

*

Offline fe50

  • ******
  • 3152
  • IXUS50 & 860, SX10 Star WARs-Star RAWs
    • fe50
Re: Newbie trying to create new firmware version
« Reply #11 on: 19 / April / 2010, 07:33:05 »
Another question - when the camera boots I see the red box telling me that I'm running CHDK, camera firmware version etc. - but I don't see the 'control wheels' logo (like the one on the forum header) that I've seen on other cameras running CHDK. Is this normal?

Yes, without logo.dat in \CHDK\DATA folder   --> http://tools.assembla.com/chdk/browser/trunk/CHDK/DATA
The \CHDK default folder is included in the "full" packages from the Autobuild Server, it's the same for all cameras.

Re: Newbie trying to create new firmware version
« Reply #12 on: 19 / April / 2010, 10:58:13 »
Interesting - because I have got logo.dat in the \CHDK\DATA folder, but I don't get a logo.

EDIT - please ignore, I'm completely wrong!!
« Last Edit: 19 / April / 2010, 12:09:41 by leighsinclair »

Re: Newbie trying to create new firmware version
« Reply #13 on: 19 / April / 2010, 12:58:31 »
I'd be really grateful if someone could spend a few minutes checking something out for me. I'm trying to debug my capt_seq.c and I'm comparing it with the SD950 100d version. In the first section of that file there is a branch to sub_FF933CA4, but on the IDA decompilation there is no subroutine at that point. I can't see how it can be a typo as 100d is a working version..what am I overlooking here?


*

Offline reyalp

  • ******
  • 14118
Re: Newbie trying to create new firmware version
« Reply #14 on: 20 / April / 2010, 01:52:46 »
I'd be really grateful if someone could spend a few minutes checking something out for me. I'm trying to debug my capt_seq.c and I'm comparing it with the SD950 100d version. In the first section of that file there is a branch to sub_FF933CA4, but on the IDA decompilation there is no subroutine at that point. I can't see how it can be a typo as 100d is a working version..what am I overlooking here?
Notice it's a B not a BL. It's jumping back into the middle of a function (FF933C30) that has been overridden, since all the parts that need to be changed are done.
Don't forget what the H stands for.

Re: Newbie trying to create new firmware version
« Reply #15 on: 20 / April / 2010, 12:06:54 »
Firstly, many thanks to reyalp and fe50 for their patience. Unfortunately I'm feeling a bit defeated having spent all day removing what I thought were the final typos from boot.c and capt_seq.c only to find very little progress. I have boot-up and OSD, but no capture mode.

It's generally easiest to enable the modified tasks one at a time. Start with spytask (which does the CHDK UI) and then physw_task (which does input). Once you have those working, you can enable capt_seq, movie_rec etc, one at a time.

Sadly I don't have the necessary knowledge to do this, and I can't find the procedure explained anywhere, so I can only hope that once I have rewritten movie_rec.c everything will spring into life. I'm not holding my breath, though. It's annoying as it seems that an offset of 34 bytes is the only code alteration that should be needed.

What is concerning me most right now is that I still can't compile either my new version (100e) or the original (100d) unless I comment out the dummy function in lib.c concerning ExitFromCompensationEVF and enable the NHSTUB in stubs_entry_2.s that points to FFFFFFFF - which is the opposite way round to the way I understand it should work. Could this be anything to do with my problem?

Sorry if this is too elementary a problem to be discussed here - I'd happily take a reply by PM!

*

Offline reyalp

  • ******
  • 14118
Re: Newbie trying to create new firmware version
« Reply #16 on: 20 / April / 2010, 22:14:59 »
Sadly I don't have the necessary knowledge to do this, and I can't find the procedure explained anywhere, so I can only hope that once I have rewritten movie_rec.c everything will spring into life. I'm not holding my breath, though. It's annoying as it seems that an offset of 34 bytes is the only code alteration that should be needed.
If you haven't already, you may want to look through http://chdk.wikia.com/wiki/Adding_support_for_a_new_camera

My guide to supporting a new FW version doesn't go into the details of how CHDK is put together.
Quote
What is concerning me most right now is that I still can't compile either my new version (100e) or the original (100d) unless I comment out the dummy function in lib.c concerning ExitFromCompensationEVF and enable the NHSTUB in stubs_entry_2.s that points to FFFFFFFF - which is the opposite way round to the way I understand it should work. Could this be anything to do with my problem?
If you can't build an existing firmware with a clean checkout from SVN, then something is wrong with your build environment. I'd suggest working that out before you worry about getting new code working.

Note that there are some incorrect or incomplete dumps floating around, which can cause problems in the build process, or result in non-functional builds. This generally shows up if required entry points aren't found, or the generated stubs_entry.S of an existing port doesn't match what's in SVN.
Quote
Sorry if this is too elementary a problem to be discussed here - I'd happily take a reply by PM!
No, it's better to have it here. More people will be able to help you, and others people who have the same problems in the future may find it.
Don't forget what the H stands for.

Re: Newbie trying to create new firmware version
« Reply #17 on: 21 / April / 2010, 13:00:26 »

Sorry if this is too elementary a problem to be discussed here - I'd happily take a reply by PM!
No, it's better to have it here. More people will be able to help you, and others people who have the same problems in the future may find it.

If you can't build an existing firmware with a clean checkout from SVN, then something is wrong with your build environment. I'd suggest working that out before you worry about getting new code working.

Well - I really hope you've got the patience to see me through this, and that it will help someone else - I promise I will limit myself to a single daily update.

Today I began trying to sort out the build environment, concentrating first on trying to compile SD950 v100d.
I deleted CHDK shell for Windows 2.70 and all associated files and reinstalled it
I allowed it to load trunk 885
I put the 100d primary.bin in sub>100d
I compiled (all compilations using the command line and the clean fir command) - it worked.
I then added the six reference files to the tools folder one by one, compiling each time. The compilations worked until the last one (dryos_3). Then I got the ExitFromCompensationEVF error message. I could then only compile after making the file alterations detailed in my post above.
I deleted and reloaded trunk885 and repeated the above procedure with v100e using my own firmware dump.
The results were identical.

Please can you tell me what I should do next, as I seem to have reached a dead end for the moment!
 


*

Offline reyalp

  • ******
  • 14118
Re: Newbie trying to create new firmware version
« Reply #18 on: 22 / April / 2010, 00:34:46 »
Well - I really hope you've got the patience to see me through this, and that it will help someone else - I promise I will limit myself to a single daily update.
If you want more real-time help, you can try in the IRC channel #chdk on irc.freenode.net
Quote
Today I began trying to sort out the build environment, concentrating first on trying to compile SD950 v100d.
I deleted CHDK shell for Windows 2.70 and all associated files and reinstalled it
I allowed it to load trunk 885
I put the 100d primary.bin in sub>100d
I compiled (all compilations using the command line and the clean fir command) - it worked.
I then added the six reference files to the tools folder one by one, compiling each time. The compilations worked until the last one (dryos_3).
signatures_dryos.h will not be built unless all three reference binaries are present. The vxworks ones are ignored.

ixus960_sd950 works for me out of the box, with all reference bins in place. Deleted the generated files to be sure they are being generated correctly, and the result is the same as what's in svn.

I don't see how you would get that error with ExitFromCompensationEVF since the auto-generated symbols should be weak anyway.
Don't forget what the H stands for.

Re: Newbie trying to create new firmware version
« Reply #19 on: 22 / April / 2010, 12:52:01 »
To eliminate strange registry settings etc from the equation, today I moved to another computer with no CHDK files whatsoever installed. Then I

Installed CHDK shell for Windows 2.70
I allowed it to load trunk 885
I put all sig reference files in the tools folder
I put seven assorted SD series firmware dumps in the relevant subs
Compiled using the GUI - did they compile witout error messages? Results....

SD990 100e  no
SD990 101b  yes
SD950 100d  no
SD850 100c  yes
SD880 102b  no
SD870 100c  no
SD800 100e  yes

Is there any kind of pattern here? I'm beginning to doubt my sanity!! What on earth am I doing wrong?

 

Related Topics


SimplePortal 2.3.6 © 2008-2014, SimplePortal