Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - Jip-Hop

Pages: 1 [2] 3 4
26
Scripting Q&A / Re: Script state at camera switch off
« on: July 10, 2019, 10:15:44 PM »
config.create_from_menu works great for me.
But how can I get and set values in the config without using a menu?
My autorun script needs to store state between reboots, and using a hidden menu (in addition to actual menu items) just to store state is not great  :P

I tried it like this, for example:

Code: [Select]
config.create_from_menu(preset_menu_ratio);

if cfg.data ~= nil then
    cfg = config:load()
    for key,value in ipairs(cfg) do
        display.notify_box(tostring(key) .. " " .. tostring(value));
        sleep(1);
    end
end

But cfg is not defined.
I tried using "config" instead, but no dice.

27
Looking forward to it!
I'm working on a (hopefully useful) script myself.

By the way, when half pressing the shutter button in MCM rewire.
The live view becomes slow.

It overrides the real time live view and replaces it with worse live view.

I find it annoying when using autofocus because then you need to keep the halfshutter pressed and the laggy live view kicks in.
Is it possible to disable this live view override on half shutter press?

Maybe only for modes that already have proper live view?

28
General Development / Re: How to run Magic Lantern into QEMU?!...
« on: July 10, 2019, 05:28:16 PM »
Thanks, I'll try it next time. For now I think I'll stick to testing my Lua scripts on my EOS M. That's probably the quickest.

29
So what does centered mean then?
And bot both are 1:1 crops right?

With ratios set to off the 2.5K 2520x1418 mode indeed has greater hight.

2.5K 1:1 centered records max 2520x1080.
2.5K 2520x1418 records in 2520x1416.

In 16:9 aspect ratio 2.5K 1:1 centered records max 1920x1080.
2.5K 2520x1418 records in 2192x1234.
So not only greater hight, but also greater width.

In 2.39:1 ratio both record in 2520x1054.
In 2.35:1 ratio both record in 2520x1072.

So there's no difference at all between these modes in these ratios?

30
The only difference between "2.5K 1:1 centered" and "2.5K 2520x1418" is the centering right? No other differences that affect quality, like possible resolutions and bit-depths? If no other differences, I'm wondering why anyone would want to record off-center...

31
General Development / Re: How to run Magic Lantern into QEMU?!...
« on: July 09, 2019, 08:54:30 PM »
Aah yes that was it!

If I try to run Canon firmware, following this guide, I still get a mostly grey screen. It also has a grey circle on the bottom right now and some black lines on the top left.

Code: [Select]
./run_canon_fw.sh EOSM,firmware="boot=0" -s -S & arm-none-eabi-gdb -x EOSM/patches.gdb -ex quit
Here's the log.

Trying to run ML with boot=1 I get a message to remove the battery.

32
Scripting API suggestions / Re: [WIP - camera.gui] GUI state triaging
« on: July 09, 2019, 08:01:55 PM »
Thanks again for the advice!

It's the photo mode interface but my EOS M is set to video mode.

I think I found the culprit.

Code: [Select]
-- INFO key menu
-- Use INFO button to toggle RAW video preferences

event.keypress = function(k)
    if lv.enabled == false and camera.gui.idle == true then
        display.notify_box("INFO screen");
    else
        display.notify_box("Other screen");
    end
    return true;
end

It still wouldn't work with this simple example.
But it would briefly flash INFO screen and then Other screen.
I had to disable "Feature guide" in the Canon menu, because it would pop-up an explanation of the selected setting at the INFO screen.
So it wouldn't pass the test in the script.
Now with that setting disabled I think I can reliably test for that screen.

I'm trying to open a custom ML menu in between each time the screen switches when pressing the INFO button. But it's giving me all sorts of trouble.

Is there instead a direct way to activate from Lua this INFO screen, the Canon Live View screen and the LV screen with ML overlays?

If I set camera.gui.mode to 21 then I get into the INFO screen. But didn't find modes for the other LV screens, and also no way to get back to the LV with ML overlays because they're all identified with camera.gui.mode == 0.

33
Scripting API suggestions / Re: [WIP - camera.gui] GUI state triaging
« on: July 09, 2019, 07:05:42 PM »
garry23 were you eventually able to distinguish the Canon INFO screen from the Canon MENU?

I want to do some stuff when not in the PLAY screen and not in the Canon MENU. But gui.menu == true also in the INFO screen and lv.enabled == false is also the case when on the INFO screen...

