Jump to content

Sandmage

Members
  • Posts

    26
  • Joined

  • Last visited

  • Days Won

    2

Everything posted by Sandmage

  1. The master branch on github already has a patch for the crash. I will provide new binaries when I find the time to work on this again. In the meantime, the crash can be avoided by opening the settings dialog before exporting.
  2. Actually, I feel connecting to C64 BBSs much more enjoyable than DOS or Linux based BBSs. And I too, wan't to run my own BBS. I have started writing a BBS server, but it will be run on a Linux server, although it will be designed to primarily output PETSCII in 40/20 mode. I have recently started to use my C128 to browse BBSs and I too want to use the X16 for that purpose. I think modem options will quickly emerge once the X16 is finished. So many people want it. And I also think, maybe it's good that it isn't there by default. I see the X16 as a platform to tinker with. It will be the foundation for endless options of tinkering and if a VIA get's destroyed by my inability to apply correct voltages, it will be a 5€ replacement and not a, oh my god I killed a CIA. If it can do everything by default, it might get boring quick ...
  3. Have you looked at cc65's conio library? The details of accesing the VERA directly are explained in the VERA programmer's reference: https://github.com/commanderx16/x16-docs/blob/master/VERA Programmer's Reference.md
  4. Thanks for pointing that out. I'll release a 1.1 version later today, before I start coding the TileEditor.
  5. It seems to have serious bugs that make it unusable. Similar, bug free, chips are no longer manufactured. Bugs me too, it would be the ideal solution. There will probably be addon cards, or kits eventually. I will most probably make one based on that chip.
  6. I don't think Arkanoid did that, but I remember playing a clone in the MS-DOS days and I remember that paddle/ball interaction wasn't really physically plausible, but it was fun. By the way, we're in the same timezone.
  7. Just played the level. It looks and plays great. But it doesn't seem to be possible to get the ball to go up again after it started to bounce mostly sideways. But maybe I'm just a bad player.
  8. Let me know what you think and what can be improved. To be honest, I haven't yet tested it that thorougly.
  9. I've been working on this for a couple of weeks now. What I originally intented to do is a tool that crunshes images with repeating patterns into a set of tiles and autogenerates a tilemap. Sort of what Ron Gilbert and Gary Winnick did in Maniac Mansion, but with enhanced features like flipping tiles and shifting the color palette. Befor I could have that I need a Tileeditor, and before I can create a Tileeditor I need this. So, this is the first version of what I hope will be a very versatile tool to create assets optimized for the VERA chip.
  10. Vera Graphics Converter View File Version 0.1 This software converts indexed and RGBA images in the formats PNG, JPG or GIF into binary data suitable for the VERA chip in the upcoming 8-Bit Computer Commander X16. Basic usage: Open an image file using File/Open... Configure the settings according to your needs. Export the image using File/Export Bitmap/Tiles/Sprites... Image Modes: You can open either an indexed image with an embedded palette or a regular RGBA image. Depending on the image mode, the software behaves slightly differently. RGBA: In RGBA mode, VGC needs to match the pixel colors to the colors in the palette. This can be done by comparing color similarity in RGB (Red, Green, Blue), HSL (Hue, Saturation, Lightness) or HSV (Hue, Saturation, Brightness) mode. Select the conversion strategy that works best for your image. Ideally load a palette that matches all colors in the image. You can specify the bit depth of the image by changing the pixel mode. 1 Bit per Pixel results in 2 colors, 2 Bits per Pixel result in 4 colors, 4 Bits per Pixel result in 16 colors and 8 Bits per Pixel uses the whole palette of 256 colors. The colors usable by the image depend on the palette offset. Indexed: In indexed mode VGC assumes that all pixels in the image have the correct index. It is still necessary to select the correct palette offset to give a correct export. On export the palette offset is subtracted and the index value capped on the selected pixel mode. Transparency Any pixel in the image that has an alpha value of 255 is set to the index selected in "Transparent Color Index". The minimum value is the palette offset. Image Mode: The VERA Graphic chip has three modes. Bitmap, tiled with a tile dimension of 8 * 8 pixels and tiled with a tile dimension of 16 * 16 pixels. Both tile modes split the image in separate tiles and limit their number to 256, since the VERA chip cannot address more than 256 tiles. It is also possible to limit their number even further. To use a tile mode the width and height of your image must be divisible by 8 or 16. The VERA chips supports 4 different resolutions: 640x480, 320x480, 640x240 and 320x240. VGC does not enforce these resolutions. It is also possible to generate sprite maps. In sprite mode the tiles can have 8, 16, 32 or 64 pixels in width or height. They are however limited to 128 tiles, and similarly, the source images dimensions have to be divisible by the tile dimensions. Sprites can only have a color depth of 4 or 8 Bits per Pixel. PRG File Header It is possible to save the exported binary file with 2 leading bytes. This is necessary for some load routines in the Commander X16 Kernal. Splitting files The exported files can be saved in chunks of a given size. The VERA Video RAM is paged in pages of 2048 bytes. Files can be split at any page, depending on how you want to store or load your data. The PRG File Header is saved to every individual file. The Palette You can load and save the color palette in the Format used by the Gnu Image Manipulation Program (GIMP) Other software like Aseprite can read and save this format too. You can also export the palette in the format used by the VERA chip. The PRG Header option is applied to this as well. The file splitting is not. Analyzing the image. You can double click on colors in the palette to change them. When you hold the left mouse button on a color in the palette, the parts of the image using this color are highlighted. Similarly, when you click on the image the color in the palette is also highlighted. Submitter Sandmage Submitted 07/02/20 Category Dev Tools  
  11. Version 0.1.1

    230 downloads

    Version 0.1 This software converts indexed and RGBA images in the formats PNG, JPG or GIF into binary data suitable for the VERA chip in the upcoming 8-Bit Computer Commander X16. Basic usage: Open an image file using File/Open... Configure the settings according to your needs. Export the image using File/Export Bitmap/Tiles/Sprites... Image Modes: You can open either an indexed image with an embedded palette or a regular RGBA image. Depending on the image mode, the software behaves slightly differently. RGBA: In RGBA mode, VGC needs to match the pixel colors to the colors in the palette. This can be done by comparing color similarity in RGB (Red, Green, Blue), HSL (Hue, Saturation, Lightness) or HSV (Hue, Saturation, Brightness) mode. Select the conversion strategy that works best for your image. Ideally load a palette that matches all colors in the image. You can specify the bit depth of the image by changing the pixel mode. 1 Bit per Pixel results in 2 colors, 2 Bits per Pixel result in 4 colors, 4 Bits per Pixel result in 16 colors and 8 Bits per Pixel uses the whole palette of 256 colors. The colors usable by the image depend on the palette offset. Indexed: In indexed mode VGC assumes that all pixels in the image have the correct index. It is still necessary to select the correct palette offset to give a correct export. On export the palette offset is subtracted and the index value capped on the selected pixel mode. Transparency Any pixel in the image that has an alpha value of 255 is set to the index selected in "Transparent Color Index". The minimum value is the palette offset. Image Mode: The VERA Graphic chip has three modes. Bitmap, tiled with a tile dimension of 8 * 8 pixels and tiled with a tile dimension of 16 * 16 pixels. Both tile modes split the image in separate tiles and limit their number to 256, since the VERA chip cannot address more than 256 tiles. It is also possible to limit their number even further. To use a tile mode the width and height of your image must be divisible by 8 or 16. The VERA chips supports 4 different resolutions: 640x480, 320x480, 640x240 and 320x240. VGC does not enforce these resolutions. It is also possible to generate sprite maps. In sprite mode the tiles can have 8, 16, 32 or 64 pixels in width or height. They are however limited to 128 tiles, and similarly, the source images dimensions have to be divisible by the tile dimensions. Sprites can only have a color depth of 4 or 8 Bits per Pixel. PRG File Header It is possible to save the exported binary file with 2 leading bytes. This is necessary for some load routines in the Commander X16 Kernal. Splitting files The exported files can be saved in chunks of a given size. The VERA Video RAM is paged in pages of 2048 bytes. Files can be split at any page, depending on how you want to store or load your data. The PRG File Header is saved to every individual file. The Palette You can load and save the color palette in the Format used by the Gnu Image Manipulation Program (GIMP) Other software like Aseprite can read and save this format too. You can also export the palette in the format used by the VERA chip. The PRG Header option is applied to this as well. The file splitting is not. Analyzing the image. You can double click on colors in the palette to change them. When you hold the left mouse button on a color in the palette, the parts of the image using this color are highlighted. Similarly, when you click on the image the color in the palette is also highlighted.
  12. I've just noticed that the Ulitmate1541 has a builtin modem now. I've been surfing BBSs the last hours, it's working great. It should be possible to hook the address- and databus to the cartridge. The Expansion ports expose the whole Address and Databus. Of course the cartridges software will not work, but it can be controlled via telnet, so that shouldn't be necessary.
  13. I think I've found the answer: According to this thread, the arguments for SETLFS are wrong:https://www.lemon64.com/forum/viewtopic.php?t=59083&sid=427e03cdae2d9890966ee5ebe2e74b81 lda #$00 ldx #$08 ldy #$01
  14. No, what doesn't work is stream based file i/o. The kernal save routine works. It doesn't work with banked ram, though: https://github.com/commanderx16/x16-rom/issues/136 Edit: I just checked. Even when saving from #A000 it works. At least it creates a file with data inside.
  15. Yeah, my mistake. And also, unlike the 6510 the 65C02 does not have a CPU port, so that's not what is wrong either. I cannot spot the mistake. Maybe try device 1 instad of 8. I think 8 is the SDcard, while 1 is the host filesystem, but I could be mistaken.
  16. Unless you explicitly read somewhere that you should add 1 to the end adress, I would guess that's wrong. End adresses are usually inclusive. But that's not the mistake. You cannot use Zeropage $00 and $01, because that's the CPU Port. I would try $70/$71. According to documentation everything untul $7F is free. But to be save, use something at the end of BASIC RAM.
  17. Your welcome. It was interesting for me too. Doing this in assembler shouldn't be difficult. Look at my first post. Using a trick like this wouldn't be the recommended way anyhow.
  18. Actually, wrong again. Since the pointer to basic ram on the C64 points to $0801 not $0800, I was looking for the wrong numbers. On the x16 223/224 ($DF/$E0) read 1 and 8, so that should be the pointer. Also, writing to these adresses changes the basic programm in memory. However, the two bytes following both read 0. Changing 224 to 9 clears the basic programm, however, entering a basic line locks up the emulator.
  19. It's very like wrong. The C64 KERNAL ROM has those same declarations at $AC and $AE. So those are not the right numbers. And 43/44 is a pointer to the start of basic-ram on the C64. Now it depends on whether the basic ram start and end adresses are hardcoded on the X16. Basic RAM starts at $0800 on the X16, so if there is apointer to the start of basic on the zeropage, it should be initialized with $00 and $08. This appears to not be the case.
  20. Also, to add to your initial question. I didn't know about this C64 trick, but what it probably does is bend the address of the save routines to point to something else than the start of the basic ram. It should be possible to do this on the X16 as somewhere that save routine has to get those adresses too. The actual locations will definitely be different. Also, I don't understand why this should work as the SAVE function should overwrite those memory locations. I've looked at the kernal-rom. In kernal/cbm/channel/channel.s are two defines that look to me like they could be the starting and end adresses: sal .res 1 ;$AC sah .res 1 ;$AD eal .res 1 ;$AE eah .res 1 ;$AF If this is correct starting address might be be in $AC (172) and end address in $AE (174). POKE 173,5000/256:POKE 172,5000-256*PEEK(173) POKE 175,6000/256:POKE 174,6000-256*PEEK(175) SAVE "DATA",1,1 Or, I could be totaly wrong. There is also a disclaimer that no zeropage adress is fixed as the kernal is still in development.
  21. Welcome, I feel the same way. When I started studying Computer Science in 2004, I noticed all the cracks started with the C64 and alike. All the non cracks didn't. To me, these old machines are still magic. Magic that I can understand and control. I hope your daughter will develop that same feeling.
  22. Apparently load and save routines are still in their infancy within the X16 roms. I’m really just learning this myself. Here is how I tackle such problems: By looking at the source of X16-Columns I’ve found a library called libx16 that has load and save functions. https://github.com/CJLove/libX16/blob/29bf20c869c56eef51b5984cbe03b9e7fb12a2dd/src/save.c Compiling save.c with cc65, I can get the assembly of those functions that are a good starting point for writing my own routines. Compiling to assembly works like this: cl65 -t cx16 -S save.c I’ve attached the assembler output to this post. I hope this helps. save.s
  23. Yes there is. I'm probably not able to code this out of my head right now, but all 6502 assemblers support converting ascii to petscii strings like this. Label: .byte "Hello World",0 You then have the string 'Hello World' followed by a NULL byte at address 'label'. Then you can set the X register to 0 and walk over the string: loop: lda (Label), x clc cmp #$00 beq loopend sta (VeraPort) lda #$0F sta (VeraPort) inx jmp loop loopend: ... I hope I got this about right. This code is untested.
  24. Hi everybody, I've had a C-128 in the early 90ies and had my first programming expericene on it. I've been following this project since the beginning, but wasn't on FB. I'm mostly interested in programming C for the CX16, gradually optimizing it as my assembler skills improve. Looking forward to buying the machine, once it goes on sale. So all in all, a big shout out to the CX16 team. You guys are amazing!
  25. I'm toying around with cc65. I'm trying to write a string to a file and read it back again. The following example works on a C64, yet x16emu cannot open the file for writing. Even with an sdcard attached. Does anyone know whether this is unimplemented or a bug? The source in cc65/libsrc/common for fopen seems to be common among all "cbm" machines. #include <stdlib.h> #include <stdio.h> char buf[128]; int main(void) { FILE *fp; int i; for (i = 0; i < 128; ++i) { buf = '\0'; } fp = fopen("testfile", "wb"); if (fp == NULL) { printf("Could not open file for writing."); return 0; } fputs("Hello World in text", fp); fclose(fp); fp = fopen("testfile", "rb"); if (fp == NULL) { printf("Could not open file for reading."); return 0; } fgets(buf, 128, fp); fclose(fp); printf("%s\n", buf); return 0; }
×
×
  • Create New...

Important Information

Please review our Terms of Use