/[projet1]/public/pc/tools/osdk/main/Osdk/_final_/lib2/math.s
Defence Force logotype

Contents of /public/pc/tools/osdk/main/Osdk/_final_/lib2/math.s

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1154 - (show annotations)
Sun Aug 10 18:19:54 2014 UTC (5 years, 6 months ago) by dbug
File size: 1036 byte(s)


1 getfarg1
2 lda sp
3 ldy sp+1
4 jmp load_acc1
5
6 _log jsr getfarg1
7 jmp $DCAF
8
9 _log10 jsr getfarg1
10 jmp $DDD4
11
12 _exp jsr getfarg1
13 jmp $E2AA
14
15 _fabs jsr getfarg1
16 jmp $DF49
17
18 _cos jsr getfarg1
19 jmp $E38B
20
21 _sin jsr getfarg1
22 jmp $E392
23
24 _tan jsr getfarg1
25 jmp $E3DB
26
27 _atn jsr getfarg1
28 jmp $E43F
29
30 _sqrt jsr getfarg1
31 jmp $E22E
32
33 _pow clc
34 lda sp
35 adc #5
36 tax
37 lda sp+1
38 adc #0
39 tay
40 txa
41 jsr load_acc1
42 lda sp
43 ldy sp+1
44 jsr load_acc2
45 jmp $E238
46
47 _modf jsr getfarg1
48 jsr $DFBD ; get integral part
49 ldy #5
50 lda (sp),y
51 tax
52 iny
53 lda (sp),y
54 tay
55 txa
56 jsr store_acc ; store integral part
57 lda sp
58 ldy sp+1
59 jsr load_acc2 ; reload number
60 jmp fsub ; and substract to return fractional part
61
62 _horner lda sp
63 ldy sp+1
64 jsr load_acc1
65 jsr $DEA0
66 ldy #5
67 lda (sp),y
68 sta $D6
69 ldy #7
70 lda (sp),y
71 sta $E0
72 tax
73 iny
74 lda (sp),y
75 sta $E1
76 tay
77 txa
78 jmp $E32A

  ViewVC Help
Powered by ViewVC 1.1.26