SX50 HS porting thread - page 34 - DryOS Development - CHDK Forum supplierdeeply

SX50 HS porting thread

  • 350 Replies
  • 158310 Views
Re: SX50 HS porting thread
« Reply #330 on: 16 / April / 2015, 07:44:40 »
Advertisements
Quote
and the other problem is that the slowest shutter speed is 15 seconds and it's very high for taking pictures of stars  is there any port for this too?
Using CHDK can set the shutter speed for more than 60 seconds (90 seconds personally tried, tested stopwatch, although the camera shows 60 seconds).

Main Menu -> Enhanced Photo Operations -> Override Tv type = LongExp, Long Exp. Value = 0:01:30 (for example).
« Last Edit: 16 / April / 2015, 07:46:31 by Malysh-ok »
Camera is SX50hs

Re: SX50 HS porting thread
« Reply #331 on: 16 / April / 2015, 08:55:24 »
First when I try to taje pictures with the shutter speed over one second,the ISO wont be manual anymore and it'll set for 80 automatically is there any port to do sth about this?
You can use the  Override ISO  option in the CHDK  Enhanced Photo Operations menu to overcome this.

Quote
and the other problem is that the slowest shutter speed is 15 seconds and it's very high for taking pictures of stars  is there any port for this too?
You can use the Override Tv  option in the CHDK  Enhanced Photo Operations menu to overcome this.

Quote
And the last one can I control the shutter speed with the remote control?
There is nothing "built-in" to do that so you will need to write a small script.  What remote control device were you hoping to use?

Quote
Will it work on bridge cameras??
The term "bridge" camera refers to the more advanced "point & shoot" cameras which supposedly bridge the gap between "point & shoot" and DSLR's.   The distinction does not matter to CHDK - if there is a CHDK port for a particular camera then it will work.  And yes,  there is a working port for the SX50hs.
Ported :   A1200    SD940   G10    Powershot N    G16

Re: SX50 HS porting thread
« Reply #332 on: 18 / April / 2015, 06:35:53 »
Please tell me how to CHDK Saves the parameters (in particular - conf.subj_dist_override_value), so that after turn on the camera left their previous value?
Camera is SX50hs

Re: SX50 HS porting thread
« Reply #333 on: 18 / April / 2015, 06:52:42 »
Please tell me how to CHDK Saves the parameters (in particular - conf.subj_dist_override_value), so that after turn on the camera left their previous value?
CHDK reads a set of files from the SD card on startup,  and writes to them when things change.

Code: [Select]
#define CONF_FILE           "A/CHDK/CCHDK4.CFG"
#define OSD_CONF_FILE       "A/CHDK/OSD__4.CFG"
#define USER_MENU_CONF_FILE "A/CHDK/UMENU4.CFG"
#define GPS_CONF_FILE       "A/CHDK/GPS__4.CFG"
Look in core/conf.c starting around line 617

Edit : changed core/gui.c to core/conf.c
« Last Edit: 19 / April / 2015, 09:09:42 by waterwingz »
Ported :   A1200    SD940   G10    Powershot N    G16


Re: SX50 HS porting thread
« Reply #334 on: 18 / April / 2015, 09:19:04 »
Look in core/gui.c starting around line 617
Something I could not see anything associated with conf.subj_dist_override_value.

I added a variable in the structure conf, I do not understand how can I save its value.
« Last Edit: 18 / April / 2015, 10:35:19 by Malysh-ok »
Camera is SX50hs

Re: SX50 HS porting thread
« Reply #335 on: 18 / April / 2015, 12:22:47 »
Look in core/gui.c starting around line 617
Something I could not see anything associated with conf.subj_dist_override_value.
That's because the variable used is conf.subj_dist_override_koef.

Quote
I added a variable in the structure conf, I do not understand how can I save its value.
That will happen automatically if you added it in the right place.  However, what you added is not what is used by the subject distance override GUI so you would not have seen anything happen.

Incidentally,  I just tested and can confimr that the SD override value is saved and restored correctly.  Did you remember to turn off the 
Disable Overrides on Startup [ * ]
menu item in the Enhanced Photo Operations menu ?
Ported :   A1200    SD940   G10    Powershot N    G16

Re: SX50 HS porting thread
« Reply #336 on: 18 / April / 2015, 14:39:41 »
That's because the variable used is conf.subj_dist_override_koef.
Code: (core/gui.c, lines 608-759:) [Select]
static void gui_draw_read_selected(const char *fn)
{
    if (fn)
    {
libtxtread->read_file(fn);
    }
}

