Motion Detection too slow? - page 8 - Script Writing - CHDK Forum

Motion Detection too slow?

  • 253 Replies
  • 201509 Views
*

Offline mx3

  • ****
  • 372
Re: Motion Detection too slow?
« Reply #70 on: 04 / February / 2008, 10:36:22 »
Advertisements
barney fife

can you make two RAM dumps and publish search results?
I could make patch (100msecs->30msecs) for you so you could test it

see http://chdk.setepontos.com/index.php/topic,405.msg3372.html#msg3372

anyone willing can try and I will make patch for your's camera model

I don't like idea to analyse all primary bins so make it yourself by easy way :-)
skype: max_dtc. ICQ: 125985663, email: win.drivers(at)gmail, eVB decompiler

Re: Motion Detection too slow?
« Reply #71 on: 04 / February / 2008, 11:18:20 »
Deleted
« Last Edit: 22 / April / 2008, 10:24:29 by Barney Fife »
[acseven/admin commented out: please refrain from more direct offensive language to any user. FW complaints to me] I felt it imperative to withdraw my TOTAL participation. Nobody has my permission, nor the right, to reinstate MY posts. Make-do with my quoted text in others' replies only. Bye

*

Offline Jucifer

  • *****
  • 251
  • [A710IS]
Re: Motion Detection too slow?
« Reply #72 on: 04 / February / 2008, 14:01:04 »
I got this for a710:

When compared the RAM dumps the 3 lines had bytes: 3CA50, not 3F480...
References to the frame buffers are:
[0x0000522C] : 105F25E0
[0x00005230] : 10670EE0
[0x00005234] : 106EF7E0
[0x0000529C] : 105F25E0
[0x00005EF0] : 10670EE0
[0x00005EF4] : 10670EE0
[0x00005F78] : 105F25E0
[0x000AF374] : 10670EE0
[0x00304008] : 106EF7E0
[0x003140E0] : 105F25E0
[0x003140E4] : 105F25E0

So should

void *vid_get_viewport_live_fb()
{
  void **fb=(void **)0x522C;
  return fb[ *((unsigned char*)0x523C) ];
}

be correct? At least it seems to work. (Haven't tested if delay was reduced, though.)
Edit: Tested (non-scientifically), seems to detect much more reliably.
« Last Edit: 04 / February / 2008, 14:22:03 by Jucifer »

Re: Motion Detection too slow?
« Reply #73 on: 04 / February / 2008, 15:51:14 »
Deleted
« Last Edit: 22 / April / 2008, 10:24:53 by Barney Fife »
[acseven/admin commented out: please refrain from more direct offensive language to any user. FW complaints to me] I felt it imperative to withdraw my TOTAL participation. Nobody has my permission, nor the right, to reinstate MY posts. Make-do with my quoted text in others' replies only. Bye

Re: Motion Detection too slow?
« Reply #74 on: 04 / February / 2008, 16:09:00 »
barney fife

can you make two RAM dumps and publish search results?
I could make patch (100msecs->30msecs) for you so you could test it

I wish I could help you at this level MX3, but outside of tweaking the uBASIC scripts, I'm almost completely lost when it comes to do the kind of thing you need.

I have NO idea what any of that even means. change find_diffs.bat? zzz.bat? get info from frame buffers?? Sorry, I'm totally lost on what any of that is about. :-(

I wish I knew, then I'd be more than happy to test the results of what needs to be changed.


I'd say I'm in pretty much the same boat. I tried searching for any info on ram dumping without much luck. Anyone have any guides or Rosetta stones that might help?

Re: Motion Detection too slow?
« Reply #75 on: 04 / February / 2008, 17:03:31 »
RAM dumping:

CHDK debug menu: enable RAM dump

Then press (display) to get ram dump in 100CANON.

It is the 32 MB file, that includes the frame buffers (LCD/EVF).

Make a dump with a dark frame (LCD/EVF), just put cap on lens,
and a dump with a normal frame.
There is no need to take a picture.

*

Offline fudgey

  • *****
  • 1705
  • a570is
Re: Motion Detection too slow?
« Reply #76 on: 04 / February / 2008, 17:31:40 »
I tried fiddling with the RAM dumps according to mx3's directions. This is from an a570is 1.00e:

wine find_diffs crw_0004.jpg crw_0005.jpg 10 6400

The last 3 lines of find_diffs output are the ones with the highest "bytes" values:

(0x00656100 + 0x1900 = 0x00657A00) bytes: 3CA50
(0x006D4A00 + 0x1900 = 0x006D6300) bytes: 3CA50
(0x00753300 + 0x1900 = 0x00754C00) bytes: 3CA50

So, if I'm not mistaken, the addresses are 0x00657A00 0x006D6300 0x00754C00 or 0x00656100 0x006D4A00 0x00753300 without the 0x1900 offset.

zzz.bat puzzles me a bit, since find_u32s.exe says
usage: find_diffs <input file 1 name> <offset> <hex1> <hex2> <hex3>
but zzz.bat has 3 extra argument addresses for the 610.refs output, with 0x10000000 offset to the other 3 args.

So after half a dozen failed attempts to form a proper command line, I ran

wine find_u32s crw_0004.jpg 0x00657A00 0x006D6300 0x00754C00 0x10657A00 0x106D6300 0x10754C00

and finally got some output  :)

