EOS M100 porting - page 4 - DryOS Development - CHDK Forum

EOS M100 porting

  • 199 Replies
  • 59841 Views
*

Offline srsa_4c

  • ******
  • 4451
Re: EOS M100 porting
« Reply #30 on: 06 / October / 2020, 17:04:51 »
Advertisements
1) The M100 changes its black level from 512 to 2048 at around ISO320. We know that from the G1x and S110
Thanks, I'll switch the port to calculate black level instead of assuming it being fixed.

Quote
2) With the M100 there is a difference between ISO and sv96 value
The M100 has
ISO100 (sv) => sv96 = 480
All my other cameras have
ISO100 (sv) => sv96= 411
Code: [Select]
sv=sv96_to_iso(sv96_real_to_market(get_prop(props.SV)))
Both PROPCASE_SV_MARKET and PROPCASE_SV appear to have the same value, indeed 480 when setting ISO 100 with Canon controls.

@Caefix
I'd appreciate if you could tell how you crashed the camera. If it's a script, make that script as short as possible. And please don't waste my time with this sort of thing.

I recommend running a build from the latest source as I moved the CHDK core to a different memory area.

*

Offline c_joerg

  • *****
  • 1248
Re: EOS M100 porting
« Reply #31 on: 07 / October / 2020, 02:31:02 »
Both PROPCASE_SV_MARKET and PROPCASE_SV appear to have the same value, indeed 480 when setting ISO 100 with Canon controls.

Right. It is the same with the M3. We already had this discussion here at the M3
https://chdk.setepontos.com/index.php?topic=12542.270
M100 100a, M3 121a, G9x II (1.00c), 2*G1x (101a,100e), S110 (103a), SX50 (100c), SX230 (101a), S45,
Flickr https://www.flickr.com/photos/136329431@N06/albums
YouTube https://www.youtube.com/channel/UCrTH0tHy9OYTVDzWIvXEMlw/videos?shelf_id=0&view=0&sort=dd

*

Offline Caefix

  • *****
  • 945
  • Sorry, busy deleting test shots...
Re: EOS M100 porting
« Reply #32 on: 07 / October / 2020, 11:43:32 »
 ::) Without zoomkeys we have trouble to adjust some script settings.
So I modified my
Code: [Select]
// gui_menu.c
        case KEY_UP:
        case JOGDIAL_LEFT: // M100 // 558 ~> Line 703
        case KEY_ZOOM_OUT:

        case JOGDIAL_RIGHT: // M100 // 562 ~> Line 708
        case KEY_ZOOM_IN:
It affects all wheel cams, but it simplyfies cursor placement on cams with dual zoomlever, too.

// I dropped the 93kb zip content into my trunk, & it works really a lot... 8)

Here I listen to focus beeps in green frame, but the output is always 0 false.
How to get get_focus()?  :(
Code: [Select]
--[[
@title FoTest.lua
--]]
repeat
press("shoot_half")
print("get_focus() ",get_focus(),get_shooting())
sleep (200)
print(" get_focus()",get_focus(),get_shooting())
release("shoot_half")
until get_wheel()~=0
« Last Edit: 07 / October / 2020, 13:50:41 by Caefix »
All lifetime is a loan from eternity.

*

Offline srsa_4c

  • ******
  • 4451
Re: EOS M100 porting
« Reply #33 on: 07 / October / 2020, 16:27:35 »
::) Without zoomkeys we have trouble to adjust some script settings.
You can use half-shoot as replacement for moving the selected digit.

Quote
How to get get_focus()?  :(
It's not implemented. It would rely on a firmware function named
GetFocusLensSubjectDistanceFromLens
but that just returns zero. Same as on M3 and M10.


*

Offline Caefix

  • *****
  • 945
  • Sorry, busy deleting test shots...
Re: EOS M100 porting
« Reply #34 on: 10 / October / 2020, 13:40:01 »
  ;) ...some other observations:
get_zoom()=0, dof.near=dof.hyp_dist, dof.far=-1, dof.dof=-1, dof.coc=19
Strange x=get_focus_state() values (bitmap?) in Auto (collected in Log 'growing' with script)
Cam ~'never' starts with first button press...
Code: [Select]
--[[
@title FoTestr.lua
@param    M Mode
@default  M 2
@range    M 0 79
@param    s sleep
@default  s 400
@range    s 0 1000
--]]

capmode=require("capmode")
props=require("propcase")
print_screen(-125)
set_console_layout(0,0,45,6)
lineal=lineal or ":...,....1....,....2....,....3....,....4.."
print(lineal)

function m_info(a,b,X)
dof=get_dofinfo()
print(a,dof.focal_length,dof.eff_focal_length,capmode.get_canon(),capmode.get(),
get_prop(65),-get_focus(),get_shooting() or b,get_focus_mode(),X,dof.focus_valid,get_focus_ok())
print(get_zoom(),dof.min_stack_dist,dof.near,dof.focus,dof.far,dof.hyp_valid,dof.hyp_dist,dof.dof,dof.coc)
print(get_mode(),-s,get_prop(props.AF_LOCK),get_prop(props.AF_FRAME),get_prop(props.METERING_MODE),get_prop(props.DRIVE_MODE),'--')
end

