mrdudz / cc65-floatlib

a naive approach for using kernal floating point numbers on C64, while using IEEE float values at application level
zlib License
37 stars 11 forks source link

C128 port? #6

Open xlar54 opened 2 years ago

xlar54 commented 2 years ago

Would love to see a 128 port of this. Any pointers on how to develop a port?

mrdudz commented 2 years ago

I wouldnt be surprised if it just worked with minimal modifications - you'll only have to find the matching kernal and basic routines (my guess is most are the same) and adjust the code like the vic20 port does. And perhaps add some banking stuff into the wrappers.

stringsn88keys commented 1 year ago

I started messing around with it a couple of years ago, c128 branch. Just came back to thinking about it this week and want to get it done.

mrdudz commented 1 year ago

Fell free to make a PR once it is ready :)

markjreed commented 1 year ago

A C128 port will be tricky because the float routines in its BASIC are designed to work with the RAM bank where BASIC variables are stored - bank 1. So if your C program's float values are in bank 0, you'll have to copy them into bank 1 somewhere before the float routines will be able to see them.

stringsn88keys commented 1 year ago

@markjreed That's helpful to know prior to tearing my hair out with code that seems like it should 100% work.