Re: 2445A calibration


To be more concrete I've thrown to IDA the 2465a ROM files. 160-3302-09 & 160-3303-09 are the part number downloaded from here:

The code structure is quite interesting. The bank switching routines are in the first 2K RAM working area. I've quickly found the voltage reference setting routine:,,,20,1,20,0

See the comments in the code. The 0xAC=172d code thrown in the DAC sets the reference voltage of 1.36V:
1ma*(4095-172)*4/4096=3831uA. Solving for x=TP2421 voltage:
x*14.2KOhm/13.0KOhm + 681Ohm*(4095-172)*0.004A/4096 = -x
x=(4095-172)*0.004A/4096*681Ohm/(1Ohm+14200Ohm/13000Ohm) = -1.247V

The above assumes that the DAC is calibrated for the 1mA reference current.

Here are some other examples of the DAC and the counter access:,,,20,1,20,0,,,20,1,20,0

The code is complex in structure due to the ugly banking implementation. There are similar sections in all four 32K ROM pages. DAC is accessed all over the place in byte fashion and also by direct 16 bit X or even S register store. The DAC work area in the first 2K of RAM is also used heavily and many locations are duplicated.

If completely stuck, then I'll try tracing the LIMIT error, but looking just at the ADC routine complexity (uses almost 200 bytes of various runtime data to do the conditional branching) likely it will consume all the time for several months...

Join to automatically receive all group messages.