Changeset 1620


Ignore:
Timestamp:
01/28/12 03:39:05 (16 months ago)
Author:
philmoz
Message:

Merged revision(s) 1617 from branches/release-1_0:
Updates to A3300 IS from mk11174. Includes new firmware version 1.00d.
http://chdk.setepontos.com/index.php?topic=650.msg80579#msg80579

Location:
trunk
Files:
23 edited
1 copied

Legend:

Unmodified
Added
Removed
  • trunk

  • trunk/camera_list.csv

    r1613 r1620  
    55a3000,100c,BETA,, 
    66a3000,100d,BETA,, 
    7 a3300,100a,ALPHA,,SKIP_AUTOBUILD 
     7a3300,100a,BETA,,SKIP_AUTOBUILD 
     8a3300,100d,BETA,,SKIP_AUTOBUILD 
    89a410,100f,BETA,100e, 
    910a430,100b,BETA,,SKIP_AUTOBUILD 
  • trunk/core/gui_draw.h

    r1556 r1620  
    734734#define COLOR_HISTO_RG_PLAY COLOR_YELLOW 
    735735 
     736// Used by :- A3300IS 
    736737#elif CAM_BITMAP_PALETTE==14 
    737738 
    738 // Used by :- A3300IS 
    739  
     739#define COLOR_TRANS                     0x4C 
    740740#define COLOR_WHITE         0x01 
    741741#define COLOR_RED           0x6C 
    742 #define COLOR_GREY          0x1a 
    743 #define COLOR_GREY_LIGHT    0x0B 
    744 #define COLOR_GREY_DARK     0x19 
    745 #define COLOR_GREEN         0xa0 
    746 #define COLOR_BLUE_LT       0x96 
    747 #define COLOR_BLUE          0xa1 
    748 #define COLOR_YELLOW        0x92 
    749 #define COLOR_BG            0x62 
    750 #define COLOR_FG            COLOR_WHITE 
    751 #define COLOR_SELECTED_BG   0x0e 
    752 #define COLOR_SELECTED_FG   COLOR_BLACK 
    753 #define COLOR_ALT_BG        COLOR_BG 
     742#define COLOR_GREY          0x1D 
     743#define COLOR_GREEN         0x5A 
     744#define COLOR_BLUE_LT       0x58 
     745#define COLOR_BLUE          0x6D 
     746#define COLOR_YELLOW        0x51 
     747#define COLOR_BG            COLOR_TRANS 
     748#define COLOR_FG            COLOR_WHITE 
     749#define COLOR_SELECTED_BG   COLOR_RED 
     750#define COLOR_SELECTED_FG   COLOR_WHITE 
     751#define COLOR_ALT_BG        COLOR_TRANS 
    754752#define COLOR_SPLASH_RED    COLOR_RED 
    755 #define COLOR_SPLASH_PINK   0x9F    // Orange 
    756 #define COLOR_SPLASH_GREY   0x16 
    757 #define COLOR_HISTO_R       0x6C 
    758 #define COLOR_HISTO_R_PLAY  COLOR_RED 
    759 #define COLOR_HISTO_B       0x6D 
    760 #define COLOR_HISTO_B_PLAY  COLOR_BLUE 
    761 #define COLOR_HISTO_G       0x90 
    762 #define COLOR_HISTO_G_PLAY  COLOR_GREEN 
    763 #define COLOR_HISTO_BG      0x52    // COLOR_BLUE_LT 
    764 #define COLOR_HISTO_RG      0x51    // COLOR_YELLOW 
    765 #define COLOR_HISTO_RB      0x3D    // COLOR_RED 
    766 #define COLOR_HISTO_RB_PLAY COLOR_HISTO_RB 
    767 #define COLOR_HISTO_BG_PLAY COLOR_BLUE_LT 
    768 #define COLOR_HISTO_RG_PLAY COLOR_YELLOW 
     753#define COLOR_SPLASH_PINK   COLOR_YELLOW 
     754#define COLOR_SPLASH_GREY   COLOR_GREY 
     755// colors for blended histo 
     756#define COLOR_HISTO_R       COLOR_RED 
     757#define COLOR_HISTO_R_PLAY  0x9F 
     758#define COLOR_HISTO_B       COLOR_BLUE 
     759#define COLOR_HISTO_G       COLOR_GREEN 
     760#define COLOR_HISTO_G_PLAY  0xA0 
     761#define COLOR_HISTO_BG      COLOR_BLUE_LT 
     762#define COLOR_HISTO_RG      COLOR_YELLOW 
     763#define COLOR_HISTO_RB      0x66 
     764#define COLOR_HISTO_RB_PLAY 0x9F 
     765#define COLOR_HISTO_B_PLAY  0xA1 
     766#define COLOR_HISTO_BG_PLAY 0xA0 
     767#define COLOR_HISTO_RG_PLAY 0x9F 
    769768#undef SCREEN_COLOR 
    770 #define SCREEN_COLOR            0x1D 
     769#define SCREEN_COLOR        0x4C 
    771770 
    772771// Icon colors 
     
    774773// Separate definitions for record and playback mode 
    775774// to cater for cameras with variable palettes 
    776 #define COLOR_ICON_REC_RED                      0x3D 
    777 #define COLOR_ICON_REC_RED_DK           0x9F 
    778 #define COLOR_ICON_REC_RED_LT           0x1E 
     775        // Record mode colors 
     776#define COLOR_ICON_REC_RED                      COLOR_RED 
     777#define COLOR_ICON_REC_RED_DK           COLOR_RED 
     778#define COLOR_ICON_REC_RED_LT           COLOR_RED 
    779779#define COLOR_ICON_REC_GREEN            0x90 
    780 #define COLOR_ICON_REC_GREEN_DK         0x5A 
    781 #define COLOR_ICON_REC_GREEN_LT         0x59 
    782 #define COLOR_ICON_REC_YELLOW           0x2D 
    783 #define COLOR_ICON_REC_YELLOW_DK        0x1E 
    784 #define COLOR_ICON_REC_YELLOW_LT        0x20 
     780#define COLOR_ICON_REC_GREEN_DK         COLOR_GREEN 
     781#define COLOR_ICON_REC_GREEN_LT         0x50 
     782#define COLOR_ICON_REC_YELLOW           0x6B 
     783#define COLOR_ICON_REC_YELLOW_DK        COLOR_YELLOW 
     784#define COLOR_ICON_REC_YELLOW_LT        0x6B 
    785785#define COLOR_ICON_REC_GREY                     COLOR_GREY 
    786 #define COLOR_ICON_REC_GREY_DK          0x1A 
    787 #define COLOR_ICON_REC_GREY_LT          0x11 
     786#define COLOR_ICON_REC_GREY_DK          COLOR_GREY 
     787#define COLOR_ICON_REC_GREY_LT          0x13 
     788        // Playback mode colors 
    788789#define COLOR_ICON_PLY_RED                      0x9F 
    789790#define COLOR_ICON_PLY_RED_DK           0x9F 
    790 #define COLOR_ICON_PLY_RED_LT           0x1E 
     791#define COLOR_ICON_PLY_RED_LT           0x9F 
    791792#define COLOR_ICON_PLY_GREEN            0xA0 
    792793#define COLOR_ICON_PLY_GREEN_DK         0xA0 
    793794#define COLOR_ICON_PLY_GREEN_LT         0x9E 
    794 #define COLOR_ICON_PLY_YELLOW           0x55 
    795 #define COLOR_ICON_PLY_YELLOW_DK        0x55 
    796 #define COLOR_ICON_PLY_YELLOW_LT        0x4C 
     795#define COLOR_ICON_PLY_YELLOW           0x92 
     796#define COLOR_ICON_PLY_YELLOW_DK        0x92 
     797#define COLOR_ICON_PLY_YELLOW_LT        0x90 
    797798#define COLOR_ICON_PLY_GREY                     COLOR_ICON_REC_GREY 
    798799#define COLOR_ICON_PLY_GREY_DK          COLOR_ICON_REC_GREY_DK 
  • trunk/include/modelist.h

    r1590 r1620  
    126126    MODE_SNOW               , 
    127127    MODE_FIREWORK           , // ixus1000 end 
     128    MODE_LIVE               , // A3300is 
     129    MODE_DISCREET                        , // A3300is 
    128130}; 
    129131 
  • trunk/loader/a3300/entry.S

    r1552 r1620  
    11    .section .entry 
    2  
    3 // Turn OFF SD Card power            
    4 // to support autostart. Disabled for SX220. 
    5 //      LDR     R3, =0xC0220018 
    6 //      MOV     R2, #0x44 
    7 //      STR     R2, [R3] 
    82         
    93// looks like idle cycle is required for proper shutdown 
    10         MOV     R3, #0xF0000   // increased from 8000 to F0000 for extra delay for sx200 maybe could be 10000 ? 
     4        MOV     R3, #0xF0000   
    1151: 
    126        SUB     R3, R3, #1 
  • trunk/loader/a3300/main.c

    r1552 r1620  
    2424} 
    2525 
    26 #define LED_PR 0xC02200F0   // -> ASM1989 08.24.2010 found at  FF91E080  in sx200 was FF8E73D0 
     26#define LED_PR 0xC02200F0 
    2727 
    2828 
  • trunk/loader/a3300/resetcode/main.c

    r1552 r1620  
    3434        } 
    3535         
    36 //SX230 found at FF02D3D8 
     36//a3300is found at FF83BF10 
    3737        asm volatile ( 
    38                         //SX220 found at FF02D058 
    39                //  "MRS     R0, CPSR\n"            //SX220 not present in dump 
    40                //  "BIC     R0, R0, #0x3F\n" 
    41                //  "ORR     R0, R0, #0xD3\n" 
    42                //  "MSR     CPSR, R0\n" 
    4338                 "LDR     R1, =0xC0200000\n" 
    4439                 "MVN     R0, #0\n" 
     
    7772                 "MOV     R1, #0x80000000\n" 
    7873                 "STR     R0, [R1,#0xFFC]\n" 
    79            //    "LDR     R0, =0xFF000000\n"            //SX220 was disabled previously 
     74           //    "LDR     R0, =0xFF810000\n"            //a3300is disabled 
    8075                 "MOV     R0, %0\n"              // new jump-vector 
    8176                 "LDMFD   SP!, {R4,LR}\n" 
  • trunk/platform/a3300/kbd.c

    r1568 r1620  
    1515static long kbd_mod_state[3] = { 0xFFFFFFFF, 0xFFFFFFFF, 0xFFFFFFFF }; 
    1616 
    17 static KeyMap keymap[]; 
    1817static long last_kbd_key = 0; 
    1918 
    2019static long alt_mode_key_mask = 0x00000030; // disp + set 
    21 static int alt_mode_led=0; 
    2220extern void _GetKbdState(long*); 
    2321 
    2422// override key and feather bits to avoid feather osd messing up chdk display in ALT mode 
    25 #define KEYS_MASK0 (0x00000000)     // physw_status[0] was 7FC05 
     23#define KEYS_MASK0 (0x00000000) 
    2624#define KEYS_MASK1 (0x00000000) 
    27 #define KEYS_MASK2 (0x0000F0BF) 
     25#define KEYS_MASK2 (0x0000F0BF)         //set to avoid canon menu being effected while in Alt mode 
    2826  
    2927#define LED_AF 0xC02200F4 
     
    7775        } 
    7876} 
    79 /*void my_blinkk(void) { 
    80         int i; 
    81         while(1) { 
    82                 *((volatile int *) 0xC02200FD) = 0x46; // Turn on LED 
    83                 for (i=0; i<0x200000; i++) { asm volatile ( "nop\n" ); } 
    84  
    85                 *((volatile int *) 0xC02200FD) = 0x44; // Turn off LED 
    86                 for (i=0; i<0x200000; i++) { asm volatile ( "nop\n" ); } 
    87  
    88                 *((volatile int *) 0xC02200FD) = 0x46; // Turn on LED 
    89                 for (i=0; i<0x200000; i++) { asm volatile ( "nop\n" ); } 
    90  
    91                 *((volatile int *) 0xC02200FD) = 0x44; // Turn off LED 
    92                 for (i=0; i<0x900000; i++) { asm volatile ( "nop\n" ); } 
    93         } 
    94 } */ 
     77 
    9578 
    9679extern long __attribute__((naked)) wrap_kbd_p1_f() { 
    9780         
    98         //FF8346D4 
     81 
    9982        asm volatile( 
    10083                "STMFD  SP!, {R1-R7,LR} \n" 
    10184                "MOV    R5, #0 \n" 
    10285                //"BL           _kbd_read_keys \n" 
    103                 "BL             my_kbd_read_keys \n"    // pached 
     86                "BL             my_kbd_read_keys \n"    // pacthed 
    10487                "B              _kbd_p1_f_cont \n" 
    10588        ); 
     
    11194         
    11295        while (physw_run) { 
    113         _SleepTask(*((int*)(0x1C30 +0x8))); //  @FF0248AC 
     96        _SleepTask(*((int*)(0x1C30 + 0x8))); //  @FF834160 + FF834168 
    11497 
    11598                if (wrap_kbd_p1_f() == 1) {   // autorepeat ? 
     
    127110} 
    128111 
    129 // like SX110 
     112 
    130113void my_kbd_read_keys() { 
    131114                 
     
    137120        _GetKbdState( kbd_new_state ); 
    138121        _kbd_read_keys_r2( kbd_new_state); 
    139          
    140 //    kbd_new_state[0] = physw_status[0];  //sx220 changed from physw_status[0] 
    141  //   kbd_new_state[2] = physw_status[2]; 
    142  //   kbd_new_state[3] = physw_status[3]; //sx220 added 
    143122         
    144123 
     
    314293    } 
    315294#endif 
    316  
    317  
    318  
  • trunk/platform/a3300/lib.c

    r1552 r1620  
    3232 
    3333int get_flash_params_count(void){ 
    34  return 0xA0;   //@FF1B94A8 in GetParameterData  
     34 return 0xa0;   // Found @0xff994830  a3300is 
    3535} 
    3636 
     37long vid_get_viewport_height() 
     38{ 
     39        return 240; 
     40} 
     41 
     42 
     43//Have to disable here and add to /sub for 100a  
     44//cause 100d crashes when in shoot mode trying to access Alt menu. 
     45//Re-Added in /SUB/100a 
     46//--------------------------------------------------------------- 
    3747/*void vid_bitmap_refresh() { 
    3848         
     
    4555        _ScreenUnlock(); 
    4656}*/ 
    47  
    48 extern void draw_filled_rect( int, int, int, int, int ); 
    49  
    50 void vid_bitmap_refresh() 
    51 { 
    52         draw_filled_rect(0, 0, CAM_BITMAP_WIDTH, CAM_BITMAP_HEIGHT, 0x00) ; 
    53 } 
    54  
    55  
  • trunk/platform/a3300/main.c

    r1554 r1620  
    2828} 
    2929 
    30 // WARNING WARNING WARNING - following stuff is copy/paste garbage from another port INCLUDING THE COMMENTS - reyalp 
    31 #define NUM_FL 126              // 0 - 125, entries in firmware (3 words each entry, first is FL) 
    32 // Focus length table in firmware @FFF4A3DC  - reyalp not really, this is a LIE! 
     30 
     31#define NUM_FL 12 
    3332extern int focus_len_table[NUM_FL*3]; 
    34  
    35 // Focal length range is 5.0 - 70,0 mm, 28 - 392 in 35-mm equivalent. 
    36 // So, CF_EFL = 28/5.0*10000=56000 or392/70*10000=56000 
     33//a3300is 
     34// Focal length range is 5.0 - 25.0 mm, 28 - 140 in 35-mm equivalent. 
     35// So, CF_EFL = 28/5.0*10000=56000 or 140/25*10000=56000 
    3736// divide by 10 to avoid overflow in get_effective_focal_length() 
    3837#define CF_EFL  5600 
    39 const int zoom_points = 126; 
     38const int zoom_points = NUM_FL; 
    4039 
    41 //TODO 
     40 
    4241int get_effective_focal_length(int zp) { 
    43         return (CF_EFL*get_focal_length(zp))/1000; 
     42        return (CF_EFL*get_focal_length(zp))/10000; 
    4443} 
    4544 
    46 //TODO 
     45 
    4746int get_focal_length(int zp) { 
    4847         
     
    5049        else if (zp >= NUM_FL) zp = NUM_FL-1; 
    5150        return focus_len_table[zp*3]; 
    52 /*       
    53         int i; 
    5451 
    55         if (zp<fl_tbl[0].zp) 
    56                 return fl_tbl[0].fl; 
    57         else if (zp>fl_tbl[NUM_FL-1].zp) 
    58                 return fl_tbl[NUM_FL-1].fl; 
    59         else 
    60                 for (i=1; i<NUM_FL; ++i) { 
    61                         if (zp==fl_tbl[i-1].zp) 
    62                                 return fl_tbl[i-1].fl; 
    63                         else if (zp==fl_tbl[i].zp) 
    64                                 return fl_tbl[i].fl; 
    65                         else if (zp<fl_tbl[i].zp) 
    66                                 return fl_tbl[i-1].fl+(zp-fl_tbl[i-1].zp)*(fl_tbl[i].fl-fl_tbl[i-1].fl)/(fl_tbl[i].zp-fl_tbl[i-1].zp); 
    67                 } 
    68         return fl_tbl[NUM_FL-1].fl; 
    69 */ 
    70 } 
    71  
    72 //TODO 
    73 int get_zoom_x(int zp) { 
    74         return get_focal_length(zp)*10/focus_len_table[0]; 
    75         //return get_focal_length(zp)*10/fl_tbl[0].fl; 
    7652} 
    7753 
    7854 
    79 //TODO 
     55int get_zoom_x(int zp) { 
     56        return get_focal_length(zp)*10/focus_len_table[0]; 
     57 
     58} 
     59 
     60 
     61 
    8062long get_vbatt_min() 
    8163{ 
    82         return 3280;  // min observed was 3.408, then it died 
     64        return 3000; 
    8365} 
    8466 
    85 //TODO 
     67 
    8668long get_vbatt_max() 
    8769{ 
    88         return 4057;  // fresh from change (actual was 4.127) 
     70        return 4150; 
    8971} 
  • trunk/platform/a3300/notes.txt

    r1554 r1620  
    1 A3300 notes 
     1Canon A3300is 
    22 
    3 WARNING WARNING WARNING 
     3Just to Note: I am not a programmer, I have never touched coding before this port, I wanted this port for my daughter so I gave it a shot and am pleased with the progress. 
    44 
    5 This is an *incomplete* alpha port, done by an person with limited programming experience. It has known issues, and likely many unknown issues. 
     5I have never used CHDK before, but from what I can tell, everything in the menus seem to work. 
    66 
    7 If you are an experienced programmer with this camera, you may want to start from scratch rather than trying to fix this port. 
    8 Most of the comments are probably copy/pasted from other ports, DO NOT TRUST THEM. 
     7One thing I notice is with the aperture, when you override it, it does effect the exposure of the image and it shows the value in stats display, but only at F2.8 will it actually show F2.8 on the canon OSD. But it is working it seems and does change the exposure on every setting. Any override at wide zoom other then F2.8 will show F8.0 on Canons OSD. 
    98 
    10 If you are an end user and somehow obtained a build of this, you should proceed with caution and assume that things will be broken. 
     9Shutter seems fine except when you go past 15", the cam can take 64sec expsosures when overridden so it is working fine, but canon only shows 15" 
    1110 
    12 porting thread http://chdk.setepontos.com/index.php?topic=6972.0 
     11------------------------------------------------------------------------- 
     12To enter CHDK <Alt> mode use the DISP+SET button. 
    1313 
    14 TOTALLY INCOMPLETE LIST OF OF KNOWN ISSUES: 
    15 modemap in shooting.c is wrong (see stubs_entry.S) 
    16 zoom step / focus table etc stuff in main.c is wrong (copy/paste from some totally different camera) 
    17 lib.c get_flash_params_count likely wrong 
    18 platform_camera.h values are likely wrong 
     14 
     15----------------------------------------------------------------------- 
     16Shortcut Keys 
     17 In Alt mode 
     18: 
     19Press Display to toggle Zoom focusing if Stats are turn on in OSD menu 
     20Press + or - to change Factor 
     21Use zoom lever to focus. 
     22------------------------------------------------------------ 
     23For now colors to get Red logo are set for Shooting mode, Play mode will be orange. 
     24Go into visual settings to adjust and menu colors the way you want. 
     25 
     26Also I had to add a new Pallette==14 to /core/gui_draw.h  to get 
     27red splash screen in shoot mode. 
     28------------------------------------------------------------------------------------  
     29 
     30I also needed to add to /include/modelist.h to get Mode_Live and Mode_Discreet for my cam. 
     31-------------------------------------------------------------------------------------- 
     32Have not tested USB shutter control yet. 
     33------------------------------------------------------------------------------------------------------- 
  • trunk/platform/a3300/platform_camera.h

    r1552 r1620  
    1 // Camera - A2200 - platform_camera.h 
     1// Camera - A3300 - platform_camera.h 
    22 
    3 // This file contains the various settings values specific to the A2200 camera. 
     3// This file contains the various settings values specific to the A3300 camera. 
    44// This file is referenced via the 'include/camera.h' file and should not be loaded directly. 
    55 
     
    2828        #define CAM_DRYOS_2_3_R47       1 
    2929 
    30         #define CAM_RAW_ROWPIX  4704 // Found @0xff1565dc 
    31     #define CAM_RAW_ROWS        3504 // Found @0xff1565e0 
     30        #define CAM_RAW_ROWPIX  4704 // Found @0xFFB213A0   a3300is 
     31   #define CAM_RAW_ROWS 3504 // Found @0xFFB21398  a3300is 
    3232 
    3333        #undef  CAM_UNCACHED_BIT 
    34         #define CAM_UNCACHED_BIT        0x40000000      // Found @0xff83a6a8 
     34        #define CAM_UNCACHED_BIT        0x40000000      // Found @0xff83a6a8   a3300is 
    3535         
    36         #define CAM_JPEG_WIDTH          4608         
    37     #define CAM_JPEG_HEIGHT     3456 
     36        #define CAM_JPEG_WIDTH          4608        // a3300is   @FFB213A0 
     37   #define CAM_JPEG_HEIGHT      3456            // a3300is   @FFB213A8 
    3838         
    39         #define CAM_ACTIVE_AREA_X1      0   
    40         #define CAM_ACTIVE_AREA_Y1      0   
    41         #define CAM_ACTIVE_AREA_X2      4704 
    42         #define CAM_ACTIVE_AREA_Y2      3504 
     39        #define CAM_ACTIVE_AREA_X1      16 
     40        #define CAM_ACTIVE_AREA_Y1      26 
     41        #define CAM_ACTIVE_AREA_X2      4640 
     42        #define CAM_ACTIVE_AREA_Y2      3486     
     43 
     44        #define DNG_VERT_RLE_BADPIXELS          1 
     45        #define CAM_DNG_LENS_INFO       { 50,10, 250,10, 28,10, 59,10 } // See comments in camera.h   a3300is 
    4346         
    44         // Almost sure values 
    45         // 
    4647        #undef  CAM_SENSOR_BITS_PER_PIXEL 
    4748        #define CAM_SENSOR_BITS_PER_PIXEL       12 
    4849         
    49         #define cam_CFAPattern                                  0x01000201      // Green  Blue  Red  Green 
     50        #define cam_CFAPattern 0x02010100 // Red  Green  Green  Blue 
    5051         
    51         #define CAM_COLORMATRIX1                             \ 
     52   #define CAM_COLORMATRIX1   \ 
    5253        827547, 1000000, -290458, 1000000, -126086, 1000000, \ 
    53         -12829, 1000000,  530507, 1000000,   50537, 1000000, \ 
    54           5181, 1000000,   48183, 1000000,  245014, 1000000 
     54    -12829, 1000000,  530507, 1000000,  50537, 1000000, \ 
     55    5181, 1000000,  48183, 1000000,  245014, 1000000 
    5556         
    5657        #define cam_CalibrationIlluminant1      1       // Daylight 
     
    5859        #undef  CAM_USES_ASPECT_CORRECTION 
    5960        #define CAM_USES_ASPECT_CORRECTION      1       //camera uses the modified graphics primitives to map screens an viewports to buffers more sized 
     61 
    6062        #undef CAM_BITMAP_WIDTH 
    6163    #define CAM_BITMAP_WIDTH            720 // Actual width of bitmap screen in bytes 
    6264 
    63         #define  CAM_SHOW_OSD_IN_SHOOT_MENU     1 
    64  
    65         #define CAM_EV_IN_VIDEO         1 
    66          
    6765        #define CAM_QUALITY_OVERRIDE            1 
    6866         
    69         #define CAM_AV_OVERRIDE_IRIS_FIX        1 
    70  
    7167        #define CAM_ZEBRA_ASPECT_ADJUST         1 
    7268        #define CAM_ZEBRA_NOBUF 1 
    7369         
    7470        #define PARAM_CAMERA_NAME       4               // parameter number for GetParameterData 
    75      
     71    
    7672    #define CAM_HAS_ND_FILTER   1 
    7773         
    78         #define CAM_EXT_TV_RANGE        1 
    79          
    8074        #define CAM_VIDEO_QUALITY_ONLY          1 
    81          
     75 
    8276        #define CAM_DETECT_SCREEN_ERASE         1 
    83          
    84         #define DNG_VERT_RLE_BADPIXELS          1 
    85          
     77 
    8678        #define CAM_DATE_FOLDER_NAMING          1 
    8779         
    8880        #define CAM_STARTUP_CRASH_FILE_OPEN_FIX 1 
    89          
    90         #undef  CAM_HAS_MANUAL_FOCUS 
    91          
    92         #undef  CAM_VIDEO_CONTROL 
    9381 
    9482        #define CAM_DRIVE_MODE_FROM_TIMER_MODE  1 
    95          
    96          
     83 
     84        #define CAM_HAS_IRIS_DIAPHRAGM      1 
     85 
     86        #undef  CAM_HAS_MANUAL_FOCUS 
     87        #undef  CAM_VIDEO_CONTROL 
     88        #undef  CAM_CAN_UNLOCK_OPTICAL_ZOOM_IN_VIDEO     
     89 
    9790        #undef  CAM_BITMAP_PALETTE 
    9891        #define CAM_BITMAP_PALETTE      14 
    9992 
    100         #undef CAM_LOAD_CUSTOM_COLORS           // 1       // Enable loading CHDK colors into the camera palette memory/hardware 
    101         #undef CHDK_COLOR_BASE                          // 0x54    // Start color index for CHDK colors loaded into camera palette. 
    102  
     93        #define CHDK_COLOR_BASE                         0x1D    // Start color index for CHDK colors loaded into camera palette. 
    10394        #define CAM_USE_COLORED_ICONS           1       // Enable using the CHDK-DE colored icons. 
    104          
    105         // Not sure values 
    106 //      #undef  CAM_CAN_UNLOCK_OPTICAL_ZOOM_IN_VIDEO 
    107         #define CAM_AF_SCAN_DURING_VIDEO_RECORD 1 
    108         // Debug 
    109         #define PROPCASE_SHOOTING_MODE          49 
  • trunk/platform/a3300/shooting.c

    r1554 r1620  
    1 #include "lolevel.h" 
    2 #include "platform.h" 
    3 #include "core.h" 
    4 #include "conf.h" 
    5 #include "keyboard.h" 
    6 #include "stdlib.h"   
     1#define PARAM_FILE_COUNTER      0x3B    // a3300is 
     2#define PARAM_EXPOSURE_COUNTER  0x02    // a3300is 
     3 
    74#include "platform.h" 
    85 
    9 #define PARAM_FILE_COUNTER      0x3B     
    10 #define PARAM_EXPOSURE_COUNTER  0x02 
    11  
    12 //No zoom 3.1 3.5 4.0 4.5 5.0 5.6 6.3 7.1 8.0 
    13 //maz zoom 5.9 7.1 8.0 
    14   
    156const ApertureSize aperture_sizes_table[] = { 
    16         {  9, 322, "3.1" }, 
    17     { 10, 352, "3.5" }, 
    18         { 11, 384, "4.0" }, 
    19         { 12, 416, "4.5" }, 
    20         { 13, 448, "5.0" }, 
    21         { 14, 480, "5.6" }, 
    22         { 15, 512, "6.3" }, 
    23         { 16, 544, "7.1" }, 
    24         { 17, 576, "8.0" } 
     7        {  9, 293, "2.8" }, 
     8        { 10, 307, "3.2" }, 
     9        { 11, 344, "3.5" }, 
     10        { 12, 388, "4.0" }, 
     11        { 13, 413, "4.5" }, 
     12        { 14, 443, "5.0" }, 
     13        { 15, 476, "5.6" }, 
     14        { 16, 500, "5.9" }, 
    2515}; 
    2616 
     
    7161        {  31,  992, "1/1250",  800 }, 
    7262        {  32, 1024, "1/1600",  625 }, 
    73         {  33, 1056, "1/2000",  500 }, 
    74         {  34, 1088, "1/2500",  400 }, 
    75         {  35, 1120, "1/3200",  313 }, 
    7663}; 
    7764 
    7865const ISOTable iso_table[] = { 
    7966        {  0,    0, "Auto", -1}, 
    80         {  1,  100,  "100", -1}, 
    81         {  2,  200,  "200", -1}, 
    82         {  3,  400,  "400", -1}, 
    83         {  4,  800,  "800", -1}, 
    84         {  5, 1600, "1600", -1}, 
    85         {  6, 3200, "3200", -1}, 
     67        {  1,   80,   "80", -1}, 
     68        {  2,  100,  "100", -1}, 
     69        {  3,  200,  "200", -1}, 
     70        {  4,  400,  "400", -1}, 
     71        {  5,  800,  "800", -1}, 
     72        {  6, 1600,  "1600", -1}, 
     73 
    8674}; 
    8775 
    88 // WARNING WARNING WARNING the following is copy/pasted from another camera and wrong 
    89 /* 
    90 http://www.usa.canon.com/cusa/support/consumer/digital_cameras/other_powershot/powershot_sx230_is#Specifications 
    91 Shooting Modes 
    92         M, Av, Tv, P, Auto, Easy, Movie Digest, Portrait, Landscape, Kids & Pets, SCN, Creative Filter, Movie 
    93    
    94 Movie: High Definition: 1280 x 720 (30 fps); 
    95     Standard Definition: 640 x 480 (30 fps), 320 x 240 (30 fps) 
    96 */ 
    97 static const CapturemodeMap modemap[] = { 
    98         { MODE_AUTO,                    32768  }, 
    99         { MODE_P,                           32772  }, 
    100         { MODE_TV,                              32771  }, 
    101         { MODE_AV,                              32770  }, 
    102         { MODE_M,                               32769  }, 
    103         { MODE_EASY,                            33314  }, 
    104         { MODE_PORTRAIT,                        32783  }, 
    105         { MODE_LANDSCAPE,                       32782  }, 
    106         { MODE_VIDEO_SPEED,                      2626  },       //MODE_VIDEO_SUPER_SLOW_MOTION 
    107         { MODE_VIDEO_STD,                        2621  }, 
    108         { MODE_KIDS_PETS,                       32786  }, 
    109         { MODE_SCN_UNDERWATER,          16409  }, 
    110         { MODE_SCN_LOWLIGHT,            16417  }, 
    111         { MODE_SCN_BEACH,                       16407  }, 
    112         { MODE_SCN_FOLIAGE,                     16405  }, 
    113         { MODE_SCN_SNOW,                        16406  },        
    114         { MODE_SCN_FIREWORK,                    16408  },        
    115         { MODE_SCN_COLOR_ACCENT,         8733  }, 
    116         { MODE_SCN_COLOR_SWAP,                   8734  },        
    117         { MODE_STITCH,                              16908  },   //MODE_SCN_STITCH_ASSIST         
    118         { MODE_SCN_SMART_SHUTTER,       16937  }, 
    119         { MODE_SCN_POSTER_EFFECT,        8743  }, 
    120         { MODE_SCN_FISHEYE,              8747  }, 
    121         { MODE_SCN_MINIATURE,                    8748  }, 
    122         { MODE_SCN_SUPER_VIVID,                  8742  }, 
    123         { MODE_SCN_NIGHT_SCENE,                 16941  },       //MODE_SCN_HANDHELD_NIGHTSCENE 
    124         { MODE_VIDEO_IFRAME_MOVIE,               2628  }, 
    125         { MODE_VIDEO_MOVIE_DIGEST,      33333  }, 
    126         { MODE_SCN_HIGHSPEED_BURST,     16904  }, 
    127         { MODE_SCN_BEST_IMAGE,          16905  }, 
    128         { MODE_SCN_TOY_CAMERA,                   8751  }, 
    129         { MODE_SCN_MONOCHROME,                   8754  }, 
    130         { MODE_SCN_WINK_SELF_TIMER,             16938  }, 
    131    { MODE_SCN_FACE_SELF_TIMER,          16936  }, 
    132 }; 
     76static struct { 
     77        int hackmode; 
     78        int canonmode; 
     79} modemap[] = { 
     80        { MODE_P,                                       32772 }, 
     81        { MODE_LIVE,                            33332 }, 
     82        { MODE_AUTO,                            32768 }, 
     83        { MODE_EASY,                            33314 }, 
     84        { MODE_SCN_PORTRAIT,            16399 }, 
     85        { MODE_SCN_LANDSCAPE,           16398 }, 
     86        { MODE_SCN_KIDS_PETS,           16402 }, 
     87        { MODE_SCN_SMART_SHUTTER,       16937 }, 
     88        { MODE_SCN_LOWLIGHT,            16417 }, 
     89        { MODE_SCN_BEACH,                       16407 }, 
     90        { MODE_SCN_FOLIAGE,                     16405 }, 
     91        { MODE_SCN_SNOW,                        16406 }, 
     92        { MODE_SCN_FIREWORK,            16408 }, 
     93        { MODE_SCN_LONG_SHUTTER,        16390 }, 
     94        { MODE_SCN_FISHEYE,                     8747 }, // not found in stub_entry.S - efect mode - fish eye            a3300is 
     95        { MODE_SCN_MINIATURE,           8748 }, // not found in stub_entry.S - efect mode - miniature           a3300is 
     96        { MODE_SCN_TOY_CAMERA,          8751 }, // not found in stub_entry.S - efect mode - toy camera          a3300is 
     97        { MODE_SCN_MONOCHROME,          8754 }, // not found in stub_entry.S - efect mode - monochrome          a3300is 
     98        { MODE_SCN_SUPER_VIVID,         8742 }, // not found in stub_entry.S - efect mode - super vivid         a3300is 
     99        { MODE_SCN_POSTER_EFFECT,       8743 }, // not found in stub_entry.S - efect mode - poster effect       a3300is 
     100   { MODE_SCN_FACE_SELF_TIMER, 16936 }, 
     101   { MODE_SCN_WINK_SELF_TIMER,  16938 }, 
     102        { MODE_DISCREET,                        32817 }, 
     103        { MODE_VIDEO_STD,                       2621 }, 
     104        { MODE_VIDEO_MINIATURE,         2627 }, 
     105 
     106} ;      
    133107 
    134108#include "../generic/shooting.c" 
    135109 
    136         // Override ISO settings (need to do this before exposure calc for ISO, as well as after)  
    137          
    138         void __attribute__((naked,noinline)) shooting_expo_iso_override(void){  
    139          
    140                 asm volatile("STMFD   SP!, {R0-R12,LR}\n");  
    141                   
    142                 if ((state_kbd_script_run) && (photo_param_put_off.sv96))  
    143                         {  
    144                                 shooting_set_sv96(photo_param_put_off.sv96, SET_NOW);  
    145                                 // photo_param_put_off.sv96 is not reset here, it will be reset in next call to shooting_expo_param_override  
    146                         }  
    147                 else if ((conf.iso_override_value) && (conf.iso_override_koef) && !(conf.override_disable==1))  
    148                                 shooting_set_iso_real(shooting_get_iso_override_value(), SET_NOW);  
    149                 else if (conf.autoiso_enable && shooting_get_flash_mode()/*NOT FOR FLASH AUTO MODE*/ && !(conf.override_disable==1 && conf.override_disable_all))  
    150                                 shooting_set_autoiso(shooting_get_iso_mode());  
    151                   
    152                 asm volatile("LDMFD   SP!, {R0-R12,PC}\n");  
    153         }  
    154          
     110// Override ISO settings (need to do this before exposure calc for ISO as well as after) 
     111void __attribute__((naked,noinline)) shooting_expo_iso_override(void) { 
     112         
     113        asm volatile("STMFD   SP!, {R0-R12,LR}\n"); 
     114         
     115        if ((state_kbd_script_run) && (photo_param_put_off.sv96)) { 
     116                shooting_set_sv96(photo_param_put_off.sv96, SET_NOW); 
     117                // photo_param_put_off.sv96 is not reset here, it will be reset in next call to shooting_expo_param_override 
     118    } 
     119    else if ((conf.iso_override_value) && (conf.iso_override_koef) && !(conf.override_disable==1)) 
     120                shooting_set_iso_real(shooting_get_iso_override_value(), SET_NOW); 
     121    else if (conf.autoiso_enable && shooting_get_flash_mode()/*NOT FOR FLASH AUTO MODE*/ && !(conf.override_disable==1 && conf.override_disable_all)) 
     122                shooting_set_autoiso(shooting_get_iso_mode()); 
     123 
     124        asm volatile("LDMFD   SP!, {R0-R12,PC}\n"); 
     125} 
     126 
    155127 
    156128long get_file_next_counter() { 
     129         
    157130        return get_file_counter(); 
    158131} 
    159132 
    160133long get_target_file_num() { 
     134         
    161135        long n; 
    162136 
    163  
    164137        n = get_file_next_counter(); 
    165  
    166     n = (n>>4)&0x3FFF; 
    167  
     138        n = (n>>4)&0x3FFF; 
    168139        return n; 
    169140} 
    170141 
     142#if defined(CAM_DATE_FOLDER_NAMING) 
     143void get_target_dir_name(char *out) { 
     144         
     145        extern void _GetImageFolder(char*,int,int,int); 
     146        _GetImageFolder(out,get_file_next_counter(),0x400,time(NULL)); 
     147} 
     148#else 
    171149long get_target_dir_num() { 
     150         
    172151        long n; 
    173  
     152         
    174153        n = get_file_next_counter(); 
    175154        n = (n>>18)&0x3FF; 
    176155        return n; 
    177156} 
    178  
    179  
    180 void get_target_dir_name(char *out) 
    181 { 
    182         extern void _GetImageFolder(char*,int,int,int); 
    183         _GetImageFolder(out,get_file_next_counter(),0x400,time(NULL)); 
    184 } 
     157#endif 
    185158 
    186159int circle_of_confusion = 5; 
    187  
  • trunk/platform/a3300/sub/100a/boot.c

    r1552 r1620  
    186186"        LDR     R0, [R0]\n"                    //added 
    187187#endif 
    188  "    LDR     R2, =0x2F1F80 \n"  
     188//"    LDR     R0, =0x16A528 \n"  
     189"    LDR     R2, =0x2F1F80 \n"  
    189190"    STR     R0, [SP, #8] \n"  
    190191"    SUB     R0, R2, R0 \n"  
     
    262263        ); 
    263264} 
     265 
    264266 
    265267//** taskcreate_Startup_my  @ 0xFF81FC58  
     
    313315"    MOV     R3, #0 \n"  
    314316"    STR     R3, [SP] \n"  
    315 //"    LDR     R3, =0xFF81FBF4 \n"                      /replaced with task_startup_my 
    316317"        LDR     R3, =task_Startup_my\n"                //added 
    317318"    MOV     R2, #0 \n"  
     
    321322"    MOV     R0, #0 \n"  
    322323"    LDMFD   SP!, {R3-R9,PC} \n"  
    323 "loc_FF835BCC:\n" 
    324 "        LDR     R0, =0xFFFE0100\n" 
    325 "        LDRB    R0, [R0]\n" 
    326 "        CMP     R0, #0\n" 
    327 "        MOVEQ   R0, #1\n" 
    328 "        MOVNE   R0, #0\n" 
    329 "        BX      LR\n" 
    330         ); 
    331 } 
     324        ); 
     325} 
     326 
    332327 
    333328//** task_Startup_my  @ 0xFF81FBF4  
     
    361356"    BL      sub_FF832F10 \n"  
    362357"    LDMFD   SP!, {R4,LR} \n"  
    363 "        B       sub_FF8166A8\n" 
    364         ); 
    365 } 
     358"    B       sub_FF8166A8 \n"  
     359        ); 
     360} 
     361 
    366362 
    367363//** taskcreatePhySw_my  @ 0xFF834190  
     
    373369"    LDR     R0, [R4, #4] \n"  
    374370"    CMP     R0, #0 \n"  
    375 "    BNE     sub_FF8341C4 \n"  
     371"    BNE     loc_FF8341C4 \n"  
    376372"    MOV     R3, #0 \n"  
    377373"    STR     R3, [SP] \n"  
    378374//"    LDR     R3, =0xFF83415C \n"              //replaced with mykbd_tasks 
    379375"        LDR     R3, =mykbd_task\n"                     //added 
    380 "    MOV     R2, #0x800 \n"  
    381 "        B               sub_FF8341A8\n" 
     376"    MOV     R2, #0x2000 \n"                    //changed from 800 
     377"    MOV     R1, #0x17 \n"  
     378"    LDR     R0, =0xFF8343E4 \n"  
     379"    BL      sub_FF83A410 \n"  
     380"    STR     R0, [R4, #4] \n"  
     381"loc_FF8341C4:\n" 
     382"    BL      sub_FF88B34C \n"  
     383"    BL      sub_FF835B1C \n"  
     384"    CMP     R0, #0 \n"  
     385"    BNE     loc_FF8341E0 \n"  
     386"    LDR     R1, =0x32D40 \n"  
     387"    MOV     R0, #0 \n"  
     388"    BL      sub_FF88B2C0 \n"  
     389"loc_FF8341E0:\n" 
     390"    LDMFD   SP!, {R3-R5,PC} \n"  
    382391        ); 
    383392} 
     
    406415"    BL      sub_FF88D814 \n"  
    407416"        BL              core_spytask_can_start\n"              //added 
    408 "        B       sub_FF895864\n" 
    409         ); 
    410 } 
     417"    CMP     R4, #0 \n"  
     418"    LDMNEFD SP!, {R4-R6,PC} \n"  
     419"    MOV     R0, R5 \n"  
     420"    LDMFD   SP!, {R4-R6,LR} \n"  
     421"    MOV     R1, #0 \n"  
     422"    B       sub_FF89167C \n"  
     423        ); 
     424} 
  • trunk/platform/a3300/sub/100a/capt_seq.c

    r1552 r1620  
    8080"    LDR     R8, [R0, #0xC] \n"  
    8181"    MOV     R0, R8 \n"  
    82 "    BL      sub_FF96EF54_my \n"  
    83 "        BL             capt_seq_hook_raw_here \n"              // added 
     82"    BL      sub_FF96EF54_my \n"                        //patch 
     83"        BL              capt_seq_hook_raw_here \n"             // added 
    8484"    MOV     R4, R0 \n"  
    8585"    MOV     R2, R8 \n"  
     
    220220"    STR     R6, [R4, #8] \n"  
    221221"    B       loc_FF87AB50 \n"  
    222 "    STMFD   SP!, {R3-R5,LR} \n"  
    223 "    LDR     R2, =0x3A1D0 \n"  
    224 "    MOV     R0, #0 \n"  
    225222        ); 
    226223} 
     
    295292"loc_FF96F030:\n" 
    296293"    LDMFD   SP!, {R3-R7,PC} \n"  
    297 "    STMFD   SP!, {R4-R6,LR} \n"  
    298 "    BL      sub_FF87A3BC \n"  
    299294        ); 
    300295} 
     
    589584"    B       loc_FF8BE984 \n"  
    590585"loc_FF8BE864:\n" 
    591 "    BL      sub_FF8BB264_my \n"  
     586"    BL      sub_FF8BB264_my \n"        //patch 
    592587"    MOV     R8, #0 \n"  
    593588"    B       loc_FF8BE984 \n"  
     
    725720"    MOV     R3, #1 \n"  
    726721"    CMP     R0, #0xB \n"  
    727 "    BNE     sub_FF8BEA74 \n"  
     722"    BNE     loc_FF8BEA74 \n"  
    728723"    MOV     R2, #0 \n"  
    729724"    STRD    R2, [SP] \n"  
     
    731726"    MOV     R1, R3 \n"  
    732727"    MOV     R0, #0 \n"  
     728"    BL      sub_FF8BA308 \n"  
     729"    MOV     R3, #1 \n"  
     730"    MOV     R2, #0 \n"  
     731"    STRD    R2, [SP] \n"  
     732"    MOV     R2, R3 \n"  
     733"    MOV     R1, R3 \n"  
     734"    MOV     R0, #0 \n"  
     735"    B       loc_FF8BEAA4 \n"  
     736"loc_FF8BEA74:\n" 
     737"    MOV     R2, #1 \n"  
     738"    STRD    R2, [SP] \n"  
     739"    MOV     R3, R2 \n"  
     740"    MOV     R1, R2 \n"  
     741"    MOV     R0, R2 \n"  
     742"    BL      sub_FF8BA308 \n"  
     743"    MOV     R3, #1 \n"  
     744"    MOV     R2, R3 \n"  
     745"    MOV     R1, R3 \n"  
     746"    MOV     R0, R3 \n"  
     747"    STR     R3, [SP] \n"  
     748"    STR     R3, [SP, #4] \n"  
     749"loc_FF8BEAA4:\n" 
     750"    BL      sub_FF8BA474 \n"  
     751"loc_FF8BEAA8:\n" 
     752"    LDR     R0, [SP, #0x20] \n"  
     753"    BL      sub_FF8BF888 \n"  
    733754        ); 
    734755} 
     
    792813"    STRH    R0, [R4, #0xC] \n"  
    793814"    LDRSH   R0, [R4, #6] \n"  
    794 "    BL      sub_FF8AC12C_my \n"  
     815"    BL      sub_FF8AC12C_my \n"        //patch 
    795816"    LDRSH   R0, [R4, #8] \n"  
    796817"    MOV     R1, #1 \n"  
  • trunk/platform/a3300/sub/100a/kbd.c

    r1552 r1620  
    11#include "lolevel.h" 
    22#include "platform.h" 
    3  
    4 //  
    5 long __attribute__((naked,noinline)) wrap_kbd_p1_f() { 
    6      
    7         asm volatile( 
    8                 "STMFD   SP!, {R1-R5,LR}\n"   
    9                 "MOV     R5, #0\n"                                       
    10                 "BL      my_kbd_read_keys\n" 
    11                 "B       _kbd_p1_f_cont\n" 
    12     ); 
    13          
    14         return 0; 
    15 } 
  • trunk/platform/a3300/sub/100a/lib.c

    r1552 r1620  
    33char *hook_raw_image_addr()    
    44{ 
    5         if (*((int*)0x3A7D) != 0)   //FF887A64 
    6         { 
    7                 return (char*) 0x48000000;  //FF969340 
    8         } 
    9         else 
    10         { 
    11                 return (char*) 0x4207DB20; 
    12         } 
     5                return (char*) 0x4207DB20;              //Found at FFB217F0 a3300is 
     6         
    137} 
    148 
    159char *hook_alt_raw_image_addr()  
    1610{ 
    17         if (*((int*)0x3A7D) == 0)       //FF887A64 
    18                 return (char*) 0x48000000;   //FF969340 
    19         else 
    20                 return (char*) 0x4207DB20; 
     11                return (char*) 0x4207DB20;              //Found at FFB217F0 
    2112} 
    2213 
    2314long hook_raw_size() 
    2415{ 
    25         return 0x01794300;  
     16        return 0x01794300; // Found @0xffb21768  a3300is 
    2617} 
    2718 
    2819char *camera_jpeg_count_str() 
    2920{ 
    30          return (void*)0xb40d4;                                       
     21         return (void*)0xb40d4;   // Found @0xff9fd850   a3300is                                  
    3122} 
    3223 
     
    3425void *vid_get_bitmap_fb() 
    3526{        
    36         return (void*)0x403f1000;  
     27        return (void*)0x403f1000; // Found @0xff85b880 a3300is 
    3728}                                   
    3829 
     
    4031void *vid_get_viewport_fb_d() 
    4132{ 
    42         return (void*)(*(int*)(0x29A0+0x58));                   
     33        return (void*)(*(int*)(0x29A0+0x58));     // FF8708C8 +  FF870DE0  a3300is          
    4334} 
    4435 
     
    4738void *vid_get_viewport_live_fb() 
    4839{ 
    49         if ((mode_get()&MODE_MASK) == MODE_REC) 
    50                 return (void*)((void*)(*(int*)(0x2258))-vid_get_viewport_xoffset()*3); 
    51          
    52         return (void*)(void*)(*(int*)(0x2258)); 
     40        return (void*)(*(int*)(0x20D0+0x138));          //FF850CE8 + FF850D38   a3300is 
    5341} 
    5442 
     
    5644void *vid_get_viewport_fb() 
    5745{        
    58         if ((mode_get()&MODE_MASK) == MODE_REC) 
    59                 return (void*)(0x40546b80-vid_get_viewport_xoffset()*3);   
    60  
    61         return (void*)0x40546b80;                  
     46        return (void*)0x40546b80;       // Found @0xffb1e2ac   a3300is           
    6247} 
    6348 
     49void vid_bitmap_refresh() { 
     50         
     51        extern int full_screen_refresh; 
     52        extern void _ScreenUnlock(); 
     53        extern void _ScreenLock(); 
    6454 
    65 long vid_get_viewport_height() 
    66 { 
    67         return 240; 
     55        full_screen_refresh |= 3; 
     56        _ScreenLock(); 
     57        _ScreenUnlock(); 
    6858} 
  • trunk/platform/a3300/sub/100a/movie_rec.c

    r1552 r1620  
    1515"    STMFD   SP!, {R2-R10,LR} \n"  
    1616"    LDR     R6, =0xFF969628 \n"  
    17 "    LDR     R7, =sub_FF969B20_my \n"  
     17"    LDR     R7, =sub_FF969B20_my \n"   //patch 
    1818"    LDR     R4, =0x66F0 \n"  
    1919"    LDR     R9, =0x67F \n"  
     
    7979"    B       loc_FF96A23C \n"  
    8080"loc_FF96A1EC:\n" 
    81 "    BL      sub_FF969780_my \n"  
     81"    BL      sub_FF969780_my \n"                //patch 
    8282"    B       loc_FF96A23C \n"  
    8383"loc_FF96A1F4:\n" 
     
    646646                "LDR    R0, =0x6774\n" 
    647647                "BL     set_quality\n" 
    648         //PATCH ENDE 
     648        //PATCH END 
    649649"loc_FF96A06C:\n" 
    650650"    CMP     R7, #1 \n"  
  • trunk/platform/a3300/sub/100a/stubs_auto.S

    r1552 r1620  
    3232STUB(FF833B70) 
    3333STUB(FF834190) 
    34 STUB(FF8341A8) 
    35 STUB(FF8341C4) 
    3634STUB(FF8342C8) 
    3735STUB(FF8342CC) 
    3836STUB(FF8342D0) 
    3937STUB(FF83543C) 
     38STUB(FF835B1C) 
    4039STUB(FF835BCC) 
    4140STUB(FF837AA8) 
     
    4645STUB(FF83A1A0) 
    4746STUB(FF83A3B8) 
     47STUB(FF83A410) 
    4848STUB(FF83A550) 
    4949STUB(FF83A610) 
     
    6868STUB(FF87876C) 
    6969STUB(FF878D60) 
    70 STUB(FF87A3BC) 
    7170STUB(FF87AFB4) 
    7271STUB(FF87B300) 
     
    9594STUB(FF884DB8) 
    9695STUB(FF887950) 
     96STUB(FF88B2C0) 
     97STUB(FF88B34C) 
    9798STUB(FF88CFAC) 
    9899STUB(FF88D3E4) 
     
    101102STUB(FF89167C) 
    102103STUB(FF892114) 
    103 STUB(FF895864) 
    104104STUB(FF8ABE30) 
    105105STUB(FF8AC0C0) 
     
    116116STUB(FF8BA210) 
    117117STUB(FF8BA268) 
     118STUB(FF8BA308) 
     119STUB(FF8BA474) 
    118120STUB(FF8BA528) 
    119121STUB(FF8BA7CC) 
     
    136138STUB(FF8BE33C) 
    137139STUB(FF8BE39C) 
    138 STUB(FF8BEA74) 
    139140STUB(FF8BEAA8) 
    140141STUB(FF8BF888) 
  • trunk/platform/a3300/sub/100a/stubs_entry.S

    r1552 r1620  
    1515// Stubs below should be checked. Stub not matched 100%, or difference found to current 'stubs_entry_2.S' 
    1616//    Name                                     Address      Rule  %  Comp to stubs_entry_2.S 
    17 //NSTUB(kbd_pwr_off                           ,0xff86031c) //  2 60%    *** != 0xff810b24 
    18 // ERROR: kbd_pwr_on is not found.                         //--- ---    *** != 0xff810b24 
     17//NSTUB(kbd_pwr_off                           ,0xff86031c) //  2 60%    *** != 0x00000000 
     18// ERROR: kbd_pwr_on is not found.                         //--- ---    *** != 0x00000000 
    1919 
    2020// Check of modemap from 'platform/CAMERA/shooting.c': 
    2121// Firmware modemap table found @ff8959c4 -> ff892270 -> ff9937f8 -> ffac835c -> ffbeea40 
    22 // Mode 16390 in firmware but not in current modemap 
    23 // Mode 33332 in firmware but not in current modemap 
    24 // Mode 16399 in firmware but not in current modemap 
    25 // Mode 16398 in firmware but not in current modemap 
    26 // Mode 16402 in firmware but not in current modemap 
    27 // Mode 32817 in firmware but not in current modemap 
    28 // Mode  2627 in firmware but not in current modemap 
     22// Current modemap entry not found in firmware - MODE_SCN_POSTER_EFFECT    8743 
     23// Current modemap entry not found in firmware - MODE_SCN_SUPER_VIVID      8742 
    2924// Current modemap entry not found in firmware - MODE_SCN_MONOCHROME       8754 
    3025// Current modemap entry not found in firmware - MODE_SCN_TOY_CAMERA       8751 
    31 // Current modemap entry not found in firmware - MODE_SCN_BEST_IMAGE      16905 
    32 // Current modemap entry not found in firmware - MODE_SCN_HIGHSPEED_BURST 16904 
    33 // Current modemap entry not found in firmware - MODE_VIDEO_MOVIE_DIGEST  33333 
    34 // Current modemap entry not found in firmware - MODE_VIDEO_IFRAME_MOVIE   2628 
    35 // Current modemap entry not found in firmware - MODE_SCN_NIGHT_SCENE     16941 
    36 // Current modemap entry not found in firmware - MODE_SCN_SUPER_VIVID      8742 
    3726// Current modemap entry not found in firmware - MODE_SCN_MINIATURE        8748 
    3827// Current modemap entry not found in firmware - MODE_SCN_FISHEYE          8747 
    39 // Current modemap entry not found in firmware - MODE_SCN_POSTER_EFFECT    8743 
    40 // Current modemap entry not found in firmware - MODE_STITCH              16908 
    41 // Current modemap entry not found in firmware - MODE_SCN_COLOR_SWAP       8734 
    42 // Current modemap entry not found in firmware - MODE_SCN_COLOR_ACCENT     8733 
    43 // Current modemap entry not found in firmware - MODE_SCN_UNDERWATER      16409 
    44 // Current modemap entry not found in firmware - MODE_KIDS_PETS           32786 
    45 // Current modemap entry not found in firmware - MODE_VIDEO_SPEED          2626 
    46 // Current modemap entry not found in firmware - MODE_LANDSCAPE           32782 
    47 // Current modemap entry not found in firmware - MODE_PORTRAIT            32783 
    48 // Current modemap entry not found in firmware - MODE_M                   32769 
    49 // Current modemap entry not found in firmware - MODE_AV                  32770 
    50 // Current modemap entry not found in firmware - MODE_TV                  32771 
    5128 
    5229// Values below can be overridden in 'stubs_min.S': 
     
    6239DEF(zoom_status                             ,0x0000cf5c) // Found @0xffacba30 
    6340DEF(some_flag_for_af_scan                   ,0x00006b0c) // Found @0xff96d344 
     41// focus_len_table contains zoom focus lengths for use in 'get_focal_length' (main.c). 
     42// each entry contains 3 int value(s), the first is the zoom focus length. 
     43// there are 12 entries in the table - set NUM_FL to 12 
     44DEF(focus_len_table                         ,0xfffe2f88) // Found @0xfffe2f88 
    6445DEF(zoom_busy                               ,0x0000665c) // Found @0xff964eb8 
    6546DEF(focus_busy                              ,0x000064d8) // Found @0xff960130 
     
    11596NSTUB(CreateTask                              ,0xff81e9b0) //101 
    11697NSTUB(DebugAssert                             ,0xff81ec88) //111 
     98NSTUB(DeleteDirectory_Fut                     ,0xff8366c0) //  1 
    11799NSTUB(DeleteFile_Fut                          ,0xff8365dc) //112 
    118100NSTUB(DoAFLock                                ,0xff838480) //102 
     
    195177NSTUB(UnlockAF                                ,0xff8384b8) //102 
    196178NSTUB(UnlockMainPower                         ,0xff891db8) //103 
    197 //NSTUB(UnsetZoomForMovie                     ,0xff99dd04) //104            == 0xff99dd04 
     179NSTUB(UnsetZoomForMovie                       ,0xff99dd04) //104 
    198180NSTUB(VbattGet                                ,0xff832e20) //101 
    199181NSTUB(Write                                   ,0xff836d18) //101 
  • trunk/platform/a3300/sub/100a/stubs_entry_2.S

    r1552 r1620  
    22#define NULL_SUB 0xFF810B24 
    33 
     4// Not found 
     5NHSTUB(kbd_pwr_off,                                     NULL_SUB) 
     6NHSTUB(kbd_pwr_on,                      NULL_SUB) 
     7 
    48// Override stubs_entry.S 
    5  
    6 NHSTUB(kbd_pwr_off,                                     0xFF810B24) 
    7 NHSTUB(kbd_pwr_on,                      0xFF810B24) 
    8 NHSTUB(SetZoomActuatorSpeedPercent, 0xFF810B24) 
    9  
    10 // These don't exist/aren't found in dryos 
    11 NHSTUB(UnsetZoomForMovie,           0xff99dd04)         // a3300is 
    12 NHSTUB(MakeAFScan,                                      0xFF190E5C)     // a3300is 
    13 NHSTUB(SetFileAttributes,               0xFF83C338)     // a3300is 
     9NHSTUB(SetZoomActuatorSpeedPercent, 0xFFAA1D88)         //      a3300is 
     10NHSTUB(MakeAFScan,                                      0xFF8DC610)     //      a3300is 
  • trunk/platform/a3300/sub/100a/stubs_min.S

    r1552 r1620  
    11#include "stubs_asm.h" 
    2  
    3 //DEF(active_palette_buffer             ,0x9174)         // FFA06C98            a3300is 
    4 //DEF(palette_buffer                    ,0xB4754)        // FFA06DB0            a3300is 
    5 //DEF(palette_control                   ,0x916C)         // FFA06DAC            a3300is 
    6  
    7 DEF(enabled_refresh_physical_screen     ,0x3B04) //(0x3B00+0x4) @FF8A53B4 a3300is 
    8  
    9 DEF(focus_len_table                             ,0xFFFE2F88) // search for 70000 (longest focus length in micrometers) & 5000 (shortest length)  //a3300is 
    10  
  • trunk/platform/a3300/sub/100d/lib.c

    r1617 r1620  
    33char *hook_raw_image_addr()    
    44{ 
    5                 return (char*) 0x42075144;              //Found at FFB217F0     and had to manually adjust till image lined up a3300is 
     5                return (char*) 0x4207DB20;              //Found at FFB217F0 a3300is 
    66         
    77} 
     
    99char *hook_alt_raw_image_addr()  
    1010{ 
    11                 return (char*) 0x42075144;              //Found at FFB217F0     and had to manually adjust till image lined up a3300is 
     11                return (char*) 0x4207DB20;              //Found at FFB217F0 
    1212} 
    1313 
Note: See TracChangeset for help on using the changeset viewer.