I want my function to also be active on the INFO screen, but not in MENU or PLAY.

34
Scripting Q&A / Re: Slow to close ML menu
« on: July 09, 2019, 06:46:23 PM »
Actually it seems I'm unable to open the menu reliably from this simple snippet as well:

Code: [Select]
-- INFO key menu

event.keypress = function(k)
    -- Check if INFO key is pressed
    if k == KEY.INFO then
        menu.open();
        return false;
    end
end

It will often end up in this slider menu with Darker and Brighter on both ends. Tried with the PLAY and SET keys too but with same results.

What am I missing?

35
General Development / Re: How to run Magic Lantern into QEMU?!...
« on: July 09, 2019, 06:11:05 PM »
Thanks a1ex! Used portable rom dumper, got the SFDATA.BIN file now.
What should I do next to get GDB working?

Code: [Select]
./run_canon_fw.sh EOSM,firmware="boot=0" -s -S & arm-none-eabi-gdb -x EOSM/patches.gdb -ex quit
[1] 1311
-bash: arm-none-eabi-gdb: command not found

QEMU starts but all I see is a grey screen.
This is the terminal output:

Code: [Select]
./run_canon_fw.sh EOSM,firmware=boot=0 -s -S &

DebugMsg=0x40D4 (from GDB script)
Lockdown read 4
Lockdown read 4
Lockdown read 5
Lockdown read 5
Lockdown read 0
Lockdown read 0
Lockdown read 1
Lockdown read 1
Lockdown read 2
Lockdown read 2
Lockdown read 3
Lockdown read 3
00000000 - 00000FFF: eos.tcm_code
40000000 - 40000FFF: eos.tcm_data
00001000 - 0FFFFFFF: eos.ram
40001000 - 4FFFFFFF: eos.ram_uncached
F8000000 - F8FFFFFF: eos.rom1
F9000000 - F9FFFFFF: eos.rom1_mirror
FA000000 - FAFFFFFF: eos.rom1_mirror
FB000000 - FBFFFFFF: eos.rom1_mirror
FC000000 - FCFFFFFF: eos.rom1_mirror
FD000000 - FDFFFFFF: eos.rom1_mirror
FE000000 - FEFFFFFF: eos.rom1_mirror
FF000000 - FFFFFFFF: eos.rom1_mirror
C0000000 - DFFFFFFF: eos.mmio
[EOS] loading './EOSM/ROM1.BIN' to 0xF8000000-0xF8FFFFFF
[EOS] loading './EOSM/SFDATA.BIN' as serial flash, size=0x800000
[MPU] warning: non-empty spell #30 (PROP 80030019) has duplicate(s): #34
[MPU] warning: non-empty spell #40 (PROP_VIDEO_MODE) has duplicate(s): #41

[MPU] Available keys:
- Arrow keys   : Navigation
- [ and ]      : Main dial (top scrollwheel)
- SPACE        : SET
- DELETE       : guess (press only)
- M            : MENU (press only)
- P            : PLAY (press only)
- I            : INFO/DISP (press only)
- Q            : guess
- L            : LiveView (press only)
- Z/X          : Zoom in/out
- Shift        : Half-shutter
- 0/9          : Mode dial (press only)
- V            : Movie mode (press only)
- B            : Open battery door
- C            : Open card door
- F10          : Power down switch
- F1           : show this help

Setting BOOTDISK flag to 0

Seems like GDB didn't install at all:
Code: [Select]
-bash: gdb: command not found

