• Home
  • Script library
  • AltME Archive
  • Mailing list
  • Articles Index
  • Site search
 

AltME groups: search

Help · search scripts · search articles · search mailing list

results summary

worldhits
r4wp0
r3wp30
total:30

results window for this page: [start: 1 end: 30]

world-name: r3wp

Group: Core ... Discuss core issues [web-public]
Pavel:
14-Dec-2009
Transfering memory based hash! (map! in R3) datatype into disk based 
shema automatically keeping the hash table computation and lookup 
hidden from user gives you a RIF. Holly grail of all rebollers :) 
long long time promissed, still waiting to be done. Anyway hash tables 
are always usually unsorted, when necessary to search in usually 
some type of additional index is used (B-tree for example), for simple 
information if the key is in the set, bitmap vectors are used with 
advantage, when the set is really big (and bitmap vector doesn fit 
into memory) comressed bitmap may be used and usually bitwise operations 
on those vectors are much quicker than on uncompressed. 

Thisi is why it should be used for bitset! datatype anyway. The number 
of byte aligned (BBC,Packbit,RLE)od word aligned (WAH) schemes exists. 
 It is used in very large datasets when index also resides in disk 
file. Once again bitwise operation may be much quickier even in memory 
on those schemes.
Group: Parse ... Discussion of PARSE dialect [web-public]
Brock:
27-Jun-2007
>> parse "BBC" [[rule] [rule] [rule]]
== false
Chris:
28-Jun-2007
Basically you're asking for [all ["A" | "B" | "C"]] -->
ABC
 = true
BAC
 = true
BBC
 = false
ABCB
 = false
Steeve:
28-Jun-2007
Once (again)

Rebol is amazing, i think i found a simple and elegant dialect

Currently, it's not allowing recursive once usage, but it's obvious 
to do with a stack.


