Closed mvdhoning closed 1 year ago
This feature was commented by other user before. I think it's useful and need to be implemented, in the new version of the compiler. But currently, I'm busy in other profitable projects . I need to get some free time to work in the compiler.
Hi. The new version of the compiler have the new directive $BIN2CSV. It can be used to include external binary files like a comma separated text. Check this example:
var
//Initialize with a binary content
AAA: array[3] of byte = ({$BIN2CSV data.bin});
begin
end.
There are some nice tools on pc allowing for easy making graphics charset and sprites for the c64 like charpad and spritpad. It would be nice to import charsets and screens and spriteset from those easly into p65pas code. Now it is a export to assembly and strip away .byte or just dump it an asm block. But for including a koala image i think there is no such a workaround. (or sid music) So a {$BINARY filename.ext} directive would be handy. That loads the data on the spot of the directive.
It would be even more powerfull with the multiple org directive feature request allowing the data at a specified location in c64 memory. E.g. for including a SID fie and next calling the init and play routines via pointers pointed at an absolute memory position what should already be possible.