36
Scripting Q&A / Slow to close ML menu
« on: July 09, 2019, 01:31:12 PM »
When I close the ML menu from a script, it flashes first, then closes but briefly shows a slider with "Darker" and "Brighter" on each end (I guess it's the exposure compensation slider) and then goes to Live View. It's quite slow, almost 2 seconds on my EOS M with Danne's crop_rec_4k_mlv_snd_isogain_1x3_presets_2019Jul01.EOSM202.

But when I'm in the ML menu, pressing the canon MENU button goes back to Live View instantly! How can I instantly quit the ML menu and go to Live View from a LUA script?

Code: [Select]
-- INFO key menu

event.keypress = function(k)
    -- Check if INFO key is pressed
    if k == KEY.INFO then
        menu.close();
        return false;
    end
end

37
General Development / Re: How to run Magic Lantern into QEMU?!...
« on: July 09, 2019, 11:30:58 AM »
Installed Mojave, downloaded the zip archive of the QEMU branch (from here) with Safari (i.e. without first installing hg & co), ran the install script (cd contrib/qemu; ./install.sh) and... worked out of the box! It installed brew and other dependencies, compiled gdb 8.2.1 from source et voilĂ ! QEMU and ML development environment installed and ready to use!

I'm following these instructions to get QEMU working with EOSM, but I'm stuck.
If I run ./run_canon_fw.sh EOSM,firmware=boot=1 I get this message:
Could not open ./EOSM/SFDATA.BIN

So I need to get my hands on a compiled version of the sf_dump module.
But when I run make in this folder:
/magic-lantern/modules/sf_dump

I get this output:

abort: no repository found in '/magic-lantern/modules/sf_dump' (.hg not found)!

(<type 'exceptions.SystemExit'>, SystemExit(1,), <traceback object at 0x10dca43f8>)
[ CC       ]   sf_dump.o
In file included from sf_dump.c:3:0:
../../src/module.h:344:10: fatal error: module_strings.h: No such file or directory
 #include "module_strings.h"
          ^~~~~~~~~~~~~~~~~~
compilation terminated.
make: *** [sf_dump.o] Error 1

Where can I find a compiled version of this module?

38
Cool stuff Danne! Can't try right now so I'll have to ask. Temporary x3crop in anamorphic as focus helper works only when not recording right?

39
Scripting Corner / Re: Simulated Q Button for EOSM
« on: July 05, 2019, 09:30:11 PM »
Interesting, thanks a1ex!

40
General Chat / Re: The A.I Up-Scaling for 1x3 and 5x3 Binning Mods
« on: July 05, 2019, 08:36:14 PM »
Here is your big moire frame up-scaled x4 using davinci super scale .

From the tests so far I think the results in the OP look best. theBilalFakhouri could you repeat the test of your anamorphic frame with DaVinci Super Scale? Would love to see how it compares to Topaz Gigapixel A.I.

41
General Chat / Re: The A.I Up-Scaling for 1x3 and 5x3 Binning Mods
« on: July 05, 2019, 08:16:11 PM »
I also just have the free version of Resolve. Don't know if it has Super Scale in free version actually, but if it doesn't it will at least show the results watermarked. Would love to do a test but I'm away from the camera and computer this weekend. But I will be lurking in the forum.

42
Scripting Corner / Re: Simulated Q Button for EOSM
« on: July 05, 2019, 08:12:24 PM »
Clever!
Found this thread https://www.magiclantern.fm/forum/index.php?topic=15681.new#new

I understand now where my confusion comes from. I kept seeing the Q button (which is also the SET button) in the ML interface but now I understand it's remapped to the play button while in ML menu.

43
General Chat / Re: The A.I Up-Scaling for 1x3 and 5x3 Binning Mods
« on: July 05, 2019, 07:48:28 PM »
I'd be curious to see how these solutions compare to DaVinci Resolve Super Scale: https://www.premiumbeat.com/blog/resolve-15-super-scale-feature/

Never use it because it's slow (so that's at least one thing they have in common). But might be nice for the anamorphic de-squeeze and would skip exporting to an image sequence first.

44
General Chat / Re: The A.I Up-Scaling for 1x3 and 5x3 Binning Mods
« on: July 05, 2019, 03:19:04 PM »
Cool stuff, looks good! Maybe this tool could be used instead?
https://github.com/IBM/MAX-Image-Resolution-Enhancer
Those results look pretty good to me too and since it's open source we can modify it ^^

45
Scripting Q&A / Help with MF + one shot AF for EOS M
« on: July 05, 2019, 01:40:54 PM »
I'm trying to make a script which will allow me to manually focus all the time, or one shot autofocus by half pressing the shutter button.
It's for my EOS M with native EF-M lenses.

I thought I'd just set the camera to MF mode in Canon menu, and trigger a lens.autofocus() from LUA and it would autofocus.
But clearly calling lens.autofocus() in MF mode doesn't work.