[0x0065C6CC] : 10657A00
[0x0065C6D0] : 106D6300
[0x0065C6D4] : 10754C00
[0x0065C73C] : 10657A00
[0x0065DC00] : 10754C00
[0x0065DC04] : 10754C00
[0x0065DC88] : 10657A00
[0x006A9A30] : 10754C00
[0x0070C57C] : 10657A00
[0x0071DFD4] : 10657A00
[0x0095A108] : 10657A00
[0x0096A1E0] : 106D6300
[0x0096A1E4] : 106D6300

Will this be of any use?

*

Offline mx3

  • ****
  • 372
Re: Motion Detection too slow?
« Reply #77 on: 04 / February / 2008, 18:04:23 »
Jucifer, I'm probably wrong, but I think they are trying to find ways to improve the response time with the md_detect's own built-in command for "immediate shoot".
we are talking about using all three available buffers instead of one used by CHDK
we are trying to reduce 100msecs to 30 msecs

this dont have anything to do with immediate shot option
skype: max_dtc. ICQ: 125985663, email: win.drivers(at)gmail, eVB decompiler

*

Offline mx3

  • ****
  • 372
Re: Motion Detection too slow?
« Reply #78 on: 04 / February / 2008, 18:16:46 »

wine find_u32s crw_0004.jpg 0x00657A00 0x006D6300 0x00754C00 0x10657A00 0x106D6300 0x10754C00

and finally got some output  :)

[0x0065C6CC] : 10657A00
[0x0065C6D0] : 106D6300
[0x0065C6D4] : 10754C00
[0x0065C73C] : 10657A00
[0x0065DC00] : 10754C00
[0x0065DC04] : 10754C00
[0x0065DC88] : 10657A00
[0x006A9A30] : 10754C00
[0x0070C57C] : 10657A00
[0x0071DFD4] : 10657A00
[0x0095A108] : 10657A00
[0x0096A1E0] : 106D6300
[0x0096A1E4] : 106D6300

Will this be of any use?

yes. it is usefull. but I would recommend you to add  1900 after file name
i'm drunk right now. i think i can use 0x0065C6CC - 0x00657A00 +0x1900 as a base address
skype: max_dtc. ICQ: 125985663, email: win.drivers(at)gmail, eVB decompiler

*

Offline fudgey

  • *****
  • 1705
  • a570is
Re: Motion Detection too slow?
« Reply #79 on: 04 / February / 2008, 18:30:14 »
Quote
yes. it is usefull. but I would recommend you to add  1900 after file name
i'm drunk right now. i think i can use 0x0065C6CC - 0x00657A00 +0x1900 as a base address

Ok,

Code: [Select]
wine find_u32s crw_0004.jpg 1900 0x00657A00 0x006D6300 0x00754C00 0x10657A00 0x106D6300 0x10754C00

[0x000065CC] : 10657A00
[0x000065D0] : 106D6300
[0x000065D4] : 10754C00
[0x0000663C] : 10657A00
[0x00007B00] : 10754C00
[0x00007B04] : 10754C00
[0x00007B88] : 10657A00
[0x00053930] : 10754C00
[0x000B647C] : 10657A00
[0x000C7ED4] : 10657A00
[0x00304008] : 10657A00
[0x003140E0] : 106D6300
[0x003140E4] : 106D6300


 

Related Topics


SimplePortal © 2008-2014, SimplePortal