temperature sensors - Feature Requests - CHDK Forum

temperature sensors

  • 28 Replies
  • 15537 Views
*

Offline LjL

  • ****
  • 266
  • A720IS
temperature sensors
« on: 25 / July / 2008, 15:40:02 »
Advertisements
insert by phyrephox: continued from here

All cameras? I was under the impression that only the higher-end ones and/or the ones with a proprietary battery had temperature sensors.

I think my A720IS just shoots a dark frame whenever the exposure time is more than 1 second...?

Anyway, if a thermometer is indeed available, then you could even just take a bias frame once, and then reconstruct dark frames on the fly based on shutter speed and temperature. Less accurate than a dark frame taken on the spot, but certainly a whole lot faster.
« Last Edit: 28 / July / 2008, 04:09:40 by PhyrePhoX »

*

Offline reyalp

  • ******
  • 14118
Re: temperature sensors
« Reply #1 on: 25 / July / 2008, 16:14:25 »
All cameras? I was under the impression that only the higher-end ones and/or the ones with a proprietary battery had temperature sensors.
My a540 spends some time in Thermometer.c when it decides what dark frame setting should be used, and has strings relating to CCD and battery temp. In one of the other threads (or maybe the wiki) it was reported that (some ?) cameras would do the dark frame on short exposures if they were hot.

Code: [Select]
ROM:FFC1CCF8 0000000E C Thermometer.c                                                                                                               
ROM:FFC1CFB0 00000016 C GetBatteryTemperature                                                                                                       
ROM:FFC1CFC8 00000012 C GetCCDTemperature                                                                                                           
ROM:FFC1CFDC 00000016 C GetOpticalTemperature                                                                                                       
Of course, it's possible that not all cameras have these features, or that it just reports a yes/no rather than a temperature value.

edit:
it's also possible those strings refer to things that aren't present in all models, but are in all the firmwares.
Don't forget what the H stands for.

*

Offline PhyrePhoX

  • *****
  • 2254
  • make RAW not WAR
    • PhyreWorX
Re: temperature sensors
« Reply #2 on: 25 / July / 2008, 16:22:56 »
i once set my old nokia 3210 cellphone into netmon mode and among other things, could readout the temperature. i dont know how they did it, but the weird thing is, this was pretty accurately the temeperature outside of the cellphone.
imagine CHDK - now with Temp sensor, it will warn you to wear gloves when it is below 0 and will advise you to wear sunglasses and shorts when it's hot outside :D

*

Offline ewavr

  • ****
  • 1057
  • A710IS
Re: temperature sensors
« Reply #3 on: 25 / July / 2008, 17:10:29 »
On A710:

GetOpticalTemperature: 33
GetCCDTemperature: 50 (after 2 minutes in live view mode)
GetBatteryTemperature: 32

Room temperature near 30C.
We need also atmosphere pressure meter in camera  :D


*

Offline PhyrePhoX

  • *****
  • 2254
  • make RAW not WAR
    • PhyreWorX
Re: temperature sensors
« Reply #4 on: 25 / July / 2008, 17:34:47 »
haha :D again, please provide adresses or tutorial how to obtain these for other cameras :D
CHDK - the swiss army knife of photography and much more ;)

*

Offline ewavr

  • ****
  • 1057
  • A710IS
Re: temperature sensors
« Reply #5 on: 25 / July / 2008, 18:31:15 »
please provide adresses or tutorial how to obtain these for other cameras :D

How to obtain address of function, which name exists in firmware? Very simply (example for S3IS)
1. Seach string "GetCCDTemperature":

ROM:FF82D300                 CMNMI   R4, #0x11C00000 ; Set cond. codes on Op1 + Op2
ROM:FF82D304                 LDRVSB  R4, [R4,#-0x443] ; Load from Memory
ROM:FF82D308                 RSBVC   R7, R5, #0x6D   ; Rd = Op2 - Op1
ROM:FF82D30C                 RSBVCS  R7, R5, #0x61000000 ; Rd = Op2 - Op1

OMG, this is string, not code! Press 'A' key to convert into string:

ROM:FF82D300 aGetccdtemperature DCB "GetCCDTemperature",0 ; DATA XREF: sub_FF82D244+8Co

if IDA cannot find data reference to string, search it manually (press Alt+B and enter FF82D300)

2. Jump to reference:

ROM:FF82D2D0                 DCD aGetccdtemperature  ; "GetCCDTemperature"
ROM:FF82D2D4                 DCD loc_FF82D368
ROM:FF82D2D8                 DCD aGetbatterytemperature ; "GetBatteryTemperature"
ROM:FF82D2DC                 DCD loc_FF82D37C

Canon's firmware very often includes such lists - first item is name, second - address of function (for service purpose).

So, address of GetCCDTemperature is 0xFF82D368 (loc_FF82D368), address of GetBatteryTemperature is 0xFF82D37C etc.

P.S. Smart IDA scripts can do such things automatically.

*

Offline PhyrePhoX

  • *****
  • 2254
  • make RAW not WAR
    • PhyreWorX
Re: temperature sensors
« Reply #6 on: 25 / July / 2008, 18:50:50 »
this LOOKS easy, but i am such a noob when it comes to IDA and assembly that i will probably never learn it - but others will do, that i'm sure, thanks!
i tried looking at these adresses two adresses you provided in the memory browser, but there wasnt anything in there. i CAN use the memorybrowser to read the temperature at these adresses, can't i?

*

Offline fudgey

  • *****
  • 1705
  • a570is
Re: temperature sensors
« Reply #7 on: 25 / July / 2008, 18:56:48 »
i tried looking at these adresses two adresses you provided in the memory browser, but there wasnt anything in there. i CAN use the memorybrowser to read the temperature at these adresses, can't i?

Umm.. if they are functions that return a temperature, no you cant.

Btw, not surprisingly, a570is 1.00e firmware has some familiar strings:
ffdeabe4 GetBatteryTemperature
ffdeabfc GetCCDTemperature
ffdeac10 GetOpticalTemperature
ffe1b7b4 CurrTemperature         

edit: and I suppose the function entry points are (no, haven't tried them):
GetOpticalTemperature ffdeac50
GetCCDTemperature ffdeac64
GetBatteryTemperature ffdeac78

« Last Edit: 25 / July / 2008, 19:18:56 by fudgey »


*

Offline reyalp

  • ******
  • 14118
Re: temperature sensors
« Reply #8 on: 25 / July / 2008, 19:55:58 »
On A710:

GetOpticalTemperature: 33
GetCCDTemperature: 50 (after 2 minutes in live view mode)
GetBatteryTemperature: 32

Room temperature near 30C.
We need also atmosphere pressure meter in camera  :D
50c :o maybe we need a waterblock hardware mod :D
Don't forget what the H stands for.

*

Offline PhyrePhoX

  • *****
  • 2254
  • make RAW not WAR
    • PhyreWorX
Re: temperature sensors
« Reply #9 on: 25 / July / 2008, 20:41:38 »
« Last Edit: 25 / July / 2008, 23:01:24 by PhyrePhoX »

 

Related Topics


SimplePortal 2.3.6 © 2008-2014, SimplePortal