Magic Lantern Forum

Developing Magic Lantern => Scripting Corner => Topic started by: garry23 on December 05, 2017, 04:15:51 PM

Title: New version of Toggler
Post by: garry23 on December 05, 2017, 04:15:51 PM
Just in case anyone else has found my Toggler script useful, here is an update that works with the latest Lua-fix nightly (Latest Build (2017-12-03 22:09)).

Although I wrote the Toggler for the EOSM, which is lean on buttons, the Toggler should work on other cameras using the Build above.

You can download Toggler from here: https://gist.github.com/pigeonhill/156ea0e55cd0a029bc447f8bf5593224

Why use Toggler?

If you find yourself switching ML states a lot, then Toggler could help.

The script you download is configured to use the PLAY, INFO and MENU buttons:
[MENU] = normal use of [MENU] if not in imode (interactive mode)
[INFO] = normal use of [INFO] in not in imode
[PLAY][PLAY] = normal use of [PLAY]
[PLAY][MENU] = enter Toggler interactive mode
In imode [PLAY] and [INFO] will toggle back and forwards through your ML condition states giving you an on-screen message
In imode [MENU] will set that condition and leave interactive mode.
In imode pressing any other key, eg [SET] (not [MENU], [INFO] or [PLAY]) will leave interactive mode

You can change the script to use other button combinations, ie that work better on your camera (the 'default' ones work well on the EOSM).

The script, as I've written it for my use, allows me to switch my Focus Bar on and off, switch the FB stacking mode on and off, open the ML menu, switch on ETTR or Auto-Bracketing and the list goes on.

As usual I welcome feedback, especially to make the Toggler idea better and make my coding better  ;)




Title: Re: New version of Toggler
Post by: garry23 on December 06, 2017, 06:16:04 PM
In the spirit of helping others, like me, learning to script; here is a version B of my Toggler script: https://gist.github.com/pigeonhill/508a3722b9dc319b64ca4c5972b9e50b

This ones toggles ML menus on and off and provides feedback to the state of the menu, ie red = off and green = on.