#include <evmu/hw/evmu_device.h>
#include <evmu/hw/evmu_rom.h>
#include <evmu/hw/evmu_lcd.h>
#include <evmu/fs/evmu_file_manager.h>
int main(int argc, char* argv[]) {
// create a VMU
EvmuDevice* pDevice = EvmuDevice_create();
// load a BIOS (if we were given one as the first cmdline argument)
if(argc >= 2)
EvmuRom_loadBios(pDevice->pRom, argv[1]);
// load a ROM (if we were given one as the 2nd cmdline argument)
if(argc >= 3)
EvmuFileManager_load(pDevice->pFileMgr, argv[2]);
// infinite loop
while(1) {
// Run the emulator for 1ms
EvmuIBehavior_update(EVMU_IBEHAVIOR(pDevice), 1000000);
// Check if the display needs to be updated
if(pDevice->pLcd->screenChanged) {
// iterate over all pixels
for(unsigned h = 0; h < EVMU_LCD_PIXEL_HEIGHT; ++h) {
for(unsigned w = 0; w < EVMU_LCD_PIXEL_WIDTH; ++w) {
// fetch the pixel value for the current location
const GblBool pixel = EvmuLcd_pixel(pDevice->pLcd, w, h);
// print X for black pixels, nothing for white
printf(pixel? "X" : " ");
}
// start next row
printf("\n");
}
// Tell EVMU the screen hasn't changed since we updated
pDevice->pLcd->screenChanged = GBL_FALSE;
}
}
// Release/free the VMU device
EvmuDevice_unref(pDevice);
return 0;
}
When using this to load up a DCI file get the following error.
Im assuming it is some error loading up standalone dci files. tried with and without the bios with and without using the .dci file extension in the cli argument and with / without having the actual file extension being .dci
But only got that specific warning when I ran ./test rom.dci so I suspect it issue is not on my end.