[Question] Using PokittoSim in Code::Blocks

The only game I am aware of right now is my own solitaire game. I don’t want to update pokitto lib until it’s finished though.

How is it that 2 differently named functions would conflict?

I take it you only use mbed online?

Ah, seems the conflict wasn’t what I thought.
It seems the conflict came from mode13 having been removed in the uploaded code.

(It was a git merge conflict, not a C++ conflict.)


Either way that issue still seems to exist.

Nope, embitz offline. I think this is the second time that mode13 has been damaged in merges.

Then I don’t see what’s stopping you from checking, you can have more than one copy of both the PokittoLib and your game without the different copies interfering with each other.

If you just don’t want to show off the changes you’ve made, do you have an old copy of your code somewhere? (e.g. Github)

I will check this in a moment

1 Like

@spinal:

Typo in Pokitto_settings.h, line 282. Internal #defines are intended to be POK_ not PROJ_.

Ie. POK_SCREENMODE is not set. “PROJ_SCREENMODE” is not the correct #define

The reason is to be able to follow #defines set externally (PROJ_) and set internally (POK_)

#if PROJ_MODE13 > 0
#define PROJ_SCREENMODE MODE13
#define POK_COLORDEPTH 8
#define POK_STRETCH 0
#define POK_FPS 30
#endif

Should be:

#if PROJ_MODE13 > 0
#define POK_SCREENMODE MODE13
#define POK_COLORDEPTH 8
#define POK_STRETCH 0
#define POK_FPS 30
#endif

Fixed and pushing to repo

2 Likes

I wasn’t at home.

@jonne Thanks for sorting it out.

2 Likes

@jonne, @Pharap, @spinal thanks for helping me.
I can confirm that the demo is working properly now in the simulator.

3 Likes

Ok. From the way you said it I just thought you were worried about your project getting messed up or being shown early.

That was easier to fix than expected.

That’s always a worry, no matter the project. For example, after adding the above fix, none of my gfx work, or perhaps the palettes, can’t quite tell. Either way, can’t look at it again until after work or even tomorrow :thinking::pensive:

It rarely affects me.

I just dump my stuff on Github and it either gets noticed or it doesn’t.
Usually nobody checks their Github feed and what I’m working on goes unnoticed.
If they notice, it’s only their own suprise they’re spoiling.

(Also I keep multiple copies of the PokittoLib around.)

The best way to check is to try to remember how old your previous copy of the PokittoLib was and look for changes between those dates.

Just re-downloaded pokittolib to be sure I was up to date. Without jonnes fix, mode13 doesn’t load the palette properly (seems not to load all 256 colours and palette doesn’t rotate in the plasma example) and with the fix the program wont get past the volume setting screen.

So it gets stuck on hardware? I will check that

There doesn’t seem to be an update for mode13 in PokittoDisplay.cpp again.

There were several overlapping merges at the time. I will fix this once and for good today

1 Like

I just tried adding

    #if POK_SCREENMODE == MODE13
    lcdRefreshMode13(m_scrbuf, paletteptr, palOffset);
    #endif

but get

Pokitto\POKITTO_CORE\PokittoDisk.cpp|68|error: too few arguments to function ‘DSTATUS disk_initialize(BYTE)’|

when trying to rebuild.

@spinal : just tested and it was working fully in embitz. I will sync the github repo and the mbed repo now

2 Likes

hmmmmm… Something isn’t quite right. First I thought 8bit drawbitmap might be missing, but that is still there. I can’t think what would cause this…

1 Like

That looks like either an indexing problem or a bitshift problem.

Yup, fixed it…