I am a bit unsure of my terminiology here so please bear with me. I am using a library (IRremote.h) and to send a IR code with this library I need to specify the manufacturer/protocol, for instance:
I have already written a sketch to identify the manufacturer/protocol and keycodes and I want to automatically retransmit them. But I've gotten stuck with using a variable in the above command. For instance, I have the make "NEC", Sony" etc. in a variable called "make" and I have tried:
Thanks, I have edited the OP to correct my typo. I will use your suggestion regarding using make to select the class method but as there are more than 20 possibilities I will use switch rather than if statements.
steveinaustria:
Thanks, I have edited the OP to correct my typo. I will use your suggestion regarding using make to select the class method but as there are more than 20 possibilities I will use switch rather than if statements.
Instead of your String 'make', use a variable of the type 'decode_type_t'. It's a enum defined in IRProtocol.h. You can use an enum in a switch / case structure.