source: trunk/platform/ixus220_elph300hs/sub/101a/lib.c @ 1448

Revision 1448, 1.5 KB checked in by philmoz, 2 years ago (diff)

Update to finsig_dryos.c to find additional values from stubs_min.S:

  • finds focus_len_table for most cameras with CAM_DNG_LENS_INFO defined
  • finds zoom_busy and focus_busy values
  • finds recreview_hold value. Note the value found for this does not match the existing value for most cameras. The value found for recreview_hold has been confirmed correct for the G10, G12, SX30, SX40, IXUS120 & IXUS310.
  • Property svn:eol-style set to native
Line 
1#include "platform.h"
2
3/*
4IXUS220HS / ELPH300HS
5full 19131120
60x1048 *  BF4   =  C29CA0
74168 * 3060 = 12754080
8*/
9
10char *hook_raw_image_addr()
11{
12
13        if (*((int*)0x2E94) != 0)
14                return (char*) 0x46000000;
15        else
16                return (char*) 0x413391A0;  // FFB615BC
17
18}
19
20char *hook_alt_raw_image_addr()
21{
22
23        if (*((int*)0x2E94) == 0)
24                return (char*) 0x46000000;
25        else
26                return (char*) 0x413391A0;  // FFB615BC
27
28}
29
30long hook_raw_size()
31{
32        //FF375484 dword_FF375484  DCD 0x123EAF0
33        return 0x0123eaf0;
34       
35}
36
37void *vid_get_viewport_live_fb()
38{
39        return (void*)(void*)(*(int*)(0x2258));
40       
41        // Found by searching RAM locations that referenced 0x405D7980 (viewport buffer)
42        // and also changed to the other buffer addresses over time. Then used each here
43        // and selected value that gave the fastest Motion Detect response using http://dataghost.com/chdk/md_meter.html.
44}
45
46// OSD buffer
47void *vid_get_bitmap_fb()
48{       
49        //FF050F24                 LDR     R0, =0x40471000
50        return (void*)0x40471000;
51}                                 
52
53// Live picture buffer (shoot half-pressed)
54void *vid_get_viewport_fb()
55{
56        return (void*)0x405c6b80;                                                          // found by search for VRAM Address @FF371E8C
57}
58
59void *vid_get_viewport_fb_d()
60{
61        //FF06C580 dword_FF06C580  DCD 0x3C70
62        //FF06D300                 STR     R12, [R5,#0x58
63        return (void*)(*(int*)(0x3C70+0x58));                 
64
65}
66
67char *camera_jpeg_count_str()
68{
69        //FF2327FC                 LDR     R0, =0xCA790
70        return (void*)0x000babac;                                     
71
72}
73
Note: See TracBrowser for help on using the repository browser.