SuperH-based fx calculators
fx legacy Setup

Setup (also 'SETUP') is character array used by the calculator to store application-wide settings. It has space for 100 entries.
A limited setup editor can be accessed through the "SET UP" key in certain applications, but a global one can also be accessed using TestMode (keycombination or syscall) -> Font/lang check -> SETUP. The fx CG Setup is similar.


Default values are the ones listed first in the Values field. Entries marked * are not found in the global Setup editor.

No. Name/description Values
0x13 Angle 00:Degrees, 01:Radians, 02:Gradians
0x14 * SHIFT/ALPHA status 00:SHIFT and ALPHA off, 01:SHIFT on, 04:ALPHA on, 0x84:SHIFT and ALPHA on.
0x15 * INS/OVWR status 02:Insert, 01:Overwrite
0x17 Mode 00:Comp, 09:Dec, 0x0F:Hex, 01:Bin, 07:Oct
0x18 Func Type 00:Y=, 01:r=, 02:Param, 03:X=c, 04:Y>, 05:Y<, 06:Y>=, 07:Y<=
0x19 Draw Type 00:Con, 01:Plot
0x1A Derivative 01:Off, 00:On
0x1B Coord 00:On, 01:Off
0x1C Grid 01:Off, 00:On
0x1D Axes 00:On, 01:Off
0x1E Label 01:Off, 00:On
0x20 Stat Wind 00:Auto, 01:Manual
0x21 Graph Func 00:On, 01:Off
0x22 Dual Screen 03:Off, only option?
0x23 Simul Graph 01:Off, 00:On
0x24 Dynamic Type 01:Stop, 00:Cont
0x25 SigmaDisplay (Σ Display) 01:Off, 00:On
0x26 Slope 01:Off, 00:On
0x27 Payment 01:End, 00:Bgn
0x28 Date Mode 00:365, 01:360
0x29 Answer Type 00:Real 01:Complex
0x2A Complex Mode 00:Real, 01:a+bi, 02:r<T
0x2B Display 00:Norm1, 0x10:Norm2, 0x20..0x29:Fix0..Fix9, 0x30..0x39:Sci0...Sci9 (Bit 0x80 toggles /E-mode)
0x2C Background 00:None, 01...0x14:Pict1...Pict20
0x2D Resid List 00:None, 01...0x1A:List1...List26
0x2E List File 01..06:File1...File6
0x2F Variable 00:Range, 01...26:List1...List26
0x30 * Recur Type not checked
0x31 Recur Dual (Dual Screen) 01:Off, 00:T+G
0x4E Auto Calc 00:On, 01:Off
0x4F Show Sell (Show cell) 00:Formula, 01:Value
0x50 Move 00:Lower, 01:Right
0x51 Sub Name 00:On, 01:Off
0x53 Input Mode 01:Linear, 00:Math
0x54 Locus 01:Off, 00:On
0x55 Y=Draw Speed 00:Norm, 01:High
0x56 Sketch Line 00:Norm, 01:Thick, 02:Broken, 03:Dot
0x57 Frac Result 00:d/c, 01:a+b/c
0x5C Q1Q3 Type 00:Std; 01:OnD [STAT]
0x5D Ineq Type 00:Intersect (And); 01:Union (Or) [GRAPH]
0x5E Periods/Yr. 00:Annu; 01:Semi [TVM]
0x5F Simplify 00:Auto; 01:Manual (OS 2.02)


0x3DC: int Setup_GetInfo(unsigned char*P1, int P2, TSetupInfo*P3);

This call seems to be the single possibility to read the size of the setup-area.

P1 and P2 are ignored on the legacy systems (contrary to fx CG).

P3 is a pointer to a struct like:

struct {
        unsigned char Name1[13];    // will be set to "SETUP.g1m" on return
        unsigned char Name2[9];    // will be set to "$GLOBAL" on return
        unsigned char Name3[10];    // will be set to "SETUP" on return
        unsigned int LengthOfSetup;
        unsigned short unknown; // 0x8038
    } TSetupInfo;   

0x4DC: char Setup_GetEntry(unsigned int index);

Returns the value at the given index. Only indexes in range 0..99 access valid entries, but no checking is done.

0x4DD: char *Setup_SetEntry(unsigned int index, char setting);

Sets the entry at the given index to the provided setting. Only indexes in range 0..99 access valid entries, but no checking is done.
Will return a pointer to the base of the Setup table.

0x4DE: char *Setup_GetEntryPtr(unsigned int index);

Returns a pointer to the actual data in the setup table (tableaddress+index).


(06.10.2012 15:42:03)