So I'm stuck and see two ways out.
I could switch temporarily from MF to AF mode when half pressing the shutter, call lens.autofocus() and switch back to MF.
But in the API I don't see any way to switch these modes.
I did read there's a dangerous option to set Canon properties, but didn't find the API to do so (and frankly I don't know if I dare to risk soft bricking the camera xD).

Another option would be to detect turning the focus ring when staying AF mode.
And then implement manual focusing in LUA, but seems like more work and I'd rather rely on the Canon MF implementation.

I thought this was going to be an easy fix xD

By the way, there's the AF+MF mode.
But MF is only allowed after an autofocus operation while the half shutter is still pressed.
So that's not true MF if you ask me.
Perhaps I could trick the camera in staying in the post-AF state, which would allow MF, and start a new AF operation on half shutter press?

Code: [Select]
-- AF KEY in MF mode 

-- Half press shutter button to autofocus if in manual focus mode

function try_af()
    local focus_lock = lens.autofocus();
    if focus_lock == true then
        display.notify_box("LOCKED ON");
    else
        display.notify_box("NO LOCK");
    end
end

event.keypress = function(key)
    if key == KEY.HALFSHUTTER then

        -- TODO: check if there's no chipped lens
        -- In that case toggle magic zoom for manual focus
        -- Maybe use CHIPPED_LENS constant?

        -- Handle key as usual in AF mode
        if lens.af == true then
            return true;
        end

        task.create(try_af);

        return false;
    end
end

46
Scripting Corner / Re: Simulated Q Button for EOSM
« on: July 05, 2019, 01:28:38 PM »
I was wondering about the Q button and if there's still the need for this script in Dannes builds for the EOS M.
But it's a bit tricky searching the thread for Q button when "Each word must be at least two characters long".
With the play button I can enter and exit submenu's in ML menu.

47
I also invested in an M50 xD

48
Thanks for the tips garry23! Will keep it in mind when I continue to work on my script.

Having used the EOS M for a bit now, I'm super excited about it :)
But I also got a couple of things I wish it had.

I'd like to be able to switch easily between various RAW recording modes.
Have some modes preconfigured so I can easily toggle between e.g. mv1080 MCM rewire 14bit with 3x crop and 4k anamorphic 10bit.
Or toggle between 2.5k and mv1080 MCM rewire 3x crop.
This could also help with focus before recording since the preview in 2.5k and anamorphic is not great.
And then just toggle and hit record.
I hope I can make this possible with a LUA script and will look into it next week.

Other things I wish it had are:
- Working auto white balance in RAW recording. Currently it doesn't log the actual measured white balance (kelvin, tint/shift). I don't know anything about how WB works, but I feel like this should be possible. To me this thread from 2013 seems relevant: https://www.magiclantern.fm/forum/index.php?topic=6779.0.
- A button which auto sets exposure (ettr) in shutter speed priority mode. So leave the shutter speed alone, but adjust aperture first and if necessary ISO.
- Better live view for 2.5k and anamorphic modes, but this is probably only possible in my dreams :P
- Full time manual focus, with the possibility to autofocus by pressing a button. The default Canon behaviour is either no autofocus, or very limited manual focus (MF only after AF while keeping half shutter pressed). I guess this could be easily fixed with LUA too, just leave focus set to manual in Canon menu and map half shutter press to autofocus with LUA.

Danne do you have any plans for the camera you wish to share?
What do others feel like could be added/removed/improved?

Magic Lantern is really awesome stuff :) thanks devs and contributors!

49
Yes I think it crashed right after the file dialog. It's about to overwrite an earlier export of the same file. If that matters.

50
Great. On my side I removed the delay when x3crop toggle is enabled in Crop mode sub menu. Response right away. Better...
https://bitbucket.org/Dannephoto/magic-lantern/downloads/crop_rec_4k_mlv_snd_isogain_1x3_presets_2019Jul04.EOSM202.zip

Cool!

@Jip-Hop

The long press approach is in my hand held helper script.


Do you mean this one https://gist.github.com/pigeonhill/3c351242740c84f0581fa57ac27e0656?

There you distinguish between long and short press of half shutter button.
But INFO button only has one state right? Not a separate one for pressed and unpressed.

So can it also be done with INFO button?
Say, short press INFO for the enhanced functionality and longpress for the normal functionality?
Seems unlikely at first thought.

The SET button does have an unpressed state, so maybe that one is better. Also these keys have unpressed state: UNPRESS_UDLR and UNPRESS_FLASH_MOVIE. But don't know if EOS M has them xD

Pages: 1 [2] 3 4