CHDK UI version 2.0 ? - page 25 - General Discussion and Assistance - CHDK Forum supplierdeeply

CHDK UI version 2.0 ?

  • 542 Replies
  • 98106 Views
*

Online philmoz

  • *****
  • 3332
    • Photos
Re: CHDK UI version 2.0 ?
« Reply #240 on: 27 / July / 2012, 23:48:37 »
Advertisements
Revision 2015 & 2016 merge my UI changes to the trunk version, plus the User Menu messages when adding items as suggested by waterwingz.

Phil.
« Last Edit: 28 / July / 2012, 00:55:40 by philmoz »
CHDK ports:
  sx30is (1.00c, 1.00h, 1.00l, 1.00n & 1.00p)
  g12 (1.00c, 1.00e, 1.00f & 1.00g)
  sx130is (1.01d & 1.01f)
  ixus310hs (1.00a & 1.01a)
  sx40hs (1.00d, 1.00g & 1.00i)
  g1x (1.00e, 1.00f & 1.00g)
  g5x (1.00c, 1.01a, 1.01b)
  g7x2 (1.01a, 1.01b, 1.10b)

*

Online philmoz

  • *****
  • 3332
    • Photos
Re: CHDK UI version 2.0 ?
« Reply #241 on: 27 / July / 2012, 23:54:14 »
BTW: CHDK.CFG is renamed from release to release. And this surely much more broke inter-version compatibility. Isn't it? :)

No, the config file name should only be changed if there is a significant change to the file itself.
It was changed for the module version of CHDK because the two versions got so out of synch with the config item numbers that it became very difficult to re-align them (which was further complicated by the merge of the CHKD & CHDK-DE code).

Phil.
CHDK ports:
  sx30is (1.00c, 1.00h, 1.00l, 1.00n & 1.00p)
  g12 (1.00c, 1.00e, 1.00f & 1.00g)
  sx130is (1.01d & 1.01f)
  ixus310hs (1.00a & 1.01a)
  sx40hs (1.00d, 1.00g & 1.00i)
  g1x (1.00e, 1.00f & 1.00g)
  g5x (1.00c, 1.01a, 1.01b)
  g7x2 (1.01a, 1.01b, 1.10b)

Re: CHDK UI version 2.0 ?
« Reply #242 on: 28 / July / 2012, 12:38:45 »
@tsvstar :  tried the lastest svn version of your code (svn rev 2018).  Took a little while to get working as my ptp download code only loads diskboot.bin and the .flt modules.  But if your help file is not on the SD card,  the code hangs and needs a "battery remove" reset. When you get a moment, it might be good to make it a little more "fault tolerant"  and check if the file exists ?

I have a question though.   Where did you put the menu item for switching between the simple/normal/advanced menu modes ?  After 5 minutes of scrolling around I can't find it.

« Last Edit: 28 / July / 2012, 13:04:50 by waterwingz »
Ported :   A1200    SD940   G10    Powershot N    G16

Re: CHDK UI version 2.0 ?
« Reply #243 on: 28 / July / 2012, 12:53:41 »
I have another UI 2.0 suggestion and I think it relates to why we all hate to delete the CCHDK.CFG & CHDK2.CFG files.

Most of what's in there is just a convenient way of having the same camera setup between boots of CHDK.  However, having to reset the OSD icons each time we delete that file is a major hassle.  And part of the reason for that is there is no way to let somebody porting a new camera specify a layout that "looks good" for that camera.   I realize that this will be a matter of personal taste,  but being able to arrange things to be at least somewhat compatible with the Canon OSD for each camera would be nice.

As I assume that we don't want to repeat the mess made with the CAM_ADJUSTABLE_ALT_BUTTON in core/gui.c would it make sense to allow some sort of camera dependent OSD defaults in platform_camera.h ?
Ported :   A1200    SD940   G10    Powershot N    G16


Re: CHDK UI version 2.0 ?
« Reply #244 on: 28 / July / 2012, 16:31:17 »
I have another UI 2.0 suggestion and I think it relates to why we all hate to delete the CCHDK.CFG & CHDK2.CFG files.

Most of what's in there is just a convenient way of having the same camera setup between boots of CHDK.  However, having to reset the OSD icons each time we delete that file is a major hassle.  And part of the reason for that is there is no way to let somebody porting a new camera specify a layout that "looks good" for that camera.   I realize that this will be a matter of personal taste,  but being able to arrange things to be at least somewhat compatible with the Canon OSD for each camera would be nice.

As I assume that we don't want to repeat the mess made with the CAM_ADJUSTABLE_ALT_BUTTON in core/gui.c would it make sense to allow some sort of camera dependent OSD defaults in platform_camera.h ?


I like the idea of OSD designed for each ported camera model. For old ports default values should exist. Also I think that now is good time to consider whether the CFG file shouldn't be in pure text form instead of binary. Major advantages:

- easy to edit in text editor
- easy to fix bugs
- once the syntax is developed the back compatibility is not a big problem - no orphan entries etc.

Even when major changes break the compatibility of some entries there would be relatively easy to update the file by hand. There could be entry with system version which would allow the CHDK to check whether the CFG is compatible with current CHDK.

As it was pointed somewhere before the XML-based languages are too complex for such purpouse, so maybe simple form:

parameter_name value

for example:

Code: [Select]
script_autostart false
bat_ico_x 120
bat_ico_y 10
tv_override -100
histo_show 3

