RE: FpCal Rom Adr.

2005-01-04 Thread Geoff Winkless
Z80 wrote:
> Hi all,
> 
> I'm having ( for two months now ) a problem regarding SamC rom
> routines. I have some programs which work perfectly on Spectrum and
> I'd like to port them to SamC. The problem is ( ta d ) while for
> Spectrum I have some ROM routines to convert a string to a FpCalc
> format, you know.. the Rst28h thingie ;) ,  ( 5 bytes that is ) for
> SamC I haven't found this routine ( something like basic Val$ I'm
> interested ). I can push some constants ( like 0, pi, 16384 ) but a
> number like 183.28819 .. I really don't know how. If anybody worked
> with it some info or sample asm code would be a dream. Sorry for my
> bad English, and thanks. 
> 
> Zecut0r.

Your english is fine!

A quick web search for the tech manual gives: 

http://sam.speccy.cz/os_tech/sam_coupe_tech-man_v3-0.pdf

Page 35 (page 40 of the pdf) looks like it might be helpful:

JEXPT1NUM (0118H)
Syntax check/evaluate a numeric expression. During syntax checking an
invisible 5-byte form of any literal numbers is inserted. During run time
the result of the expression is left on the floating point calculator stack.

JEXPTSTR (0116H)
Syntax check/evaluate a string expression. See JEXPT1NUM.

JEXPTEXPR (0llEH)
Syntax check/evaluate an expression. See JEXPT1NUM. 
These three routines can be useful in extending the Basic interpreter.

HTH

Geoff


__
This email has been scanned by the MessageLabs Email Security System.
For more information please visit http://www.messagelabs.com/email 
__


RE: FpCal Rom Adr.

2005-01-04 Thread Geoff Winkless
Z80 wrote:
> Hi all,
> 
> I'm having ( for two months now ) a problem regarding SamC rom
> routines. I have some programs which work perfectly on Spectrum and
> I'd like to port them to SamC. The problem is ( ta d ) while for
> Spectrum I have some ROM routines to convert a string to a FpCalc
> format, you know.. the Rst28h thingie ;) ,  ( 5 bytes that is ) for
> SamC I haven't found this routine ( something like basic Val$ I'm
> interested ). I can push some constants ( like 0, pi, 16384 ) but a
> number like 183.28819 .. I really don't know how. If anybody worked
> with it some info or sample asm code would be a dream. Sorry for my
> bad English, and thanks. 
> 
> Zecut0r.

Your english is fine!

A quick web search for the tech manual gives: 

http://sam.speccy.cz/os_tech/sam_coupe_tech-man_v3-0.pdf

Page 35 (page 40 of the pdf) looks like it might be helpful:

JEXPT1NUM (0118H)
Syntax check/evaluate a numeric expression. During syntax checking an
invisible 5-byte form of any literal numbers is inserted. During run time
the result of the expression is left on the floating point calculator stack.

JEXPTSTR (0116H)
Syntax check/evaluate a string expression. See JEXPT1NUM.

JEXPTEXPR (0llEH)
Syntax check/evaluate an expression. See JEXPT1NUM. 
These three routines can be useful in extending the Basic interpreter.

HTH

Geoff


__
This email has been scanned by the MessageLabs Email Security System.
For more information please visit http://www.messagelabs.com/email 
__


RE: FpCal Rom Adr.

2005-01-04 Thread Z80

Thank you, I'll try this right away .

Zecut0r .

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On
Behalf Of Geoff Winkless
Sent: 04 January 2005 14:34
To: sam-users@nvg.ntnu.no
Subject: RE: FpCal Rom Adr.

