Transmitting IR codes

So I'm using the Ken Shirriff's IRLibrary and understand everything but what 'codes' you use to send, like I understand theres the different protocols on how it's transmitted (Eg. NEC, Sony, RC5 and RC6) but wjat I don't understand is the values you send, like irsend.sendSony(what value is this, what does this even mean); are they just basic hexidecimal values and if so how do you choose which one to use, I'm asking because I'm trying to make a basic IR remote control that controls some lights, I just don't know what values to use or which is the best/easiest protocol to use

If you intend to use arduino both for sending and receiving side: use any coding you decide yourself.
Many user choose to use an surplus remote sender, chech which codes it sends and then let the receiver take action basted on those received code signals..

Well yeah, I'll be using one arduino to send and one to receive, so I'm going to have to use irsend.sendNEC() but what values do I put in the first variable slot and what do I put in the second one, what do I even use the second one for?..

Looking in the library files, I found this:

void sendNEC(unsigned long data, int nbits);