# CTRDG_GetAgbMakerCode

## Syntax

      #include <nitro/ctrdg.h>

      u16 CTRDG_GetAgbMakerCode( void );

## Arguments

None.

## Return Values

Returns the maker code for an existing AGB Game Pak if it matches the one obtained when the `CTRDG_Init` function was called.
Otherwise returns `FALSE`. Also, always returns `FALSE` after the Game Pak has been removed once.

## Description

Returns the AGB Game Pak's maker code.

However, if there is no AGB Game Pak or the maker code does not match the code retrieved by the `CTRDG_Init` function, `FALSE` is returned.
This function can be called when the cartridge bus is locked with the `OS_LockCartridge` function. However, while the bus is locked, the ARM7 does not detect removal automatically, so call the `CTRDG_IsExisting` function at regular intervals, such as each game frame, during which the player cannot perform a re-insert operation. (This function internally calls the `CTRDG_IsExisting` function.)

## Note

If the maker code obtained when the `CTRDG_Init` function was called matches the one obtained again in this function, that value will be returned.
Accordingly, note that Game Paks enabled after the `CTRDG_Init` function is called will not be recognized.
(For details, see the description of the `CTRDG_Init` function.)

## See Also

`CTRDG_Init`
`CTRDG_GetAgbGameCode`
`CTRDG_IsAgbCartridge`

## Revision History

2005/04/12 Added description of cartridge bus lock and revised explanation about game code being re-obtained each time.
2005/03/03 Added explanation that the presence of a Game Pak is determined only at initialization.
2004/10/04 Initial version.

CONFIDENTIAL