Search found 383 matches

by at67
Today, 14:29
Forum: Hardware and software hacking
Topic: gtBASIC
Replies: 141
Views: 25954

Re: gtBASIC

If you'd like to be able to use tabs in the current compiler, then you can add the following two patches to expression.cpp Patch 1: change 1047-1053 from: while(*str && (*str != c || (numQuotes & 1) || numBrackets)) { if(*str == '"' && (str == begin || (str > begin &&...
by at67
Today, 13:36
Forum: Hardware and software hacking
Topic: gtBASIC
Replies: 141
Views: 25954

Re: gtBASIC

You've found another bug in the parser, you have \t, (i.e. real tabs as whitespace), the parser expects spaces as all my editors expand \t to spaces.

I'll fix that for the next release, for now either replace your tabs with spaces or set your editor to do it automatically.
by at67
Today, 06:39
Forum: Hardware and software hacking
Topic: Is it possible a floppy disk by Arduino on Gigatron?
Replies: 2
Views: 32

Re: Is it possible a floppy disk by Arduino on Gigatron?

You would pretty much have to duplicate what Norgate did with Pluggy Reloaded and his SD Card reader, as you surmised Arduino's run out of storage very quickly when using external libraries, i.e. I doubt you could fit the SD and floppy libraries in a typical device.
by at67
Today, 00:18
Forum: Hardware and software hacking
Topic: gtBASIC
Replies: 141
Views: 25954

Re: gtBASIC

Here's a slightly better example: _runtimePath_ "../runtime" _runtimeStart_ &h7FFF _codeRomType_ ROMv1 sndVolAddr = &h01FA ' channel 1, (out of 1 to 4) sndWaveAddr = &h01FB ' channel 1, (out of 1 to 4) sndFreqAddr = &h01FC ' channel 1, (out of 1 to 4) sndVol = 64 ' 127 to 6...
by at67
Yesterday, 23:18
Forum: Hardware and software hacking
Topic: gtBASIC
Replies: 141
Views: 25954

Re: gtBASIC

Change all the semi-colons to single quotes, it's a parsing bug in your version of the compiler, I just tested this and it works: _runtimePath_ "../runtime" _runtimeStart_ &h7FFF _codeRomType_ ROMv3 repeat POKE &h2C, 255 gosub ENGINESOUND_FX forever ' less accurate frequency versio...
by at67
Yesterday, 22:40
Forum: Hardware and software hacking
Topic: gtBASIC
Replies: 141
Views: 25954

Re: gtBASIC

There's a few things wrong with your code: 1) Equates and labels have to start in the first column of the line otherwise they will be interpreted as opcodes, (that's why your equates are giving that error message). 2) The registerX equates are defined in gigatron.i, but you don't want to use the gtB...
by at67
Yesterday, 10:49
Forum: Hardware and software hacking
Topic: gtBASIC
Replies: 141
Views: 25954

Re: gtBASIC

It doesn't work like that, it's more complicated :/ - Ignore xxFE and xxFF they are free running timers used by the audio subsytem. - Frequency is a 15bit value, high byte into xxFD, low byte, (7bits shifted right once), into xxFC, xx = 01 to 04 for channel 1 to 4. If you want to skip the shift righ...
by at67
16 Sep 2021, 09:58
Forum: Hardware and software hacking
Topic: gtBASIC
Replies: 141
Views: 25954

Re: gtBASIC

Edit keywords.cpp on line 6190 and change the if 0 to if 1 #if 0 <-- change this to 1 // TODO: Fix this // (256 - n) = vblank interrupt frequency, where n = 1 to 255 Compiler::emitVcpuAsm("LDWI", "realTS_rti + 2", false); Compiler::emitVcpuAsm("STW", "register0&quo...
by at67
14 Sep 2021, 17:19
Forum: Hardware and software hacking
Topic: gtBASIC
Replies: 141
Views: 25954

Re: gtBASIC

GET • GET is a function that accepts a string literal describing a system variable to get and an optional number of parameters used by that system variable. • System variable’s available for get. bs = GET(“BUTTON_STATE”) ‘ returns the current BUTTON_STATE register, &h00 >= bs <= &hFF cm = GE...
by at67
13 Sep 2021, 12:59
Forum: Hardware and software hacking
Topic: gfxbrot.c and gfxjulia.c
Replies: 8
Views: 207

Re: gfxbrot.c and gfxjulia.c

I think using less colors and iterations this could be made faster plus in code there might be something to optimize. Maybe a grey scale version? What color numbers those might be? Iterations will help with speed but will lose fidelity on the boundaries, (the interesting bits), I use 16 iterations ...