Discussion about software development for the old-school Gameboys, ranging from the "Gray brick" to Gameboy Color
(Launched in 2008)
You are not logged in.
Can printf not print 32bit numbers ?
My code:
#include <gb/gb.h>
#include <stdio.h>
#include <stdint.h>
void main() {
int32_t i = 45000;
// printf("x:%ld \n", (int32_t)i); //<- %ld doesn't work
printf("x:%d \n", (int32_t)i);
}
BGB output:
x: -20536
I'm trying to write a simple calculator....
Last edited by M2m (2022-01-25 05:32:42)
Offline
use ltoa()/ultoa()
Offline
toxa wrote:
use ltoa()/ultoa()
Ha ! That works !
Offline