if is_capture_mode_valid(M) then set_capture_mode(M); play_sound(1) else M=2 end

repeat
press("shoot_half")
x=get_focus_state()
if x~=0 then m_info(" ",7777,x) end

sleep(s)
x=get_focus_state()
if x~=0 then m_info("-",8888,x) end
release("shoot_half")

sleep(2*s)
until get_wheel()~=0

set_console_layout(0,0,25,5)

« Last Edit: 10 / October / 2020, 13:44:12 by Caefix »
All lifetime is a loan from eternity.

*

Offline c_joerg

  • *****
  • 1248
Re: EOS M100 porting
« Reply #35 on: 10 / October / 2020, 14:15:04 »
  ;) ...some other observations:
get_zoom()=0, dof.near=dof.hyp_dist, dof.far=-1, dof.dof=-1, dof.coc=19 Strange )
Did you read that and understand where the values ​​come from?
https://chdk.setepontos.com/index.php?topic=13756.0

Cam ~'never' starts with first button press...
One Power on?

if I turn on the camera too quickly after inserting the SD, my M100 sometimes doesn't turn on either. I have to wait a bit when switching on (until the LED is off).
M100 100a, M3 121a, G9x II (1.00c), 2*G1x (101a,100e), S110 (103a), SX50 (100c), SX230 (101a), S45,
Flickr https://www.flickr.com/photos/136329431@N06/albums
YouTube https://www.youtube.com/channel/UCrTH0tHy9OYTVDzWIvXEMlw/videos?shelf_id=0&view=0&sort=dd

*

Offline Caefix

  • *****
  • 945
  • Sorry, busy deleting test shots...
Re: EOS M100 porting
« Reply #36 on: 10 / October / 2020, 15:28:07 »
One Power on?
I trained that ... & changed the card.
Do we need Boot to <play> after (short) ON on M100?
& Thx for nice links...  8)
All lifetime is a loan from eternity.

*

Offline srsa_4c

  • ******
  • 4451
Re: EOS M100 porting
« Reply #37 on: 10 / October / 2020, 17:10:43 »
if I turn on the camera too quickly after inserting the SD, my M100 sometimes doesn't turn on either. I have to wait a bit when switching on (until the LED is off).
I see that, but it's not too bad (at least here). Waiting for a ~second is enough. Do any of you need to wait longer before the cam is willing to start?
There's a worse issue with startup. If I remove the battery and leave it out for some time, I have to wait a long time (15 seconds are enough*) before the camera can be successfully started. If I attempt to start sooner, I get the LED blink (sign of diskboot executing) and cam stays off. Unsuccessful attempts elongate the "dead" period.
I suspect these are connected to some startup check that my current code isn't handling correctly.

*edit:
corrected amount of "dead" time
« Last Edit: 10 / October / 2020, 17:22:04 by srsa_4c »


*

Offline c_joerg

  • *****
  • 1248
Re: EOS M100 porting
« Reply #38 on: 10 / October / 2020, 18:00:13 »
I see that, but it's not too bad (at least here). Waiting for a ~second is enough. Do any of you need to wait longer before the cam is willing to start?
When I close the SD card door, the green LED goes on briefly twice. That takes maybe 2s. If I switch on after that, then everything is fine.
If I switch the camera on too early, the green LED stays on for about 10s and prevents it from being switched on again.
There's a worse issue with startup. If I remove the battery and leave it out for some time, I have to wait a long time (15 seconds are enough*) before the camera can be successfully started. If I attempt to start sooner, I get the LED blink (sign of diskboot executing) and cam stays off. Unsuccessful attempts elongate the "dead" period.
I have not yet come into this situation.

I also had no other undefined crashes. I’m really happy right now

M100 100a, M3 121a, G9x II (1.00c), 2*G1x (101a,100e), S110 (103a), SX50 (100c), SX230 (101a), S45,
Flickr https://www.flickr.com/photos/136329431@N06/albums
YouTube https://www.youtube.com/channel/UCrTH0tHy9OYTVDzWIvXEMlw/videos?shelf_id=0&view=0&sort=dd

*

Offline srsa_4c

  • ******
  • 4451
Re: EOS M100 porting
« Reply #39 on: 10 / October / 2020, 18:20:30 »
When I close the SD card door, the green LED goes on briefly twice. That takes maybe 2s.
I've never seen it blinking twice. Maybe it depends on card...?
Quote
If I switch the camera on too early, the green LED stays on for about 10s and prevents it from being switched on again.
That's probably a lockup or crash (never seen that either). Do you get new romlog with matching timestamp after that (I suspect not)?

edit:
It looks like memory is getting corrupted, but only when booting with the above mentioned conditions (closing card door or battery out->in->closing door). Need to investigate...

edit2:
I also occurred to me that the CPU cache routines used in CHDK may not be adequate in a dual-core setup. We're probably only clearing the cache on one core...
« Last Edit: 11 / October / 2020, 05:46:23 by srsa_4c »

 

Related Topics