No code is involved. Once you have the giant red Materia, simply talk to it and Bahamut Zero is yours.