root/platform/a1300/sub/100b/lib.c

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

DEFINITIONS

This source file includes following definitions.
  1. hook_raw_image_addr
  2. hook_alt_raw_image_addr
  3. vid_get_viewport_live_fb
  4. _GetBatteryTemperature
  5. vid_get_bitmap_fb
  6. vid_get_viewport_fb
  7. vid_get_viewport_fb_d
  8. camera_jpeg_count_str
  9. get_flash_params_count

   1 #include "platform.h"
   2 
   3 char *hook_raw_image_addr()     {return (char*) 0x420B7FC0;}   //Found @0xffae0ef4 a810
   4 char *hook_alt_raw_image_addr() {return (char*) 0x420B7FC0;}   //Found @0xffae0ef4 a810
   5 
   6 
   7 void *vid_get_viewport_live_fb()
   8 {
   9     void **fb=(void **)0x2274;
  10     unsigned char buff = *((unsigned char*)0x2094);
  11     if (buff == 0) {
  12         buff = 2;
  13     }
  14     else {
  15         buff--;
  16     }
  17     return fb[buff];
  18 }
  19 
  20 /*
  21  * Note copied from SX110 IS
  22  * GetBatteryTemperature usually will get back temperature of battery compartment/batteries. GetBatteryTemperature is implemented in Canon's firmware for SX120IS.
  23  * Firmware entry point is identified (0xFFC394D8) but function is not usable. Camera will crash if Canon's GetBatteryTemperature is called by CHDK.
  24  * To avoid a crash Canon's GetBatteryTemperature must not called. As long CHDK general code do not distinguish between cameras that support or don't support GetBatteryTemperature,
  25  * this function will be implemented as specific CHDK-code. It returns always with -99 (which means -99° Celsius or -146° Fahrenheit).
  26  * Original entry point in Canon's firmware is disabled (in stubs_entry.S).
  27  * */
  28 int _GetBatteryTemperature()     { return -99;}
  29 
  30 /*Auto generated for a810*/
  31 void *vid_get_bitmap_fb()        { return (void*)0x40411000; }             // Found @0xff8521ac
  32 void *vid_get_viewport_fb()      { return (void*)0x40566b80; }             // Found @0xffade038
  33 void *vid_get_viewport_fb_d()    { return (void*)(*(int*)(0x2950+0x54)); } // Found @0xff867ad4 & 0xff867b0c
  34 char *camera_jpeg_count_str()    { return (char*)0x000b376c; }             // Found @0xff9c9134
  35 int get_flash_params_count(void) { return 0xa6; }                          // Found @0xff985564

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