static void gui_draw_read(int arg)
{
    libfselect->file_select(LANG_STR_SELECT_TEXT_FILE, conf.reader_file, "A/CHDK/BOOKS", gui_draw_read_selected);
}

static void gui_draw_read_last(int arg)
{
    if (stat(conf.reader_file,0) == 0)
        gui_draw_read_selected(conf.reader_file);
    else
        gui_draw_read(arg);
}

static void gui_draw_rbf_selected(const char *fn)
{
    if (fn) {
        strcpy(conf.reader_rbf_file, fn);
    }
}

static void gui_draw_load_rbf(int arg)
{
    libfselect->file_select(LANG_STR_SELECT_FONT_FILE, conf.reader_rbf_file, "A/CHDK/FONTS", gui_draw_rbf_selected);
}

static const char* gui_reader_codepage_cps[] = { "Win1251", "DOS"};
static CMenuItem reader_submenu_items[] = {
    MENU_ITEM(0x35,LANG_MENU_READ_OPEN_NEW,           MENUITEM_PROC,    gui_draw_read, 0 ),
    MENU_ITEM(0x35,LANG_MENU_READ_OPEN_LAST,          MENUITEM_PROC,    gui_draw_read_last, 0 ),
    MENU_ITEM(0x35,LANG_MENU_READ_SELECT_FONT,        MENUITEM_PROC,    gui_draw_load_rbf, 0 ),
    MENU_ENUM2(0x5f,LANG_MENU_READ_CODEPAGE,          &conf.reader_codepage, gui_reader_codepage_cps ),
    MENU_ITEM(0x5c,LANG_MENU_READ_WORD_WRAP,          MENUITEM_BOOL,    &conf.reader_wrap_by_words, 0 ),
    MENU_ITEM(0x5c,LANG_MENU_READ_AUTOSCROLL,         MENUITEM_BOOL,    &conf.reader_autoscroll, 0 ),
    MENU_ITEM(0x5f,LANG_MENU_READ_AUTOSCROLL_DELAY,   MENUITEM_INT|MENUITEM_F_UNSIGNED|MENUITEM_F_MINMAX, &conf.reader_autoscroll_delay, MENU_MINMAX(0, 60) ),
    MENU_ITEM(0x51,LANG_MENU_BACK,                    MENUITEM_UP, 0, 0 ),
    {0}
};

static CMenu reader_submenu = {0x37,LANG_MENU_READ_TITLE, reader_submenu_items };

//-------------------------------------------------------------------

static CMenuItem games_submenu_items[] = {
    MENU_ITEM(0x38,LANG_MENU_GAMES_REVERSI,           MENUITEM_PROC,  module_run, "reversi.flt" ),
    MENU_ITEM(0x38,LANG_MENU_GAMES_SOKOBAN,           MENUITEM_PROC,  module_run, "sokoban.flt" ),
    MENU_ITEM(0x38,LANG_MENU_GAMES_CONNECT4,          MENUITEM_PROC,  module_run, "4wins.flt" ),
    MENU_ITEM(0x38,LANG_MENU_GAMES_MASTERMIND,        MENUITEM_PROC,  module_run, "mastmind.flt" ),
    MENU_ITEM(0x38,"Snake" ,                          MENUITEM_PROC,  module_run, "snake.flt" ),
    MENU_ITEM(0x38,"Tetris",                          MENUITEM_PROC,  module_run, "tetris.flt" ),
MENU_ITEM(0x38,"Sudoku",   MENUITEM_PROC,  module_run, "sudoku.flt" ),
    MENU_ITEM(0x51,LANG_MENU_BACK,                    MENUITEM_UP, 0, 0 ),
    {0}
};

static CMenu games_submenu = {0x38,LANG_MENU_GAMES_TITLE, games_submenu_items };

//-------------------------------------------------------------------

static void gui_menuproc_mkbootdisk(int arg)
{
    mark_filesystem_bootable();
    gui_mbox_init(LANG_INFORMATION, LANG_CONSOLE_TEXT_FINISHED, MBOX_BTN_OK|MBOX_TEXT_CENTER|MBOX_FUNC_RESTORE, NULL);
}

#if CAM_MULTIPART

static void card_break_proc(unsigned int btn)
{
    if (btn==MBOX_BTN_YES) create_partitions();
}

static void gui_menuproc_break_card(int arg)
{
    gui_mbox_init(LANG_WARNING, LANG_PARTITIONS_CREATE_WARNING, MBOX_BTN_YES_NO|MBOX_DEF_BTN2|MBOX_TEXT_CENTER|MBOX_FUNC_RESTORE, card_break_proc);
}

