1<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> 2<HTML> 3<HEAD> 4<META http-equiv="Content-Type" content="text/html; charset=windows-1252"> 5<META name="GENERATOR" content="IBM WebSphere Studio Homepage Builder Version 7.0.0.0 for Windows"> 6<META http-equiv="Content-Style-Type" content="text/css"> 7<TITLE>CTRDG_GetAgbMakerCode</TITLE> 8<LINK rel="stylesheet" href="../css/nitro.css" type="text/css"> 9</HEAD> 10<BODY> 11<H1 align="left">CTRDG_GetAgbMakerCode <IMG src="../image/NTR.gif" align="middle"></H1> 12<H2>Syntax</H2> 13<DL> 14 <DD> 15 <PRE><CODE>#include <nitro/ctrdg.h></CODE></PRE> 16 <PRE><CODE>u16 CTRDG_GetAgbMakerCode( void );</CODE></PRE> 17</DL> 18<H2>Arguments</H2> 19<P>None.</P> 20<H2>Return Values</H2> 21<P>Returns the maker code for an existing AGB Game Pak if it matches the one obtained when the <a href="CTRDG_Init.html"><CODE>CTRDG_Init</CODE></a> function was called.<br><br>Otherwise returns <code>FALSE</code>. Also, always returns <code>FALSE</code> after the Game Pak has been removed once.</P> 22<H2>Description</H2> 23<P>Returns the AGB Game Pak's maker code.</P> 24<P>However, if there is no AGB Game Pak or the maker code does not match the code retrieved by the <a href="CTRDG_Init.html"><CODE>CTRDG_Init</CODE></a> function, <CODE>FALSE</CODE> is returned.<br><br>This function can be called when the cartridge bus is locked with the <a href="../os/spinLock/OS_LockCartridge.html"><CODE>OS_LockCartridge</CODE></a> function. However, while the bus is locked, the ARM7 does not detect removal automatically, so call the <A href="CTRDG_IsExisting.html"><CODE>CTRDG_IsExisting</CODE></A> function at regular intervals, such as each game frame, during which the player cannot perform a re-insert operation. (This function internally calls the <A href="CTRDG_IsExisting.html"><CODE>CTRDG_IsExisting</CODE></A> function.) 25</P> 26<H2>Note</H2> 27<P><font color="#800000">If the maker code obtained when the <a href="CTRDG_Init.html"><CODE>CTRDG_Init</CODE></a> function was called matches the one obtained again in this function, that value will be returned.<br><br>Accordingly, note that Game Paks enabled after the <a href="CTRDG_Init.html"><CODE>CTRDG_Init</CODE></a> function is called will not be recognized.</font><br><br>(For details, see the description of the <a href="CTRDG_Init.html"><CODE>CTRDG_Init</CODE></a> function.) 28</P> 29<H2>See Also</H2> 30<P><code><a href="CTRDG_Init.html">CTRDG_Init</a></code><BR> <code><a href="CTRDG_GetAgbGameCode.html">CTRDG_GetAgbGameCode</a></code><BR> <code><a href="CTRDG_IsAgbCartridge.html">CTRDG_IsAgbCartridge</a></code></P> 31<H2>Revision History</H2> 32<P> 332005/04/12 Added description of cartridge bus lock and revised explanation about game code being re-obtained each time.<br />2005/03/03 Added explanation that the presence of a Game Pak is determined only at initialization.<br />2004/10/04 Initial version. 34</P> 35<hr><p>CONFIDENTIAL</p></body> 36</HTML> 37