Jump to content

dmsc

Members
  • Content Count

    800
  • Joined

  • Last visited

  • Days Won

    1

dmsc last won the day on July 14 2017

dmsc had the most liked content!

Community Reputation

1,339 Excellent

5 Followers

About dmsc

Profile Information

  • Gender
    Male
  • Location
    Viña del Mar, Chile

Recent Profile Visitors

8,663 profile views
  1. Hi! Thanks! Current player stores a bit mask at the beginning representing pokey registers 1 to 8 (AUDC1 to AUDCTL), so any of those can be skipped. This could be easily be modified to add a new register, but the problem is that SKCTL is register number 15, this means that we must skip from 15 to 8 in the player loop. About timing writes, I think that you only need to time the writing of SKCTL up to the write of the first "special" AUDF*, as this affects the phase from the poly counter to the frequency generation. Afterwards, when not writing 0 to AUDF* all the timing should be correct - as the frequency changes only occur after the counters are reloaded. What I'm saying is: if you are using values for AUDF* that are multiples of the poly counter period, you will keep at the same phase even when changing the AUDF* value to another multiple, the timing of the AUDF* write is not important as the frequency change will be aligned. Have Fun!
  2. Hi! Oh, that's a nuisance. I use pandoc in the reverse direction: I wrote the manual for Fastbasic in markdown but in 40 columns, so it can be rendered in the Atari screen easily - I just replace the `CODE` blocks with inverse video using an awk script. And by using a template, the PDF output is quite good, even with syntax coloring for the BASIC samples: Original Version: https://raw.githubusercontent.com/dmsc/fastbasic/master/manual.md Output PDF: https://github.com/dmsc/fastbasic/releases/download/v4.4/fastbasic-v4.4-manual.pdf Perhaps you could convert it once, manually editing the bad parts and then use pandoc to go to the ODT format again - pandoc can use an existing ODT as a base, extracting the styles and replacing only the text. Have Fun!
  3. Hi! Strange, must be some default option. Here this works: Perhaps some default option is set differently. I'm using pandoc version 2.9.2.1, with the command line: pandoc doctst.odt -o test.md Reading the manual, you can try with: pandoc doctst.odt -t markdown+grid_tables-simple_tables-pipe_tables-raw_html -o test.md This disables "simple tables" and activates the "grid tables". Have Fun!
  4. Hi! Use pandoc: https://pandoc.org/ , it converts between hundred of different text formats. In your case, you can convert to Markdown (.md) or RestructuredText (.rst), see which looks better to you: pandoc mydocument.odt -o mydocument.md pandoc mydocument.odt -o mydocument.rst The beauty of pandoc is that you can convert from Markdown of RST to HTML, PDF or ODT again, and you can use a template to provide styles and formating. Have Fun!
  5. Hi! This is really great! You should upgrade the basicParser, I just fixed the parsing of "TIME$" as argument to PRINT: https://github.com/dmsc/tbxl-parser/commit/1c62f5073ac0fa5c6ff255ffc9a9f4f601fb47f2 Have Fun!
  6. Hi! Finally I released the new FastBasic version, with all the improvements from the last beta version and a few more fixes. From the github release text: Changes in the IDE: BREAK key handling in the IDE - this was long overdue, now you can press BREAK key to return to the IDE from your program. COPY/PASTE of lines to the editor, you need to press CONTROL-C to make a line to copy, then when you press CONTROL-V that line is copied after the current one. Pressing CONTROL-V multiple times copies multiple lines. This needed a change from CONTROL-V to CONTROL-I for the page-down action. Go to Line, pressing CONTROL-G moves the cursor to any given line, this makes editing larger programs easier. Allows usage of the page-up and page-down keys on the 1200XL keyboard (SHIFT-F1 and SHIFT-F2), in addition to CONTROL-U and CONTROL-I. Changes to the language: Adds CLR statement, that un-dimension arrays and sets all variables to 0. Adds WSYNC command to the DLI, allows setting multiple lines in one DLI. Adds & operator for abbreviating the ADR() function. Allows abbreviations for some BASIC functions and operators and skipping the parenthesis on most functions, allowing to write shorter code, see the manual for details. Minor incompatible change: The abbreviations for ELSE, ENDIF, PMGRAPHICS and PMHPOS changed to make them more consistent and smaller. Changes to the cross-compiler: Allows to compile to code that can be put in a cartridge - by removing all uses of self-modifying-code and adding a stub to copy the zeropage interpreter from ROM to RAM at startup. Allows accessing to DATA's from external assembly files. Adds a DATA FILE statement that includes binary data from external files. The CC65 tools are included in the distribution, you don't need to install CC65 to use the cross-compiler anymore. The new release is over github, download at: https://github.com/dmsc/fastbasic/releases/tag/v4.4
  7. It is relatively easy, using P/M collision registers: GRAPHICS 0 PMGRAPHICS 2 ? "X" POKE 623, 64 PAUSE 0 SETCOLOR -4,4,10 PMHPOS 0, 100 MSET PMADR(0) + 16, 16, 255 POKE $D01E, 1 PAUSE 0 CHK = PEEK($D004) PAUSE 0 POKE $D01E, 1 PAUSE 0 PMHPOS 0, 54 PAUSE 0 TEST = PEEK($D004) PAUSE 0 PMHPOS 0, 100 POKE 623, 0 GR.0 IF CHK ? "CHECK ERROR!" ENDIF IF TEST = 4 ? "CTIA" ELIF TEST = 0 ? "GTIA" ELSE ? "ERROR!" ENDIF REPEAT: UNTIL KEY() Have Fun!
  8. Hi! The problem is that the code waits for all the console keys to be released before jumping to the cold start vector. Then, you have exactly 81 scan-lines (so, about 5.1ms) to press OPTION again, and that is not physically possible! The last 4 instructions implement the logic to wait for the console keys to be released: 27D5: AC 1F D0 LDY $D01F ;CONSOL 27D8: A5 80 LDA $80 ;LOMEM 27DA: C9 01 CMP #$01 27DC: D0 08 BNE $27E6 27DE: C0 06 CPY #$06 27E0: F0 0B BEQ $27ED 27E2: C0 05 CPY #$05 27E4: F0 11 BEQ $27F7 27E6: C0 06 CPY #$06 27E8: F0 03 BEQ $27ED 27EA: 4C 06 28 JMP $2806 27ED: AD 1F D0 LDA $D01F ;CONSOL 27F0: C9 07 CMP #$07 27F2: D0 F9 BNE $27ED 27F4: 4C 77 E4 JMP $E477 ;COLDSV Have Fun!
  9. Hi! That won't work, as Altirra does not know how to re-disable BASIC. What the emulator does is simply to fake the pressing of OPTION key on bootup. After that, the emulator behaves just like a standard machine. Have Fun!
  10. Hi! The idea is simple: use the COLRSH O.S. variable to count the current line, so that each DLI is: DLI: ' Save Registers PHA TXA PHA ' Read current counter and sync LDX COLRSH STX WSYNC ' Read from table and store color LDA table,X STA COLBK ' Increment counter for next DLI INC COLRSH ' Exit DLI PLA TAX PLA RTI The standard OS will clear COLRSH to 0 on each vertical blank, even when the critical flag is set, whenever the attract mode is skipped. Have Fun!
  11. Hi! See the code at https://github.com/dmsc/turbo-dis/blob/master/turbo-mads.asm Basically, you have the loader first (not used after load is finished): - Loader font: $5C00 to $5FFF - Splash screen code: $2100 to $2193 - RAM under ROM Loader: $6000 to $617F And the code: - Low code: $2080 to $3628 - Interpreter stack: $2100 to $21FF - FP temporaries: $22CA to $22FF - High code 1: $C000 to $CBF5 - High code 2: $D800 to $DFF9 - High code 3: $E400 to $FFFF As always, the interpreter uses memory from $3629 upwards to store the BASIC program, and $580 as the input buffer. Have Fun!
  12. Hi! Yes, now you can write code like this: P.D.88,P.D.88+1 Or this full program: DO:F.X=D.88TOD.88+39:P.X,P.X+1:N.:L. Good luck deciphering the meanings
  13. Hi! Privately I also proposed to change it to "DOWN" or "ROW", so it reads better, the options could be: "DLI x = $10 INTO $D01A, $14 NEXT INTO $D01A, $18 NEXT INTO $D01A" "DLI x = $10 INTO $D01A, $14 DOWN INTO $D01A, $18 DOWN INTO $D01A" "DLI x = $10 INTO $D01A, $14 ROW INTO $D01A, $18 ROW INTO $D01A" "DLI x = $10 INTO $D01A, $14 SYNC INTO $D01A, $18 SYNC INTO $D01A" "DLI x = $10 INTO $D01A, $14 WAIT INTO $D01A, $18 WAIT INTO $D01A" What do you prefer? Have Fun!
  14. Hi! There is an option: I can implement abbreviation of "ADR", by changing the parser to only skips letters or numbers after a dot. But this will mean that you would need to abbreviate "ERR()" as "E.()" and "KEY()" as "K.()". That would also mean that I could abbreviate string functions conserving the $ at the end, for example, "CHR$" to "C.$" Would that be a better solution? Have Fun!
  15. Hi! Added the function abbreviations and the optional parentheses. New in this beta release: - Adds CONTROL-G to the IDE go to a specific line in the file. - Recognize Shift-F1 and Shift-F2 (1200XL keys) as page-up and page-down. This also works on most emulators. - Adds a "NEXT" word to the DLI to write to WSYNC, advancing to the next screen line before writing the registers. (use like " DLI tst = $80 INTO $D01A, $86 NEXT INTO $D01A, $8A NEXT INTO $D01A, $8E NEXT INTO $D01A" - Allows to skip parentheses in functions accepting one value, like "A = PEEK 123" or "? CHR$ 65" - Allows function abbreviations, using the table provided by @vitoco. Please, test this beta version - specially the abbreviations, as I would like to release version 4.4 next weekend. The integer IDE is exactly 8192 bytes, after a lot of optimizations I could make it fit in 8kB again Have Fun! fastbasic-manual-4.4-beta.pdf fastbasic-v4.4-beta-18-g7c637a4.atr fastbasic-v4.4-beta-18-g7c637a4-win32.zip fastbasic-v4.4-beta-18-g7c637a4-linux64.zip
×
×
  • Create New...