Disadvantages:

- significant size increase of the file
- much effort to provide the parser and implement the infrastructure in place of current system.
- documentation...

PS. tsvstar - Thank you for your wishes! Nevertheless, I'm not Russian, but Pole. However, I clearly understand russian :)
if (2*b || !2*b) {
    cout<<question
}

Compile error: poor Yorick

Re: CHDK UI version 2.0 ?
« Reply #245 on: 28 / July / 2012, 17:23:30 »
But if your help file is not on the SD card,  the code hangs and needs a "battery remove" reset. When you get a moment, it might be good to make it a little more "fault tolerant"  and check if the file exists ?
Actually this is strange. I tested and it works with help file and without. With textreader module and without.
The only one issue on my s95 is that after exit from help camera shutdown.

Could you please ensure that textread.flt is new one? Because I'm really surprised.

Quote
I have a question though.   Where did you put the menu item for switching between the simple/normal/advanced menu modes ?  After 5 minutes of scrolling around I can't find it.
Since rev1999 no more "advanced mode" in my branch. First feedback was that simple mode is acceptable and enough.  So code could be simplified, no additional control.
Try 1998 if you interested to play with switching modes.
« Last Edit: 28 / July / 2012, 17:25:13 by tsvstar »

Re: CHDK UI version 2.0 ?
« Reply #246 on: 28 / July / 2012, 17:45:29 »
- once the syntax is developed the back compatibility is not a big problem - no orphan entries etc.
actually back-compatibility is not a problem for current format too.
if you need something different - you have to simply add new entry.
Issue with inter-release changes is big difference of behavior/meaning of some entries.

Quote
Disadvantages:
- significant size increase of the file
- much effort to provide the parser and implement the infrastructure in place of current system.
- documentation...
Two more disadvantages which are more significant then listed as for me:
- possible impact to chdk core binary size. a) We need to store names of each parameter. b) I think parser/writer will be big and complex thing
- possible impact to speed. Currently you are able to make your camera start almost also as quick as without CHDK (just turn off autoscript and other complex things). But with this I have no other option then wait until CHDK make complex large parsing. CPU on cameras still far even from smartphones.

If I understand correct, main declared advantage is "easy to edit". I think that this could be implemented as module and/or PC convertor. This is more safe and no any impact solution.

Re: CHDK UI version 2.0 ?
« Reply #247 on: 28 / July / 2012, 17:45:43 »
Actually this is strange. I tested and it works with help file and without. With textreader module and without.
Sorry - I assumed it was the Help file because when I only loaded diskboot.bin and the .flt modules,  I could hard lock up the camera 100% by going to the Help menu item.  Might be some other files needed too that were causing the hang ?

Quote
The only one issue on my s95 is that after exit from help camera shutdown.
Probably not a good sign ?

Quote
Could you please ensure that textread.flt is new one? Because I'm really surprised.
I've got the latest svn version checked out and the make file builds everything AFAIK.

Quote
Since rev1999 no more "advanced mode" in my branch.
Thanks - I'll see how that works for me.
Ported :   A1200    SD940   G10    Powershot N    G16


Re: CHDK UI version 2.0 ?
« Reply #248 on: 28 / July / 2012, 18:05:31 »
Quote
Sorry - I assumed it was the Help file because when I only loaded diskboot.bin and the .flt modules,  I could hard lock up the camera 100% by going to the Help menu item.  Might be some other files needed too that were causing the hang?
Algorithm of help is very simple:
1. When enter to alt mode, check flag in cfg file. If it raised works as before.
If it is not raised
2. Raise the flag. Save config file (to prevent any possiblity of cyclic hangup on start)
3. Construct help file path
4. Run "textread.flt" module with argument help_file_path.

Nothing more. So no other files should affect this.
Could you please make experiments - with/without  module + with/without helpfile

Quote
Probably not a good sign?
I agree. But this is very hard to catch issue. And at same time it doesn't broke anything in my case.
Press power first time - see help file - press menu to exit - camera turned off - press power - get to work.

Quote
I've got the latest svn version checked out and the make file builds everything AFAIK.
Just my experience: When I stabilize new feature I rebuild and rewrote CHDK on SD every five minutes. And I rarely update flt. I believed in API versioning checks. :) But probably it is in out-of-sync status or maybe GCC version related issue. Anyhow but in some way on new CHDK some old modules worked wrong. For example it fselect always think that shoot is halfpressed.

I hunt this bug about a hour, while just make full compile + full overwrite everything on card :)

Re: CHDK UI version 2.0 ?
« Reply #249 on: 28 / July / 2012, 19:38:09 »
Could you please make experiments - with/without  module + with/without helpfile
Okay - here's what I did.  You can probably reproduced it too.

1) Updated to latest svn versions for trunk and tsvstar
2) Built and installed and ran trunk version on clean SD card.
3) Built tsvstar version and downloaded the diskboot.bin file and all .flt files to the sd card from step 2 above.
4) Start camera (playback mode), activate CDHK menu,  go to Miscellaneous Stuff -> Show HELP.
5) Camera GUI hangs.  Background task that simply blinks my cameras power LED continues to run.  Other operations unpredictable.

Unzipping the complete tsvstar zip file corrects the action above.   A little mystery perhaps but probably not worth a lot more time ?



Ported :   A1200    SD940   G10    Powershot N    G16

 

Related Topics