static char* partitions_enum=NULL;

static const char* gui_menuproc_swap_partitions_enum(int change, int arg)
{
    int new_partition;
    int partition_count = get_part_count();
    char vBuf[16];
    if(partitions_enum)
    {
      free(partitions_enum);
      partitions_enum=NULL;
    }
    new_partition= get_active_partition()+change;
    if( new_partition <=0)
    {
      new_partition = partition_count;
    }
    else if( new_partition > partition_count)
    {
      new_partition = 1;
    } 
    sprintf(vBuf,"%d/%d",new_partition, partition_count);
    partitions_enum=malloc((strlen(vBuf)+1)*sizeof(char));
    strcpy(partitions_enum,vBuf);

    if(change != 0)
    {
      swap_partitions(new_partition);
    }
    return partitions_enum;
}

#endif

static CMenuItem sdcard_submenu_items[] = {
    MENU_ITEM   (0x33,LANG_MENU_DEBUG_MAKE_BOOTABLE,        MENUITEM_PROC,                  gui_menuproc_mkbootdisk, 0 ),
#if CAM_MULTIPART
    MENU_ITEM   (0x33,LANG_MENU_DEBUG_CREATE_MULTIPART ,    MENUITEM_PROC,                  gui_menuproc_break_card,            0 ),
    MENU_ITEM   (0x33,LANG_MENU_DEBUG_SWAP_PART,            MENUITEM_ENUM,                  gui_menuproc_swap_partitions_enum,  0 ),
#endif
    MENU_ITEM   (0x51,LANG_MENU_BACK,                       MENUITEM_UP,                    0,                                  0 ),
    {0},
};

static CMenu sdcard_submenu = {0x33,LANG_SD_CARD, sdcard_submenu_items };

//-------------------------------------------------------------------

static void gui_delete_module_log_callback(unsigned int btn)
{
    if (btn == MBOX_BTN_YES)
        module_log_clear();
}

static void gui_delete_module_log(int arg)
{
    gui_mbox_init(LANG_WARNING, LANG_MENU_DELETE_MODULE_LOG, MBOX_BTN_YES_NO|MBOX_DEF_BTN2|MBOX_TEXT_CENTER|MBOX_FUNC_RESTORE, gui_delete_module_log_callback);
}

static CMenuItem module_submenu_items[] = {
    MENU_ITEM   (0x80,LANG_MENU_MODULE_INSPECTOR,           MENUITEM_PROC,                  module_run, "modinsp.flt" ),
    MENU_ITEM   (0x5c,LANG_MENU_MODULE_LOGGING,             MENUITEM_BOOL,                  &conf.module_logging, 0 ),
    MENU_ITEM   (0x2b,LANG_MENU_DELETE_MODULE_LOG,          MENUITEM_PROC,                  gui_delete_module_log, 0 ),
    MENU_ITEM   (0x51,LANG_MENU_BACK,                       MENUITEM_UP,                    0, 0 ),
    {0},
};

static CMenu module_submenu = {0x28,LANG_MENU_MODULES, module_submenu_items };
???
« Last Edit: 18 / April / 2015, 14:41:53 by Malysh-ok »
Camera is SX50hs

Re: SX50 HS porting thread
« Reply #337 on: 18 / April / 2015, 14:51:18 »
Incidentally,  I just tested and can confimr that the SD override value is saved and restored correctly.
Yes, that's all good.

Quote
That will happen automatically if you added it in the right place.  However, what you added is not what is used by the subject distance override GUI so you would not have seen anything happen.
And you can more?
I added a variable in the structure conf (core/conf.h), and in array conf_info (core/conf.c), but the value is not saved.
Camera is SX50hs


Re: SX50 HS porting thread
« Reply #338 on: 18 / April / 2015, 16:13:12 »
???
Sorry - I had too many files open at the time. I should have said "Look in core/conf.c starting around line 617".

A quick grep on any of the file names I listed ( e.g. CCHDK4.CFG) would have told you that.

And you can more? I added a variable in the structure conf (core/conf.h), and in array conf_info (core/conf.c), but the value is not saved.
CHDK developers put additional things there almost every time a new feature is added.
Ported :   A1200    SD940   G10    Powershot N    G16

Re: SX50 HS porting thread
« Reply #339 on: 19 / April / 2015, 02:50:50 »
Quote
CHDK developers put additional things there almost every time a new feature is added.
Can you still explain how to do it?
Camera is SX50hs

 

Related Topics


SimplePortal 2.3.6 © 2008-2014, SimplePortal