/*---------------------------------------------------------------------------* Project: Wii Connect 24 API demos File: WiiNumber.c Copyright 2006 Nintendo. All rights reserved. These coded instructions, statements, and computer programs contain proprietary information of Nintendo of America Inc. and/or Nintendo Company Ltd., and are protected by Federal copyright law. They may not be disclosed to third parties or copied or duplicated in any form, in whole or in part, without the prior written consent of Nintendo. $Log: WiiNumber.c,v $ Revision 1.1 2007/06/14 00:42:01 hirose_kazuki Initial check in. *---------------------------------------------------------------------------*/ #include #include #include /*---------------------------------------------------------------------------* A simple demo to display the Wii Number. *---------------------------------------------------------------------------*/ /*---------------------------------------------------------------------------* Main *---------------------------------------------------------------------------*/ int main(void) { NWC24Err err; s32 result; NWC24UserId wiiNumber; result = NANDInit(); if ( result != NAND_RESULT_OK ) { OSHalt("NANDInit() failed.\n"); } (void)NWC24SuspendScheduler(); OSReport("*******************************************************\n"); OSReport(" A simple demo to display the Wii Number.\n"); OSReport("*******************************************************\n"); err = NWC24GetMyUserId(&wiiNumber); if ( err != NWC24_OK ) { OSReport("NWC24GetMyUserId(): Error %d\n", err); OSHalt("Program failed.\n"); } OSReport("Your Wii Number: %016lld\n\n", wiiNumber); OSHalt("Program finished.\n"); return 0; } /*---------------------------------------------------------------------------*/