Z80 wrote:
> Hi all,
> 
> I'm having ( for two months now ) a problem regarding SamC rom
> routines. I have some programs which work perfectly on Spectrum and
> I'd like to port them to SamC. The problem is ( ta d ) while for
> Spectrum I have some ROM routines to convert a string to a FpCalc
> format, you know.. the Rst28h thingie ;) ,  ( 5 bytes that is ) for
> SamC I haven't found this routine ( something like basic Val$ I'm
> interested ). I can push some constants ( like 0, pi, 16384 ) but a
> number like 183.28819 .. I really don't know how. If anybody worked
> with it some info or sample asm code would be a dream. Sorry for my
> bad English, and thanks. 
> 
> Zecut0r.

Your english is fine!

A quick web search for the tech manual gives: 

http://sam.speccy.cz/os_tech/sam_coupe_tech-man_v3-0.pdf

Page 35 (page 40 of the pdf) looks like it might be helpful:

JEXPT1NUM (0118H)
Syntax check/evaluate a numeric expression. During syntax checking an
invisible 5-byte form of any literal numbers is inserted. During run time
the result of the expression is left on the floating point calculator stack.

JEXPTSTR (0116H)
Syntax check/evaluate a string expression. See JEXPT1NUM.

JEXPTEXPR (0llEH)
Syntax check/evaluate an expression. See JEXPT1NUM. 
These three routines can be useful in extending the Basic interpreter.

HTH

Geoff


__
This email has been scanned by the MessageLabs Email Security System.
For more information please visit http://www.messagelabs.com/email 
__



RE: FpCal Rom Adr.

2005-01-04 Thread Z80

Thank you, I'll try this right away .

Zecut0r .

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On
Behalf Of Geoff Winkless
Sent: 04 January 2005 14:34
To: sam-users@nvg.ntnu.no
Subject: RE: FpCal Rom Adr.

Z80 wrote:
> Hi all,
> 
> I'm having ( for two months now ) a problem regarding SamC rom
> routines. I have some programs which work perfectly on Spectrum and
> I'd like to port them to SamC. The problem is ( ta d ) while for
> Spectrum I have some ROM routines to convert a string to a FpCalc
> format, you know.. the Rst28h thingie ;) ,  ( 5 bytes that is ) for
> SamC I haven't found this routine ( something like basic Val$ I'm
> interested ). I can push some constants ( like 0, pi, 16384 ) but a
> number like 183.28819 .. I really don't know how. If anybody worked
> with it some info or sample asm code would be a dream. Sorry for my
> bad English, and thanks. 
> 
> Zecut0r.

Your english is fine!

A quick web search for the tech manual gives: 

http://sam.speccy.cz/os_tech/sam_coupe_tech-man_v3-0.pdf

Page 35 (page 40 of the pdf) looks like it might be helpful:

JEXPT1NUM (0118H)
Syntax check/evaluate a numeric expression. During syntax checking an
invisible 5-byte form of any literal numbers is inserted. During run time
the result of the expression is left on the floating point calculator stack.

JEXPTSTR (0116H)
Syntax check/evaluate a string expression. See JEXPT1NUM.

JEXPTEXPR (0llEH)
Syntax check/evaluate an expression. See JEXPT1NUM. 
These three routines can be useful in extending the Basic interpreter.

HTH

Geoff


__
This email has been scanned by the MessageLabs Email Security System.
For more information please visit http://www.messagelabs.com/email 
__


Re: FpCal Rom Adr.

2005-01-11 Thread Edwin Blink

From: Z80 <[EMAIL PROTECTED]>

> I'm having ( for two months now ) a problem regarding SamC rom routines. I
> have some programs which work perfectly on Spectrum and I'd like to port
> them to SamC.

I think it should be something like below but somehow it doesn't work.
Can't use simcoupes debugger too to find out what excactly goes wrong since
my
mini keyboard misses some keys :-(

ld a,strpage
ld de,stringptr ;>32768
ld bc,strlen
call &0127 ;stackstore

RST &28 ;start FPC
DB &54 ;val
db &33 ;end FPC or use db&34 end FPC and RET

;FPC value on stack

Edwin