void main(void) { ES_Return_t ErrorType; BOARD_Init(); //printf("Starting Intern State Machine \n"); //printf("using the 2nd Generation Events & Services Framework\n"); //Hardware Init Bot_Init(); // Framework Init ErrorType = ES_Initialize(); if (ErrorType == Success) { ErrorType = ES_Run(); } //if we got to here, there was an error switch (ErrorType) { case FailedPointer: printf("Failed on NULL pointer"); break; case FailedInit: printf("Failed Initialization"); break; default: printf("Other Failure"); break; } for (;;) ; };
void main(void) { ES_Return_t ErrorType; BOARD_Init(); // When doing testing, it is useful to annouce just which program // is running. printf("Starting the Exit HSM Test Harness \r\n"); printf("using the 2nd Generation Events & Services Framework\n\r"); // Your hardware initialization function calls go here Bot_Init(); Drive_Init(); // now initialize the Events and Services Framework and start it running ErrorType = ES_Initialize(); if (ErrorType == Success) { ErrorType = ES_Run(); } // //if we got to here, there was an error // switch (ErrorType) { case FailedPointer: printf("Failed on NULL pointer"); break; case FailedInit: printf("Failed Initialization"); break; default: printf("Other Failure"); break; } while (1) { ; } }
void Host_Init(quakeparms_t *parms) { if (standard_quake) minimum_memory = MINIMUM_MEMORY; else minimum_memory = MINIMUM_MEMORY_LEVELPAK; if (COM_CheckParm("-minmemory")) parms->memsize = minimum_memory; host_parms = *parms; if (parms->memsize < minimum_memory) Sys_Error("Only %4.1f megs of memory available, can't execute game", parms->memsize / (float) 0x100000); com_argc = parms->argc; com_argv = parms->argv; Memory_Init(parms->membase, parms->memsize); Cbuf_Init(); Cmd::Init(); V_Init(); NN_init(); COM_Init(); Host_InitLocal(); W_LoadWadFile("gfx.wad"); Key_Init(); Con_Init(); M_Init(); PR_Init(); Mod_Init(); NET_Init(); SV_Init(); Bot_Init(); Con_Printf("Exe: "__TIME__" "__DATE__"\n"); Con_Printf("%4.1f megabyte heap\n", parms->memsize / (1024 * 1024.0)); if (cls.state != ca_dedicated) { host_basepal = (byte *) COM_LoadHunkFile("gfx/palette.lmp"); if (!host_basepal) Sys_Error("Couldn't load gfx/palette.lmp"); host_colormap = (byte *) COM_LoadHunkFile("gfx/colormap.lmp"); if (!host_colormap) Sys_Error("Couldn't load gfx/colormap.lmp"); IN_Init(); VID_Init(host_basepal); Draw_Init(); SCR_Init(); R_Init(); TextureManager::Init(); S_Init(); CDAudio_Init(); Sbar_Init(); CL_Init(); } Cbuf_InsertText("exec quake.rc\n"); Hunk_AllocName(0, "-HOST_HUNKLEVEL-"); host_hunklevel = Hunk_LowMark(); host_initialized = true; Sys_Printf("========Quake Initialized=========\n"); }