Go to Post He is just one of the dozens of evil minions I have molded into my image over the years. Be afraid world, be very afraid. - Andy Grady [more]
Home
Go Back   Chief Delphi > Technical > Programming
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Closed Thread
 
Thread Tools Rate Thread Display Modes
  #1   Spotlight this post!  
Unread 30-04-2003, 10:23
srawls's Avatar
srawls srawls is offline
Registered User
#0122 (Nasa Knights)
 
Join Date: Dec 2001
Location: Yorktown
Posts: 507
srawls is an unknown quantity at this point
Send a message via AIM to srawls
Quote:
Originally posted by rbayer
The ** op is not exponentiation. It is just muplication, but returns the high-order 16-bits instead of the normal low-order 16. Combined with the normal * op, you can get the full 32-bit result that could come from multiplying two 16-bit numbers. As far as I know, PBASIC doesn't have an exponentiation op.

--Rob
d'oh ... I'm thinking in Perl. Sorry about that. The only sort of exponention op I know of is DCD, which is just 2^n (or 1 << n), where n is the argument. Hmm ... I can pull something out of my failed code ...

Code:
bitVAR = DCD (byteVAR - a) - 1  MAX 1 '!(byteVAR == a)
That just reverses the logic (0 if they are equal, 1 if they are not). I don't know the error handling if DCD's argument is over 15, so the statement may need another MAX. Of course, it's past the realm of usefulness I suppose.

Stephen
Closed Thread


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
BS2 syntax (PBASIC) on the new controllers? Maybe! Jeremy_Mc Programming 0 25-10-2003 15:00
PBASIC Syntax Question Raven_Writer Programming 4 20-08-2003 08:07
Pbasic 2.5 syntax Rickertsen2 Programming 10 15-02-2003 08:56
Another PBASIC Question Ian W. Programming 4 31-01-2002 21:36
Simplifying PBasic IDiggles General Forum 16 06-11-2001 01:36


All times are GMT -5. The time now is 16:13.

The Chief Delphi Forums are sponsored by Innovation First International, Inc.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi