Minimum Pokitto Library


That’s unsurprising.
Most environments have the OS read the .elf/.exe/.dll and determine how best to load the program into memory.
On something like the Pokitto, you load the program into memory when you ‘flash’ the .bin,
there’s no OS on the device to do it for you, so the addresses have to be predetermined.

I believe it’s also related to memory segments.
Most people are only aware of the .text, .bss, .data and .rodata sections, but other segments are sometimes used, and sometimes that’s platform specific, and the segments appear to be one of the thing linker scripts control.

Also don’t forget that ARM is memory mapped while x86 has dedicated IN and OUT instructions (and peripherals are usually managed by the OS anyway, so there’s no risk of accidentally writing to a device port).

I’d look into it futher, but the last thing I need at the moment is another rabbit hole to jump down,
so I’ll put it towards the back of my todo list.


Yes, good point, the lack of OS API in form of syscalls requires memory mapping. So now I’d also need to figure out the linker script and rewrite it too.

My issue is now testing directly on HW as my dev setup is based on emulator and uploading to Pokitto is a little clumsy for me, and I also can’t debug this well, I really lack a lot of knowledge and experience here.

I’d really love to have that single file minimal completely free CC0 Pokitto library, not only because of the minimalism which I prefer, but it would also liberate the software, which would basically remove my concerns regarding vanilla Pokittolib and I would then be more inclined to recommend Pokitto in free SW communities. I hope @FManga will consider this, it would really be a huge thing to me and also other people.

Three files isn’t bad, but I say why not do better if we can? :slight_smile: This lib is definitely extremely lightweight, but minimal to me means there is really nothing more to take away.