Jump to content

dmsc

Members
  • Posts

    1,162
  • Joined

  • Last visited

  • Days Won

    1

dmsc last won the day on July 14 2017

dmsc had the most liked content!

Profile Information

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

Recent Profile Visitors

10,596 profile views

dmsc's Achievements

Stargunner

Stargunner (7/9)

2k

Reputation

  1. Hi! You did not rewrite the program, only rearranged it a little. Your program is an adaptation of an Atari BASIC 10-liner, from this post: https://workshop88.com/oldblog/index.php/2021/03/21/an-interactive-mandelbrot-set-explorer-in-10-lines-of-atari-basic/ Being a 10-liner, it is written to be as concise as possible, without much regard for speed - but the algorithm is a standard mandelbrot plotter. Try to understand the code and write it again without the NEXTs inside the IFs, and without all the unneeded gotos. Have Fun!
  2. Hi! I think it is already merged there, so, it is also in my branch. Have Fun!
  3. Hi! I have a branch that compiles in my Debian Linux, you need to install liballegro4-dev and libfreeimage-dev before compilation: https://github.com/dmsc/RastaConverter/tree/linux-compile # Install libraries sudo apt install liballegro4-dev libfreeimage-dev g++ make # Clone repo and checkout branch git clone https://github.com/dmsc/RastaConverter cd RastaConverter/ git checkout linux-compile # Compile cd src make Have Fun!
  4. Hi! As @Irgendwer said, I went to that path once - started after adding procedure parameters and other optimizations to my basic parser tool (at https://github.com/dmsc/tbxl-parser ), and ended writing FastBasic instead. There is still a branch in the tbxl-parser repo with some work. FastBasic is designed to be easier to compile (no line numbers) and optimize (having native integer variables), and by having a version that runs in the Atari itself is a great tool for writing ten-liners or other simple games, you can see this years "Chaseme" by Vitoco https://bunsen.itch.io/chase-me-atari-8-bit-by-vitoco , "Tetris" and "Gunner" by Eric Car https://bunsen.itch.io/tetris-atari-8-bit-by-eric-carr https://bunsen.itch.io/gunner-atari-8-bit-by-eric-carr - all are incredible for 10 BASIC lines. Have Fun!
  5. Hi! Here is my MAC/65 file conversion tool: https://github.com/dmsc/m65-lister Also, the attached ATASCII to ASCII converter could be useful - I use it all the time in the command line to list ATASCII files, with the '-e' option it will even use terminal codes to show inverse video. Have Fun! conv-atascii-utf8.c
  6. Hi! This is because the optimizer in the cross-compiler is really dumb, the program is represented as a list of tokens and certain patterns replaced with others. With a three based representation, the optimizer could do much more. Yes, multiplications in the 6502 are slow 😛 If you need to perform floating point operations, it is better to replace the mathpack with a faster one, for example the Altirra mathpack. About a list of tips, I'm not aware of any. Have Fun!
  7. Hi! Problem is windows command line processing: there is no way to pass filenames to a windows command line directly; it does not support the concept of command line "arguments", only of a single command line. I followed the advice of https://learn.microsoft.com/en-us/cpp/c-runtime-library/spawn-wspawn-functions?view=msvc-170#arguments-for-the-spawned-process and enclosed parameters with spaces in double quotes, this seems to work. And released a new beta version, attached is the ATR plus windows and linux cross-compiler, all other version over github: https://github.com/dmsc/fastbasic/releases/tag/v4.7-beta1 Changes from v4.6: Language changes: Adds SIO statement Adds Fujinet support: NOPEN, NCLOSE, NSTATUS and NGET statements, see "nc" and "mastodon" examples. Support ADR for floating point variables. Adds %() function. You can now omit parentheses in string functions, like LEN "X" instead of LEN("X") Fixes: Fixes compiling long DLI statements. Fixes for AND/OR mixing bools and integer operands. Fixes chaining COLOR() and RTAB() in PRINT statements. Cross Compiler: Fixes on Windows cross compiler for filenames with spaces or Unicode characters. Better error messages: show variable names in errors, ASCII art with the error location, shows errors on missing ending of loops or ifs. Have Fun! fastbasic-v4.7-beta1-win32.zip fastbasic-v4.7-beta1.atr fastbasic-v4.7-beta1-linux64.zip
  8. Hi! The definitive guide: https://www.virtualdub.org/downloads/Altirra Hardware Reference Manual.pdf See in section 2.7. "Extended memory", at page 35. Have Fun!
  9. Hi! So, if you boot into BW-DOS and type "MEMEDIT D200", then 50, ENTER, AA, ENTER, do you hear any sound?: What SIO device are you using? Have Fun!
  10. Hi! Yes, you have to use the NE555 pin 7 (discharge) as output, connected to SIO pin 9 with the same 2k2 resistor to pin 8. To use the 555 as a comparator with hysteresis, you tie the NE555 pins 2 and 6, and adjust the hysteresis with a resistor from NE555 pin 5 to ground. And, the same as the other circuit, you adjust the comparator signal with a resistor divider at the input. This is the idea: The 4k7 resistor should be changed depending on the hysteresis needed. Have Fun!
  11. Hi! I suspect it should be much easier to simply use a LM393 and a transistor.... easy to buy in any electronics shop. Or, you can use a 555 chip as the comparator and output transistor with a few resistors to adjust the threshold voltaje. Have Fun!
  12. Hi! Perhaps, but as I don't have an 128k A8, I won't try 😛 Here is a new animation, running in reverse but also moving the floor with respect to the spheres - the original animation moved the floor in the oposite direction as the spheres, and the reflection did not move (as was in the original). You can press OPTION to change between 4 palletes, 2 are better in PAL, 2 are better in NTSC. Pressing START restarts the animation from the beginning. Have Fun! raytrace.atr
  13. Hi! You can use a REPEAT/UNTIL instead of FOR and use one less variable to do the loop, my result is in N, input in X: i=x/16+x&15*16:w=1:n=0:R.:n=n+i&w*w*3:w=w+w:U.w>255 But it is smaller still if you use the same variable to hold the input and the result. This is the same length as my other solution: n=x/16+x&15*16:I=128:R.:n=n*4+n&I/I*3:I=I+I:U.I<0 What kills this kind of loop is the need to invert the nibbles at the start (the "x/16=x&15*16"), without it it is much smaller. Have Fun!
  14. Hi! Which BASIC? For example, FastBasic does not have "READ", the data is defined as an array. You can have DATA statement span more than one line: DATA LongVar() BYTE = 0,1,2,3,4,5,6,7,8, DATA BYTE = 9,10,11,12,13,14,15,16,$C0,$80, DATA BYTE = $FF,7,8,9 ? LongVar(10) For other BASIC dialects in the Atari, you can use RESTORE to assign a line to read DATA from. Have Fun!
  15. Hi! Indeed! and you don't need the parenthesis, so it is now 2 chars less than the table based one: n=x/16+x&15*256:n=n!(n*4)&13107:n=n!(n*2)&21845*3 Have Fun!
×
×
  • Create New...