root/platform/sx20/sub/102d/stubs_entry.S

/* [<][>][^][v][top][bottom][index][help] */
   1 // !!! THIS FILE IS GENERATED. DO NOT EDIT. !!!
   2 #include "stubs_asm.h"
   3 
   4 // Camera info:
   5 //   DRYOS R39 (DRYOS version 2.3, release #0039)
   6 //   Firmware Ver GM1.02D   // Found @ 0xff88e430, "GM1.02D" @ 0xff88e43d
   7 //   Firmware build timestamp: Mar  9 2010 10:00:57
   8 //   Canon PowerShot SX20 IS
   9 
  10 // Values for makefile.inc
  11 //   DIGIC = 40# DIGIC 4
  12 //   PLATFORMOSVER = 39
  13 //   PLATFORMID = 12772# (0x31e4) Found @ 0xfffe0130
  14 //   MAXRAMADDR = 0x03ffffff
  15 //   MEMISOSTART = 0x0013dd6c
  16 //   KEYSYS = d4# Found @ 0xffff35a0
  17 //   NEED_ENCODED_DISKBOOT = 3# Found @ 0xffff35b0
  18 //   ARAM_HEAP_START = 0x34e000# Found @ 0xff96b28c
  19 //   ARAM_HEAP_SIZE  = 0x32000# Found @ 0xff96b24c
  20 
  21 // Detected address ranges:
  22 // ROM      0xff810000 - 0xffffffff (8323072 bytes)
  23 // RAM data 0x00001900 - 0x0000e7fc copied from 0xffc0f184 (  52988 bytes)
  24 
  25 // Stubs below should be checked. Stub not matched 100%, or difference found to current 'stubs_entry_2.S'
  26 //    Name                                     Address      Rule  %  Comp to stubs_entry_2.S
  27 //NHSTUB(DoAFLock                             ,0xff836a9c) //120        *** != 0xff879704
  28 //NHSTUB(TurnOffBackLight                     ,0xff8a5b30) //104        *** != 0xff89b6f4
  29 //NHSTUB(UIFS_WriteFirmInfoToFile             ,0xff979b78) //120        *** != 0xdeadc0de
  30 //NHSTUB(UnlockAF                             ,0xff836b38) //120        *** != 0xff879714
  31 //NHSTUB(VbattGet                             ,0xff831cec) //120        *** != 0xff95d27c
  32 //NHSTUB(kbd_pwr_off                          ,0xff85f2c4) //  2 60%    *** != 0x00000000
  33 
  34 // Check of modemap from 'platform/CAMERA/shooting.c':
  35 // Firmware modemap table found @ffaac914 -> ffbe87b4
  36 // No problems found with modemap table.
  37 
  38 // Values below can be overridden in 'stubs_min.S':
  39 DEF(physw_status                            ,0x00032464) // Found @0xff83341c
  40 DEF(physw_run                               ,0x00001c44) // Found @0xff83308c
  41 DEF(physw_sleep_delay                       ,0x00001c42) // Found @0xff83308c
  42 DEF(levent_table                            ,0xffba33a8) // Found @0xffba33a8
  43 DEF(FlashParamsTable                        ,0xffbe899c) // Found @0xffbe899c
  44 DEF(movie_status                            ,0x00002c30) // Found @0xff878e00
  45 DEF(video_compression_rate                  ,0x00002c5c) // Found @0xff879008
  46 DEF(full_screen_refresh                     ,0x00009cf4) // Found @0xffa02778
  47 DEF(canon_menu_active                       ,0x0000312c) // Found @0xff88fee0
  48 DEF(canon_shoot_menu_active                 ,0x00008845) // Found @0xff9aa1e4
  49 DEF(playrec_mode                            ,0x00002e58) // Found @0xff882278
  50 DEF(zoom_status                             ,0x0000c6c0) // Found @0xffaaf648
  51 DEF(some_flag_for_af_scan                   ,0x00007934) // Found @0xff95fd00
  52 // focus_len_table contains zoom focus lengths for use in 'get_focal_length' (main.c).
  53 // each entry contains 1 int value, which is the the zoom focus length.
  54 // there are 6 entries in the table - set NUM_FL to 6
  55 DEF(focus_len_table                         ,0xffbadd24) // Found @0xffbadd24
  56 DEF(zoom_busy                               ,0x00006ec0) // Found @0xff955efc
  57 DEF(focus_busy                              ,0x00006d50) // Found @0xff950090
  58 //DEF(recreview_hold                          ,0x00003d2c) // Found @0xff8a1bb0, ** != ** stubs_min = 0x000083d8 (0x82E0+0xF8)
  59 // Palette colour tables  found @ 0xffbbc158
  60 DEF(active_palette_buffer                   ,0x00009cfc) // Found @0xffa026b4
  61 DEF(palette_buffer_ptr                      ,0x00009d08) // Found @0xffa02388
  62 // Offset from start of palette_buffer to color data = 8 (Found @0xffae5998)
  63 // Camera appears to have only 1 RAW buffer @ 0x41f723e0 (Found @0xffb05b50)
  64 DEF(fileio_semaphore                        ,0x000029e0) // Found @0xff86d7e0
  65 DEF(exmem_alloc_table                       ,0x00038dd8) // Found @0xff8897d0
  66 DEF(exmem_types_table                       ,0xffc10800) // Found @0x00002f7c
  67 DEF_CONST(exmem_type_count                  ,0x00000012)
  68 DEF(imager_active                           ,0x00001fac) // Found @0xff84a040 (0x1fa8 + 4)
  69 DEF_CONST(uiprop_count                      ,0x0000006e) // Found @0xff98fb8c
  70 
  71 // Values below go in 'lib.c':
  72 //void *vid_get_bitmap_fb()        { return (void*)0x403f1000; }             // Found @0xff859684
  73 //void *vid_get_viewport_fb()      { return (void*)0x41020120; }             // Found @0xffb03448
  74 DEF(viewport_fb_d                           ,0x00002a88) // Found 0x2a30 (@0xff870890) + 0x58 (@0xff8708c8)
  75 //void *vid_get_viewport_fb_d()    { return (void*)(*(int*)(0x2a30+0x58)); } // Found @0xff870890 & 0xff8708c8
  76 DEF(jpeg_count_str                          ,0x00072dfc) // Found @0xff9f7368
  77 //char *camera_jpeg_count_str()    { return (char*)0x00072dfc; }             // Found @0xff9f7368
  78 //int get_flash_params_count(void) { return 0x84; }                          // Found @0xff9907e0
  79 
  80 // Bitmap masks and physw_status index values for SD_READONLY and USB power flags (for kbd.c).
  81 //#define SD_READONLY_FLAG    0x00020000 // Found @0xffb44d84, levent 0x90a
  82 //#define SD_READONLY_IDX     2
  83 //#define USB_MASK            0x00040000 // Found @0xffb44d90, levent 0x902
  84 //#define USB_IDX             2
  85 //#define BATTCOVER_FLAG      0x00008000 // Found @0xffb44c40, levent 0x905
  86 //#define BATTCOVER_IDX       0
  87 //#define HOTSHOE_FLAG        0x10000000 // Found @0xffb44dfc, levent 0x904
  88 //#define HOTSHOE_IDX         2
  89 //#define ANALOG_AV_FLAG      0x00100000 // Found @0xffb44da8, levent 0x900 (non-inverted logic)
  90 //#define ANALOG_AV_IDX       2
  91 
  92 // Keymap values for kbd.c. Additional keys may be present, only common values included here.
  93 //static KeyMap keymap[] = {
  94 //    { 0, KEY_SHOOT_FULL      ,0x00000003 }, // Found @0xffb44c1c, levent 0x01
  95 //    { 0, KEY_SHOOT_FULL_ONLY ,0x00000002 }, // Found @0xffb44c1c, levent 0x01
  96 //    { 0, KEY_SHOOT_HALF      ,0x00000001 }, // Found @0xffb44c10, levent 0x00
  97 //    { 0, KEY_POWER           ,0x00002000 }, // Found @0xffb44c28, levent 0x600
  98 //    { 0, KEY_PLAYBACK        ,0x00004000 }, // Found @0xffb44c34, levent 0x601
  99 //    { 1, KEY_VIDEO           ,0x00000020 }, // Found @0xffb44c88, levent 0x12
 100 //    { 1, KEY_SET             ,0x00000100 }, // Found @0xffb44cac, levent 0x08
 101 //    { 1, KEY_DISPLAY         ,0x00000200 }, // Found @0xffb44cb8, levent 0x0a
 102 //    { 1, KEY_UP              ,0x00000400 }, // Found @0xffb44cc4, levent 0x04
 103 //    { 1, KEY_DOWN            ,0x00000800 }, // Found @0xffb44cd0, levent 0x05
 104 //    { 1, KEY_RIGHT           ,0x00001000 }, // Found @0xffb44cdc, levent 0x07
 105 //    { 1, KEY_LEFT            ,0x00002000 }, // Found @0xffb44ce8, levent 0x06
 106 //    { 1, KEY_MENU            ,0x00004000 }, // Found @0xffb44cf4, levent 0x09
 107 //    { 0, 0, 0 }
 108 //};
 109 
 110 // Values below go in 'platform_camera.h':
 111 //#define CAM_DRYOS         1
 112 //#define CAM_DRYOS_2_3_R39 1 // Defined for cameras with DryOS version R39 or higher
 113 //#define CAM_RAW_ROWPIX    4080 // Found @0xff92b724
 114 //#define CAM_RAW_ROWS      3048 // Found @0xff92b72c
 115 //#undef  CAM_UNCACHED_BIT
 116 //#define CAM_UNCACHED_BIT  0x40000000 // Found @0xff838e2c
 117 //#define CAM_DATE_FOLDER_NAMING 0x100 // Found @0xffa69cf0 (pass as 3rd param to GetImageFolder)
 118 //#define PARAM_CAMERA_NAME 4 // Found @0xffbeaed8
 119 
 120 // Known propcases
 121 // //      PROPCASE_AFSTEP 13
 122 // #define PROPCASE_FOCUS_STATE 18
 123 // #define PROPCASE_AV 23
 124 // #define PROPCASE_BV 34
 125 // //      PROPCASE_DELTA_DIGITALGAIN 77
 126 // #define PROPCASE_DELTA_SV 79
 127 // //      PROPCASE_DELTA_ND 80
 128 // #define PROPCASE_EV_CORRECTION_2 209
 129 // #define PROPCASE_ORIENTATION_SENSOR 221
 130 // #define PROPCASE_SV_MARKET 248
 131 // //      PROPCASE_SVFIX 249
 132 // #define PROPCASE_TV 264
 133 // Guessed propset: 3
 134 
 135 // Misc stuff
 136 DEF(ctypes, 0xffb3a416)
 137 
 138 // EXMEM types:
 139 // EXMEM_RAMDISK        0
 140 // EXMEM_COM            1
 141 // EXMEM_FORMATTER      2
 142 // EXMEM_SHADING        3
 143 // EXMEM_FAMODE         4
 144 // EXMEM_FIRMUP         5
 145 // EXMEM_FIRMUP_VRAM    6
 146 // EXMEM_FIRMUP_INFLATE 7
 147 // EXMEM_DVLPWORK       8
 148 // EXMEM_EVF            9
 149 // EXMEM_SCRIPT         10
 150 // EXMEM_FILESTORE      11
 151 // EXMEM_MOVIE_REC      12
 152 // EXMEM_MOVIE_PLY      13
 153 // EXMEM_WIDE           14
 154 // EXMEM_NARROW         15
 155 // EXMEM_CRAW_REC       16
 156 // EXMEM_PCEVF          17
 157 
 158 // ISR flag: 0x1964, pointer to current task's control block: 0x1960
 159 // pointer to TCB area: 0x19f0, found @ 0xff81683c
 160 
 161 // LED table init @ 0xff90b838
 162 // LED #1: 0xc02200b4, offset 0x244
 163 
 164 // For capt_seq.c
 165 DEF(_nrflag,0x7910) // Found @ ff9625a8 (0x7918) & ff9625c8 (-0x08)
 166 //static long *nrflag = (long*)(0x7918-0x08);  // Found @ ff9625a8 & ff9625c4
 167 
 168 // Stubs below matched 100%.
 169 //    Name                                     Address                Comp to stubs_entry_2.S
 170 NHSTUB(AllocateUncacheableMemory              ,0xff838de8) //112
 171 NHSTUB(Close                                  ,0xff83527c) //120
 172 NHSTUB(CreateBinarySemaphore                  ,0xff8385c8) //115
 173 NHSTUB(CreateTask                             ,0xff81e5b4) //120
 174 NHSTUB(DebugAssert                            ,0xff81e88c) //107
 175 NHSTUB(DeleteDirectory_Fut                    ,0xff834cec) //116
 176 NHSTUB(DeleteFile_Fut                         ,0xff834c08) //112
 177 NHSTUB(DoAELock                               ,0xff836e28) //120
 178 NHSTUB(EnterToCompensationEVF                 ,0xff836d84) //104
 179 NHSTUB(ExecuteEventProcedure                  ,0xff88b598) //104
 180 NHSTUB(ExitFromCompensationEVF                ,0xff836dc8) //104
 181 NHSTUB(ExitTask                               ,0xff81e844) //120
 182 NHSTUB(ExpCtrlTool_StartContiAE               ,0xff84465c) //104
 183 NHSTUB(ExpCtrlTool_StopContiAE                ,0xff844734) //104
 184 NHSTUB(Fclose_Fut                             ,0xff834d84) //120
 185 NHSTUB(Feof_Fut                               ,0xff834f70) //  1
 186 NHSTUB(Fflush_Fut                             ,0xff834fac) //  1
 187 NHSTUB(Fgets_Fut                              ,0xff834ed8) //  1
 188 NHSTUB(Fopen_Fut                              ,0xff834d44) //120
 189 NHSTUB(Fread_Fut                              ,0xff834e30) //120
 190 NHSTUB(FreeUncacheableMemory                  ,0xff838e28) //112
 191 NHSTUB(Fseek_Fut                              ,0xff834f24) //120
 192 NHSTUB(Fwrite_Fut                             ,0xff834e84) //120
 193 NHSTUB(GetBatteryTemperature                  ,0xff862744) //102
 194 NHSTUB(GetCCDTemperature                      ,0xff8626d0) //102
 195 NHSTUB(GetCurrentAvValue                      ,0xff9526d8) //120
 196 NHSTUB(GetCurrentShutterSpeed                 ,0xff8b13c8) //120
 197 NHSTUB(GetUsableMaxAv                         ,0xffafd598) //120
 198 NHSTUB(GetUsableMinAv                         ,0xffafd580) //120
 199 NHSTUB(GetDrive_ClusterSize                   ,0xff86f1c8) //122
 200 NHSTUB(GetDrive_FreeClusters                  ,0xff86f228) //  3
 201 NHSTUB(GetDrive_TotalClusters                 ,0xff86f1fc) //  3
 202 NHSTUB(GetFocusLensSubjectDistance            ,0xff950bcc) //102
 203 NHSTUB(GetFocusLensSubjectDistanceFromLens    ,0xff951000) //  3
 204 NHSTUB(GetImageFolder                         ,0xff933568) //122
 205 NHSTUB(GetKbdState                            ,0xff85f11c) //109
 206 NHSTUB(GetMemInfo                             ,0xff81a070) //115
 207 NHSTUB(GetOpticalTemperature                  ,0xff8627b8) //120
 208 NHSTUB(GetParameterData                       ,0xff9907a0) //101
 209 NHSTUB(GetPropertyCase                        ,0xff88f32c) //102
 210 NHSTUB(GetSystemTime                          ,0xffa9b880) //120
 211 NHSTUB(GetVRAMHPixelsSize                     ,0xff84f904) //120
 212 NHSTUB(GetVRAMVPixelsSize                     ,0xff84f910) //120
 213 NHSTUB(GetZoomLensCurrentPoint                ,0xff956864) //120
 214 NHSTUB(GetZoomLensCurrentPosition             ,0xffa8ed0c) //102
 215 NHSTUB(GiveSemaphore                          ,0xff838804) //120
 216 NHSTUB(IsStrobeChargeCompleted                ,0xff8ce3f4) //102
 217 NHSTUB(LEDDrive                               ,0xff85e338) //120
 218 NHSTUB(LocalTime                              ,0xff888f0c) //115
 219 NHSTUB(LockMainPower                          ,0xff896efc) //120
 220 NHSTUB(MakeDirectory_Fut                      ,0xff834c7c) //116
 221 NHSTUB(MoveFocusLensToDistance                ,0xffaff710) //102
 222 NHSTUB(MoveIrisWithAv                         ,0xffa971a8) //120
 223 NHSTUB(MoveZoomLensWithPoint                  ,0xffa978d0) //120
 224 NHSTUB(MoveOpticalZoomAt                      ,0xff8363f0) //109
 225 NHSTUB(Open                                   ,0xff835224) //120
 226 NHSTUB(PB2Rec                                 ,0xff899e38) //104
 227 NHSTUB(PT_MoveDigitalZoomToWide               ,0xff8796b4) //120
 228 NHSTUB(PT_MoveOpticalZoomAt                   ,0xff87968c) //120
 229 NHSTUB(PT_PlaySound                           ,0xff8840a8) //102
 230 NHSTUB(PostLogicalEventForNotPowerType        ,0xff894df8) //120
 231 NHSTUB(PostLogicalEventToUI                   ,0xff894e44) //120
 232 NHSTUB(PutInNdFilter                          ,0xffa97754) //102
 233 NHSTUB(PutOutNdFilter                         ,0xffa97778) //102
 234 NHSTUB(Read                                   ,0xff81ab78) //120
 235 NHSTUB(ReadFastDir                            ,0xffa7d6d4) //  3
 236 NHSTUB(Rec2PB                                 ,0xff8988a4) //104
 237 NHSTUB(RefreshPhysicalScreen                  ,0xffa04ad8) //104
 238 NHSTUB(RenameFile_Fut                         ,0xff834b74) //116
 239 NHSTUB(Restart                                ,0xff83a53c) //122
 240 NHSTUB(ScreenLock                             ,0xffa04aa4) //117
 241 NHSTUB(ScreenUnlock                           ,0xffa04b48) //117
 242 NHSTUB(SetAE_ShutterSpeed                     ,0xffb025c0) //102
 243 NHSTUB(SetAutoShutdownTime                    ,0xff896f70) //120
 244 NHSTUB(SetCurrentCaptureModeType              ,0xff89eb78) //120
 245 NHSTUB(SetFileAttributes                      ,0xff83554c) //  3
 246 NHSTUB(SetFileTimeStamp                       ,0xff835508) //  3
 247 NHSTUB(SetLogicalEventActive                  ,0xff896c4c) //120
 248 NHSTUB(SetParameterData                       ,0xff99067c) //101
 249 NHSTUB(SetPropertyCase                        ,0xff88f230) //102
 250 NHSTUB(SetScriptMode                          ,0xff896c9c) //120
 251 NHSTUB(SleepTask                              ,0xff838a6c) //120
 252 NHSTUB(TakeSemaphore                          ,0xff838734) //120
 253 NHSTUB(TurnOnBackLight                        ,0xff8a5b18) //104
 254 NHSTUB(TurnOnDisplay                          ,0xff859888) //120
 255 NHSTUB(TurnOffDisplay                         ,0xff859898) //120
 256 NHSTUB(UnlockAE                               ,0xff836e4c) //120
 257 NHSTUB(UnlockMainPower                        ,0xff896e50) //120
 258 NHSTUB(UpdateMBROnFlash                       ,0xff86f048) //105
 259 NHSTUB(Write                                  ,0xff83530c) //120
 260 NHSTUB(WriteSDCard                            ,0xff940c34) //108
 261 NHSTUB(_log                                   ,0xffb37ed8) //111
 262 NHSTUB(_log10                                 ,0xffb36e1c) //112
 263 NHSTUB(_pow                                   ,0xffb36f8c) //121
 264 NHSTUB(_sqrt                                  ,0xffb39240) //  1
 265 NHSTUB(add_ptp_handler                        ,0xffa49320) //121
 266 NHSTUB(apex2us                                ,0xffa08264) //121
 267 NHSTUB(close                                  ,0xff81a990) //109
 268 NHSTUB(err_init_task                          ,0xff815f28) //111
 269 NHSTUB(exmem_alloc                            ,0xff889dcc) //103
 270 NHSTUB(exmem_free                             ,0xff889e44) //103
 271 NHSTUB(free                                   ,0xff814138) //112
 272 NHSTUB(get_current_nd_value                   ,0xffa8d328) //122
 273 NHSTUB(kbd_p1_f                               ,0xff833498) //109
 274 NHSTUB(kbd_p1_f_cont                          ,0xff8334a4) //109
 275 NHSTUB(kbd_p2_f                               ,0xff832d58) //109
 276 NHSTUB(kbd_read_keys                          ,0xff83341c) //109
 277 NHSTUB(kbd_read_keys_r2                       ,0xff85e850) //109
 278 NHSTUB(lseek                                  ,0xff835398) //120
 279 NHSTUB(malloc                                 ,0xff8140dc) //112
 280 NHSTUB(memcmp                                 ,0xff8203d8) //120
 281 NHSTUB(memcpy                                 ,0xff83e458) //120
 282 NHSTUB(memset                                 ,0xffa072b4) //120
 283 NHSTUB(mkdir                                  ,0xff8356f0) //109
 284 NHSTUB(mktime_ext                             ,0xff8ad110) //  1
 285 NHSTUB(open                                   ,0xff81a8e0) //109
 286 NHSTUB(OpenFastDir                            ,0xffa7d5a0) //  3
 287 NHSTUB(closedir                               ,0xffa7d55c) //  3
 288 NHSTUB(get_fstype                             ,0xff86f24c) //122
 289 NHSTUB(qsort                                  ,0xffaeb65c) //  1
 290 NHSTUB(rand                                   ,0xff8204e0) //121
 291 NHSTUB(realloc                                ,0xffa07330) //115
 292 NHSTUB(reboot_fw_update                       ,0xffa82be4) //106
 293 NHSTUB(set_control_event                      ,0xff8968a0) //111
 294 NHSTUB(srand                                  ,0xff8204d4) //122
 295 NHSTUB(stat                                   ,0xff8353d4) //109
 296 NHSTUB(strcat                                 ,0xff8ac8cc) //  1
 297 NHSTUB(strchr                                 ,0xff813fc0) //  1
 298 NHSTUB(strcmp                                 ,0xff820394) //120
 299 NHSTUB(strcpy                                 ,0xff82037c) //120
 300 NHSTUB(strftime                               ,0xff8acb18) //  1
 301 NHSTUB(strlen                                 ,0xff81400c) //120
 302 NHSTUB(strncmp                                ,0xff813f74) //  1
 303 NHSTUB(strncpy                                ,0xff813f38) //  1
 304 NHSTUB(strrchr                                ,0xff813fe4) //  1
 305 NHSTUB(strtol                                 ,0xff83e738) //101
 306 NHSTUB(strtolx                                ,0xff83e53c) //109
 307    DEF(task_CaptSeq                           ,0xff87cd90) //120
 308    DEF(task_DvlpSeqTask                       ,0xff87e75c) //120
 309    DEF(task_ExpDrv                            ,0xff8c1480) //120
 310    DEF(task_FileWrite                         ,0xffa78f30) //120
 311    DEF(task_InitFileModules                   ,0xff89a91c) //120
 312    DEF(task_MovieRecord                       ,0xff879084) //120
 313    DEF(task_PhySw                             ,0xff833088) //120
 314    DEF(task_RotaryEncoder                     ,0xff85f3cc) //120
 315 NHSTUB(time                                   ,0xff889484) //109
 316 NHSTUB(vsprintf                               ,0xff820340) //115
 317 NHSTUB(EngDrvRead                             ,0xff8342e0) //102
 318 NHSTUB(PTM_GetCurrentItem                     ,0xff897834) //105
 319 NHSTUB(DisableISDriveError                    ,0xffa9985c) //120
 320 NHSTUB(CancelHPTimer                          ,0xff88ac80) //119
 321 NHSTUB(SetHPTimerAfterNow                     ,0xff88ab78) //119
 322 NHSTUB(PT_MFOn                                ,0xff879744) //120
 323 NHSTUB(PT_MFOff                               ,0xff879754) //120
 324 NHSTUB(GetAdChValue                           ,0xff85b160) //120
 325 NHSTUB(get_ptp_buf_size                       ,0xff8f4cf0) //122
 326 NHSTUB(get_ptp_file_buf                       ,0xffa4ad08) //121

/* [<][>][^][v][top][bottom][index][help] */