take: func [r] [n: 0 once/1: (length? r) + 1 / 3 once/2/2: r replace/all 
r '.. '.]
.: [(n: n + 1)]
..: [(n: n + 1) end skip]
once: [0 [(if n > 0 [poke once/2/2 n - 1 * 3 + 1  '..] n: 0) []]]


rule: [. "a" | . "b" | . "c"]
parse "CBA" [ (take rule) once]
== true
parse  "BAC" [ (take rule) once]
== true
parse  "CBA" [ (take rule) once]
== true
parse  "BBC" [ (take rule) once]
== true
parse  "CA" [ (take rule) once]
== false
parse  "CABA"[ (take rule) once]
== false
rule2: [. "a" | . "a" | . "b" | . "c"]
parse "CABA"[ (take rule2) once]
== true
Steeve:
28-Jun-2007
(correction) 
>>parse "BBC" [(take rule) once]
== false
Geomol:
4-Feb-2008
I'm not really sure. First I do a general 6502 assembler and emulator, 
but I only have an emulator of the BBC homecomputer to test up against, 
so I probably have to deal with some Operating System stuff too. 
I operate with a 64k address space, and on the BBC writing to some 
certain addresses made something special for that platform happen. 
But let's see, what we can do.
Geomol:
6-Feb-2008
Yes! :)
From http://www.bbcmicrogames.com/acornsoft.html

It has been ported to just about every other platform out there however, 
it appeared first on the BBC.

The BBC had a 6502 too, and it's the platform, I'm testing up against, 
so let's hope, it all work out well.
Geomol:
8-Feb-2008
Robert, there's no emulator written in REBOL, that can run Elite, 
afaik. But there are emulators emulating the BBC computer, if that's 
what you mean, and they can run Elite. I use an emulator called BeebEm3.
Group: Dialects ... Questions about how to create dialects [web-public]
Geomol:
24-Jun-2007
I use this guide as a base for the BASIC interpreter: http://www.nvg.ntnu.no/bbc/doc/BBCUserGuide-1.00.pdf
I found it on this site: http://www.nvg.ntnu.no/bbc/docs.php3
Geomol:
24-Jun-2007
I choosed that one, because I once owned a BBC Micro. I have no idea, 
how far that is from QBasic. But I guess Basic is Basic. They probably 
differ in stuff like graphics and sound.
Geomol:
17-Jul-2007
The start of a BBC BASIC interpreter using string parsing: http://www.fys.ku.dk/~niclasen/rebol/bbcbasic.r
Geomol:
18-Jul-2007
Uploaded new version of BBC BASIC intepreter. Added expressions and 
conditions. Added IF and INPUT. Example:

>> do http://www.fys.ku.dk/~niclasen/rebol/bbcbasic.r
connecting to: www.fys.ku.dk
Script: "BBC BASIC" (18-Jul-2007)
BASIC v. 0.0.2 

>auto
   10 input "Name",name$

   20 if name$="Carl" then print "Hi " name$ else print "Hello " name$
   30 0
>run
Name?John
Hello John
Geomol:
18-Jul-2007
New version 0.1.0 of BBC BASIC. Added FOR ... NEXT loop. Example:

>> do http://www.fys.ku.dk/~niclasen/rebol/bbcbasic.r
connecting to: www.fys.ku.dk
Script: "BBC BASIC" (19-Jul-2007)
BASIC v. 0.1.0 

>auto
   10 for a=10 to pi step -2.3
   20 for n%=1 to 3 step 2
   30 print a n%
   40 next
   50 next
   60 0
>run
                  10                   1
                  10                   3
                 7.7                   1
                 7.7                   3
                 5.4                   1
                 5.4                   3
Geomol:
19-Jul-2007
A modern BASIC should maybe be able to recognize both lower an UPPER 
case, like in my examples. The original BBC BASIC distinguish between 
upper and lower case. I should change my interpreter to work this 
way, so already written programs will work.
Geomol:
19-Jul-2007
New version 0.1.1 of BBC BASIC. Added many keywords, mostly functions. 
To run:
>> do http://www.fys.ku.dk/~niclasen/rebol/bbcbasic.r

List of keywords: http://www.fys.ku.dk/~niclasen/rebol/bbcbasic.html
Geomol:
22-Jul-2007
Version 0.2.0 of BBC BASIC uploaded. Added DATA, READ and RESTORE. 
Added GOSUB and RETURN. Added hex notation, made some changes and 
fixed bugs.
Geomol:
22-Jul-2007
This is meant as an implementation of BBC BASIC originally found 
on the BBC Micro from british Acorn. It's not an emulator of that 
computer. For emulation of the BBC Micro, I recommend BeebEm.
Geomol:
22-Jul-2007
The BBC BASIC interpreter is now more than 800 lines of REBOL source 
(or 20278 bytes). It's 4568 bytes compressed.
Geomol:
22-Jul-2007
In the early 80'ies, before the era of PCs, the Amiga, Mac and Linux, 
there were a whole range of home computers more or less expensive 
(the BBC Micro were in the high price range back then). They all 
came with some version of the BASIC language. It was also possible 
to program in assembler (the BBC had a 6502 CPU). Imagine a new homecomputer 
with REBOL and rebcode. And many other languages supported as REBOL 
dialects. It should just have a keyboard, network, some RAM and maybe 
a memory stick instead of a harddisk. And connection to a monitor. 
That shouldn't be too costly to produce. Would it sell if the price 
was right?
Geomol:
24-Jul-2007
Version 0.3.0 of BBC BASIC uploaded. Added the rest of the string 
handling: LEFT$, MID$, RIGHT$, STRING$ and INSTR. Added ON, that 
can change the order of execution. Added DIM, which implement arrays. 
Both for integers, reals and strings. To run:
>> do http://www.fys.ku.dk/~niclasen/rebol/bbcbasic.r

List of keywords: http://www.fys.ku.dk/~niclasen/rebol/bbcbasic.html
Geomol:
27-Jul-2007
BBC BASIC v. 0.4.0 uploaded. Added procedures and local variables 
(DEF PROC, ENDPROC and LOCAL). Added TIME, RND and EVAL. Added better 
error handling. Next thing will be functions, but I'll test procedures 
some more first. The implementation is based on this user guide: 
http://www.nvg.ntnu.no/bbc/doc/BBCUserGuide-1.00.pdf
Geomol:
27-Jul-2007
Example use of local variables. In line 70, 'a' is local, because 
it's a parameter to the procedure, 'b' is still global. After line 
80, 'b' also become local to the procedure. After returning from 
the procedure, both 'a' and 'b' are set back to their global values. 
In 'proctest', 'a' could have been called anything without changing 
the global 'a'.

>> do http://www.fys.ku.dk/~niclasen/rebol/bbcbasic.html
Script: "BBC BASIC" (27-Jul-2007)
BASIC v. 0.4.0 

>auto
   10 a=42
   20 b=1
   30 proctest(a)
   40 print "line 40 : a=";a " b=";b
   50 end
   60 def proctest(a)
   70 print "line 70 : a=";a " b=";b
   80 local b
   90 a=2:b=2
  100 print "line 100: a=";a " b=";b
  110 endproc
  120 0
>50end
>run
line 70 : a=        42 b=         1
line 100: a=         2 b=         2
line 40 : a=        42 b=         1
Geomol:
29-Jul-2007
So far, I've allowed keywords to be either UPPER- or lower-case. 
I think, I have to restrict them to UPPER-case like in traditional 
BASIC. Problem is with variable names being assigned by the LET statement. 
If I define a variable "length":
LET length=10

and then use it in some expression, the first part of the variable 
name is being recognized as the LEN function. In the original BBC 
BASIC, the above LET statement is ok, while you can't write:
LET LENGTH=10

, which will give a syntax error. I conclude, I have to restrict 
keywords to UPPER-case and then check, when the variables are being 
defined, so their names don't collide with keywords.
Geomol:
30-Jul-2007
It's rather difficult to implement functions (user functions, which 
the BBC BASIC language support), with the implementing method, I've 
choosed. Problem is, that the return point need to be saved, while 
the function code is running. The problem is the same with statements 
like GOSUB and PROC (procedures), but so far, I've just put some 
restrictions on those. In this basic, more than one statement can 
be on each line, if they're separated by colons, ':'. The way it's 
implemented, this example give a syntax error:
GOSUB 100:PRINT "I'm back"

My implementation require, that the return point is the next line. 
That isn't good enough with functions, because they're used in the 
middle of other statements. Examples:

PRINT FNone_function, FNanother_function
IF FNmyfunc=42 THEN PRINT "It's 42!"


The return point for those need to be in the middle of a statement, 
in the middle of a line. So I'm at a point, where I consider another 
implementation of all the statements (more like a real emulation 
of the BBC computer) or if I just should say "the heck with it" and 
move on to some other language or another version of a new BASIC 
language.
Group: Hardware ... Computer Hardware Issues [web-public]
Geomol:
13-Feb-2012
I don't understand, why Ctrl is moved down on modern keyboards. I 
always switch Ctrl and Caps Lock, because I use Ctrl a lot and don't 
like my hand twisted. It's much better to have Ctrl on the same line 
as A, S, D, F ..., like on the keyboards, I used a lot in the past 
(Acorn BBC, Amiga, Wyse terminals). I'm currious, what users modern 
keyboards are friendly for, they're not programmer friendly for sure.
Group: rebcode ... Rebcode discussion [web-public]
Geomol:
11-Feb-2008
I only did very little test so far. I got around 1.5 MHz. The cpu 
(actually a 6512, it seems buth with 6502 instructions) in the BBC 
was 1MHz.
Geomol:
11-Feb-2008
For 6502 asm documentation, I use the "BBC Advanced User Guide" found 
here: http://www.nvg.ntnu.no/bbc/docs.php3
Geomol:
12-Feb-2008
A performance test program:

lda #0
sta &1001
.l1
lda #0
sta &1002
.l2
lda #0
sta &1003
.l3
lda &1003
adc #1
sta &1003
lda &1003
bne l3
lda &1002
adc #1
sta &1002
lda &1002
bne l2
lda &1001
adc #1
sta &1001
lda &1001
bne l1


It takes 40s to run on a BBC emulator emulating a 1MHz 6502. It took 
around 14s using the rebcode emulator on my 1.2 GHz G4, and it took 
9.5s using the rebcode emulator on my 2.4GHz Pentium 4.
Group: Tech News ... Interesting technology [web-public]
Jerry:
6-Sep-2007
http://www.bbcbasic.co.uk/bbcwin/bbcwin.html
BBC Basic for Windows
 is tiny and powerful.
Jerry:
7-Sep-2007
btiffin, the point is not the BASIC language. it's the compiler.
Most of the applications developed in BBC Basic for Windows is 
under 100 KB. Only one EXE, no DLLs needed.