Magic Lantern Forum

Developing Magic Lantern => General Development => Topic started by: a1ex on September 25, 2013, 06:45:08 PM

Title: Config presets
Post by: a1ex on September 25, 2013, 06:45:08 PM
I've tried to implement the much-requested config presets, and almost got them working (https://bitbucket.org/hudson/magic-lantern/commits/c937de8a0497):

Backend:

* A preset is a subfolder under ML/SETTINGS
* It contains ML settings, module settings, pretty much any kind of settings except Canon ones.
* To choose a preset, you just change the settings directory. As long as code requiring some files with settings does not hardcode ML/SETTINGS, but uses get_config_dir() instead, it should work out of the box.
* Special preset names: <keyname>.KEY and <modename>.MOD (see below)

Frontend:

* You can choose a preset in 3 ways:
    - From menu (select it by name)
    - Linked to a key that you press and hold at startup (currently MENU, PLAY and INFO/DISP)
    - Linked to the shooting mode (from the mode dial) selected at startup (so you have a preset for M, another for Av and so on).
* You can create up to 13 named presets by creating subfolders under ML/SETTINGS/ (just "new folder" is enough; copying an existing folder is also fine)
* The preset name is always displayed in the menu, in a corner.
* If it sounds complicated, you have built-in help in the camera ;)

Caveats:

* Changing the preset requires reboot (to keep things simple and robust).
* You may want to move ML/MODULES/*.CFG and *.EN to ML/SETTINGS (or just delete them and start fresh).
* Right now there's no way to create new named presets from menu (you need to do this on the PC).
* 5D2/50D do not have a dedicated switch for movie mode (they always start in photo mode). This means you can't have a preset for movie and another one for photo on these cameras (even if the menu may suggest you can). It might work if you press LiveView fast enough at startup (didn't try this).
Title: Re: Config presets
Post by: Jakobmen on September 25, 2013, 07:05:12 PM
nice!
Title: Re: Config presets
Post by: Marsu42 on September 25, 2013, 07:05:33 PM
Quote from: a1ex on September 25, 2013, 06:45:08 PM
Changing the preset requires reboot (to keep things simple and robust).

Hmmmyes, that was to be expected after what you've already written before, and it certainly makes the mode-dependent presets less practical - but the implementation sounds very nice and thought through, I'm keen to give it a try (well, as soon as 1% pulls it into his fork so it's on my 6D :-p)!

If you didn't already do it when selecting a different config - maybe implementing a soft reboot to switch configs would be a good idea so users don't need to power off the camera, wait some (otherwise it might not have reboot), and then switch it back on again?
Title: Re: Config presets
Post by: engardeknave on September 26, 2013, 10:07:29 AM
This is awesome.
Title: Re: Config presets
Post by: RenatoPhoto on September 26, 2013, 01:32:27 PM
Hard to keep up with you guys!  ;D
The Your development speed outpaces the my learning speed! :o
Congratulations!
Title: Re: Config presets
Post by: arrinkiiii on September 26, 2013, 02:01:30 PM
...always the same, and the same... only good news  :D

Thanks for this, very appreciated.
Title: Re: Config presets
Post by: Doyle4 on September 26, 2013, 03:05:42 PM
Nice.

i now have 4 sets, Photo - RAW Video - H264 video - TimeLapse
Title: Re: Config presets
Post by: Walter Schulz on October 12, 2013, 12:33:17 PM
Reported a possible bug in http://www.magiclantern.fm/forum/index.php?topic=7473.msg82413#msg82413

Ciao
Walter
Title: Re: Config presets
Post by: Walter Schulz on October 16, 2013, 12:14:40 PM
Bug?
650D, nightly build 16.0ct.: INFO button key doesn't work if
Prefs -> Config files -> Config preset - Startup key
is activated. MENU and PLAY buttons are working.

Ciao
Walter
Title: Re: Config presets
Post by: a1ex on October 16, 2013, 12:22:13 PM
Most likely the INFO key event is not sent if you hold the key during startup. Try pressing it a few times after starting ML, before the config gets loaded; maybe it will get caught this way.

Also check if INFO works as expected in menu (it should attempt to display some help).
Title: Re: Config presets
Post by: Walter Schulz on October 16, 2013, 12:46:03 PM
Works!
Press INFO once after Canon's screen appears while sensor cleaning is running.
Thanks!

EDIT: Help works as intended after pressing INFO in ML menu. INFO in liveview: No problems, too.

Ciao
Walter

Title: Re: Config presets
Post by: a1ex on October 18, 2013, 09:14:37 AM
What about popping up a menu at startup, where you can select a config preset by name?

Also it may be nice to include some presets in the nightly zip, as suggested here: http://www.magiclantern.fm/forum/index.php?topic=5586.msg82358#msg82358

and the presets could include stripped-down Junkie menus, so this menu would be no longer overwhelming for newcomers:

http://www.magiclantern.fm/forum/index.php?topic=8741.msg83212#msg83212

for example, my Junkie menu looks roughly like this:

(http://a1ex.magiclantern.fm/bleeding-edge/junkie3.png)

Thoughts?
Title: Re: Config presets
Post by: Marsu42 on October 18, 2013, 11:01:03 AM
Quote from: a1ex on October 18, 2013, 09:14:37 AM
What about popping up a menu at startup, where you can select a config preset by name?

My one issue with the current preset system is not loading presets, but *saving* them - I'd like to have the choice to save the current preset to a specific mode/button. If I could give it a name and there's a nice loading choice menu all the better, but since a reboot is required anyway the mode/button solution is also quick if you can remember what config is where.
Title: Re: Config presets
Post by: a1ex on October 18, 2013, 11:15:16 AM
You mean, start changing settings from preset A and save it as B?
Title: Re: Config presets
Post by: RenatoPhoto on October 18, 2013, 02:24:34 PM
Quote from: a1ex on October 18, 2013, 09:14:37 AM
What about popping up a menu at startup, where you can select a config preset by name?
The concept seems very good but I would added as optional by pressing a button since I would not want this screen to come up every time.

Quote from: a1ex on October 18, 2013, 09:14:37 AM
Also it may be nice to include some presets in the nightly zip, as suggested here: http://www.magiclantern.fm/forum/index.php?topic=5586.msg82358#msg82358
Absolutely!  I find presets very useful to setup ML for specific functions i.e. Timelapse.  This will allow beginners to quickly get results without the lengthy trouble shooting questions of How to?

Quote from: a1ex on October 18, 2013, 09:14:37 AM
and the presets could include stripped-down Junkie menus, so this menu would be no longer overwhelming for newcomers:
Anything to provide ease of use and quick reliable results via presets is a huge plus. +
Title: Re: Config presets
Post by: engardeknave on October 29, 2013, 08:12:20 AM
QuoteWhat about popping up a menu at startup, where you can select a config preset by name?

I suggested this a while ago and I would definitely be for it.
Title: Re: Config presets
Post by: jose_ugs on November 26, 2013, 03:31:33 AM
Where magic happens!!! So useful!
Title: Re: Config presets
Post by: morsafr on January 06, 2014, 06:49:57 PM
Hi everybody,

Great perspective indeed!

Is it already available in the nightly build?

Thanks!
Title: Re: Config presets
Post by: Walter Schulz on January 06, 2014, 07:20:03 PM
If you're talking about config presets in common:
It is for months.
You may even use it.

If you're talking about config preset selectable at startup as a menu: Nope.
Title: Re: Config presets
Post by: morsafr on January 07, 2014, 05:22:23 PM
Thanks for the feedback.

I'm not sure which one is the one for me.

Basically what I'd like to do is alternate between two ML configs: one for RAW (with RAW Recording ON and FPS Override ON) and one for H264 (with RAW recording and FPS Override OFF).

Can I do it with Config Presets in common?
Title: Re: Config presets
Post by: Walter Schulz on January 07, 2014, 05:31:29 PM
Yes, because they were made for such things.
Title: Re: Config presets
Post by: morsafr on January 07, 2014, 05:52:27 PM
I cannot find information on how they work.

Is there any guide for it?

Thanks again.
Title: Re: Config presets
Post by: Walter Schulz on January 07, 2014, 06:08:12 PM
First post.
Title: Re: Config presets
Post by: timbytheriver on January 08, 2014, 11:57:43 AM
Maybe a dumb question, but are these 'config presets' options also in the a.d./pravdomil builds for Mk2?

Thanks.

Title: Re: Config presets
Post by: eos on February 17, 2014, 02:18:22 PM
Quote from: a1ex on October 18, 2013, 11:15:16 AM
You mean, start changing settings from preset A and save it as B?

+1
Title: Re: Config presets
Post by: barepixels on July 27, 2014, 11:08:51 PM
am just wondering what is the status of this module.  is it still functional with current builds of ML?
Title: Re: Config presets
Post by: jerrykil on July 28, 2014, 12:06:20 AM
It's built in and still works. however, the implementation is rather coarse. On my eosM, info button at bootup prevents ML from loading at all, and there are no mode dials. I set a preset for Menu.KEY and it worked great...
Title: Re: Config presets
Post by: barepixels on July 28, 2014, 02:23:04 AM
found it.  I never knew it exist.  thnx
Title: Re: Config presets
Post by: jose_ugs on August 16, 2014, 12:00:47 AM
Using this for a while and thinking all the time, like Marsu suggested a year ago: maybe implementing a soft reboot to switch configs would be a good idea... and a +1 on this one!
Title: Re: Config presets
Post by: Walter Schulz on May 15, 2015, 01:48:08 PM
@a1ex: Looks like presets are not ordered alphanumerical but in order of time of creation.
(http://picload.org/image/iaidpol/vram8.jpg)
Is it possible to change behauviour?
Title: Re: Config presets
Post by: Lars Steenhoff on October 11, 2017, 01:52:29 AM
I just created an issue.

I hope it's not user error, but I don't find a way to keep the modules loading

https://bitbucket.org/hudson/magic-lantern/issues/2789/config-presets-dont-keep-module-mlv_lite

Working with the crop_rec4k branch:
Config presets https://www.magiclantern.fm/forum/index.php?topic=8499.0
Canon 5d Mk3 1.2.3 with Latest Build Branch: crop_rec_4k (2017-10-10 21:51)
crop_rec and mlv_lite don't load when pressing the MENU or INFO button to load a config.
When pressing MENU to load the config preset and after loading the crop_rec it does not load again after reboot.
Somehow does not keep the settings for loading those modules.

Title: Re: Config presets
Post by: Lars Steenhoff on October 12, 2017, 01:57:11 AM
The issue is resolved
Title: Re: Config presets
Post by: p5ylance on May 19, 2020, 10:06:18 AM
I just tried this with my camera, I moved all my ML/SETTINGS stuff and dropped it into a new folder "Video_RAW" and it showed up on my config presets easy. Can't wait to make some other presets, and this will make setting up my cards so much quicker! It's been a little bit exhausting to comb through the menu each time I set up a card, and I'm really nitpicky about making sure my cards are consistent across the board. This will help so much.

EDIT: I notice when I try to choose my preset and then reboot, the mlv_rec and mlv_snd modules are turned off. when I try to turn on the mlv_rec and mlv_snd modules and reboot, they do not turn on still. If the Preset is supposed to be a new path to get the files, do I just move all the files created into a preset folder? (right now in my folder i have only my preset folder in ML/SETTINGS.

My preset folder contains:

bench.en
magic.cfg
mlv_play.en
mlv_rec.cfg
mlv_rec.en
mlv_snd.cfg
mlv_snd.en