Been lurking the forum only for a short while, so not sure if this is the right place to ask.
I've been fooling around with Basic 10 as a way to start familiarizing myself with C65 in Xemu and one thing I'm stuck with right now is getting my program to switch to 40 columns or 80 columns with one or more poke commands.
So I did print peek(dec("D031")), which seemed the right (and only?) address that concerns this. Was getting 224 for 80 column and 96 for 40 column, after switching the modes manually with F1 in the emu.
Now doing a poke dec("D031"),96 will switch the screen to 40 columns, but if I was in 80 columns from boot, the line width remains 80 or something. So every print command or the list command on a larger program will throw in an empty line every row if the contents are within 40 columns.
And doing a poke dec("D031"),224 will switch to 80 columns, if I was in 40 columns from pressing F1 earlier, but the line width will then remain 40, which makes every rows being printed or listed alternating between the left half and the right half of the screen.
F1 switches the modes correctly, including limiting the maximum line width that basic is displaying its stuff in. So I either keep missing the register in the documentation that makes this works correctly, or I'm not understanding $D031 correctly, or it's a bug of sorts. But I'm not putting my money on bug. It's probably my limited knowledge
Thanks in advance if anyone can push me in the right direction. Cheers!