Replies: 18 comments 1 reply
-
Another thought: we could use the same mechanism to automatically run the test suite, to give some assurance that changes haven't broken compatibility or caused a performance hit. |
Beta Was this translation helpful? Give feedback.
-
@rhalkyard ,
For some reason the
|
Beta Was this translation helpful? Give feedback.
-
Hands-free build is something great; from my experience with cc64 and the CBM flavour of VolksForth I can highly recommend it. Interesting stuff about the debug cartridge in VICE - I didn't know about that. I chose a different path to implement stopping the emulator from within, basically using the file system as a signal path to the outside. The emulator is watched by a shell loop, and as soon as a certain file (called "notdone") disappears (because the code inside the emulator scratched it), the shell loop terminates VICE. Kinda nice: this approach also works with x16emu, the emulator for the Commander X16. Details are here, here, here and here if you want to look at some code. chitselb in the 6502.org forum chose yet another pathto achieve the same goal: They use VICE's breakpoint and monitor feature to terminate VICE with a SYS command. See http://forum.6502.org/viewtopic.php?f=8&t=5628 |
Beta Was this translation helpful? Give feedback.
-
@pzembrod, I happened across your presentation "Temporary headers in VolksForth" as I subscribe to the channel it was posted in. Nice work. The low level details go over my head. Very interesting. I'll have to look at it and cc64 in more detail. But I've been wanting to build a scheme where I can swap in code from the C64 REU (i.e. overlays see Forth Dimensions v05 n1 p37). Maybe this is exactly solvable with your temporary headers. |
Beta Was this translation helpful? Give feedback.
-
It would be nice to have CI setup through Github Actions. It seems like work to set it up, but in the ideal scenario, it could build & run test suite for every commit, and releases could be generated & published automatically. |
Beta Was this translation helpful? Give feedback.
-
@cminter thank you, and sorry, I completely forgot to reply earlier.
Thank you for pointing out this article to me. For cc64 I'll need to come up with a way to place Forth code into banked memory on the Commander X16 before I can continue any feature work as I am at the code size limit for the X16 version. For this, this FD article will surely be super-useful. I could see temp headers being useful in this context, to save overlay or banked memory, but the core problem of banked or overlay code seems to be somewhat different from or even orthogonal to the problem that temp headers solve. |
Beta Was this translation helpful? Give feedback.
-
@jkotlinski I've been thinking about this for cc64 and VolksForth, too. I think that I already have most of the scripting for CI actions. The one thing missing for proper batch processing would be a framebuffer X11 server to run the VICE emulator in a headless mode. But beyond that, a larger obstacle I would see is that you would have to check in C64 ROMs for VICE to run on github workers, and that might pose copyright challenges. |
Beta Was this translation helpful? Give feedback.
-
@pzembrod Ooops, copyright challenges might be difficult! It was easier in the past when everyone was oblivious to such things! |
Beta Was this translation helpful? Give feedback.
-
@jkotlinski I've been thinking about this a bit more. Maybe https://github.com/MEGA65/open-roms could provide a viable option. |
Beta Was this translation helpful? Give feedback.
-
I just upgraded Vice on my computer, to 3.6.0, and it seems ROMs came included. In that case, perhaps it is no longer an issue. |
Beta Was this translation helpful? Give feedback.
-
That's great news! |
Beta Was this translation helpful? Give feedback.
-
It is an issue for some people, but not all. I guess Vice has a license to distribute the unmodified ROMs somehow, but they are non-free binaries themselves, so won't ship in distributions like Debian or Guix. It is weird that Vice doesn't indicate under what conditions the ROMs are included, as they have been asked. Vice seems to have included full C64 ROMs since 0.14.2.26 was imported in 1998. |
Beta Was this translation helpful? Give feedback.
-
https://github.com/lonetech/durexforth/tree/faster-build demonstrates running the deploy step in an automated fashion using Vice. Vice itself checks the program finishes in a finite time, and saves a screenshot of the last stage. I should probably have read this thread properly to learn about the debugcart, but at least I get status output? It's also interesting how the "ok!" didn't happen, but the interpreter was left awaiting input. It looks like turnkey interfered with the interpreting of the final words in base. I used a noname compiled section to work around that. |
Beta Was this translation helpful? Give feedback.
-
@lonetech sorry for belated reply. What is "x64.exe" that you are using instead of "x64sc.exe"? It is not included in my Vice install. |
Beta Was this translation helpful? Give feedback.
-
I now added so that "make deploy" exits Vice automatically. It also runs the tests automatically. Not totally hands-free though, as one test tests keyboard input. The problem with "ok!" not happening, and the need to put the $d7ff write in Thank you for all the great advice given in this issue! Anything else I should think of before I close the issue? |
Beta Was this translation helpful? Give feedback.
-
Hi Philip, nice to hear from you!
I sorted this by Vice -keybuf, as well as writing Forth code that pushes
characters to the keyboard buffer :-)
Thank you for suggestions!
I should investigate volksForth more deeply some day! I bet there are many
good ideas hidden!
sön 22 jan. 2023 kl. 16:55 skrev Philip Zembrod ***@***.***>:
… Hi Johan,
in case you would also like to automate the keyboard input test: I managed
to do that for the CBM flavours of volksForth by using the
-keybuf
flag of VICE:
The "1234567890" part of the input (plus a newline attached by a script)
in the make rule at e.g.
https://github.com/forth-ev/VolksForth/blob/master/6502/C64/Makefile#L106
is consumed by the accept-test word in the core test:
https://github.com/forth-ev/VolksForth/blob/master/6502/C64/tests/core.fr#L991
respectively, for durexforth,
https://github.com/lonetech/durexforth/blob/faster-build/forth_src/testcore.fs#L974
The script details live here:
https://github.com/forth-ev/VolksForth/blob/master/6502/C64/emulator/run-in-vice.sh#L47
Maybe this can be useful for you, too.
Cheers
/Philip
—
Reply to this email directly, view it on GitHub
<#513 (reply in thread)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAY34O6CHTAEUS62ILUCSMTWTVKAXANCNFSM6AAAAAAUDBVTRM>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
Beta Was this translation helpful? Give feedback.
-
I just managed to set up Github CI! For each push to master, it builds durexforth and makes sure that all tests still pass. I am surprised how easy this was! You can check the workflow here: https://github.com/jkotlinski/durexforth/blob/master/.github/workflows/build.yml |
Beta Was this translation helpful? Give feedback.
-
Wow, that is amazing! Esp. the headlessvice install looks really cool. |
Beta Was this translation helpful? Give feedback.
-
Just a little quality-of-life improvement that I've added to my personal build setup for durexforth:
The VICE
-debugcart
option makes VICE quit when a program writes to IO address$d7ff
, with the return code being the byte that was written - the intent is to allow automated testing of C64 code. https://vice-emu.pokefinder.org/index.php/DebugcartInvoking VICE with
-debugcart
and adding0 $d7ff c!
to the end ofsave-pack
allows an unattendedmake deploy
- on a successful build, VICE quits automatically and the build continues, but if something fails, it stays open so you can see the error message.We probably don't want to make
save-pack
do this outside of the build environment in case it interferes with any unusual setups people have out there, but if we can somehow set things up so that it happens during the build but never on a built system, it would streamline things quite nicely. The C128 build means that another VICE instance has to run, and I'm forgetful enough that I often wonder why the build is stuck, until I find a VICE window I'd forgotten to close...Probably a pretty low-priority thing, but I thought I'd share.
Beta Was this translation helpful? Give feedback.
All reactions