Apple Mbed Studio ready 15 Nov 2022

Dependencies:   mbed

Committer:
andrewcrussell
Date:
Tue Nov 15 11:32:21 2022 +0000
Revision:
0:3110d82c59ff
Apple final build Nov 15 2022

Who changed what in which revision?

UserRevisionLine numberNew contents of line
andrewcrussell 0:3110d82c59ff 1 /********************************* RC5 control codes ******************************/
andrewcrussell 0:3110d82c59ff 2 // The Philips RC5 coce consists of 14 bits delivered in bi-phase Manchester encoding from
andrewcrussell 0:3110d82c59ff 3 // an IR LED on the remote. This is picked up by a detector (e.g. a Vishay TSOP3741) which
andrewcrussell 0:3110d82c59ff 4 // outputs the demodulated bit stream as follows:-
andrewcrussell 0:3110d82c59ff 5 // First 2 bits are start bits - allow the detector AGC to stabilize and trigger decoding process
andrewcrussell 0:3110d82c59ff 6 // Third bit is the toggle bit - it remains at the same logic level as long as a key is depressed
andrewcrussell 0:3110d82c59ff 7 // and will change to the alternate state when the key is un/re-depressed or when a different
andrewcrussell 0:3110d82c59ff 8 // key is depressed
andrewcrussell 0:3110d82c59ff 9 // Bits 4~8 are the address bits and determine which piece of equipment is being controlled
andrewcrussell 0:3110d82c59ff 10 // Bits 9~14 are the command bits
andrewcrussell 0:3110d82c59ff 11 // As long as a key is depressed, the 14 bits will be sent by the remote controller in sequential
andrewcrussell 0:3110d82c59ff 12 // blocks with a 120ms delay between subsequent block transmissions
andrewcrussell 0:3110d82c59ff 13 // See http://en.wikipedia.org/wiki/RC-5 for the codes
andrewcrussell 0:3110d82c59ff 14
andrewcrussell 0:3110d82c59ff 15 // 0-9 NUMERIC KEYS 0 - 9 - not used in this implementation
andrewcrussell 0:3110d82c59ff 16
andrewcrussell 0:3110d82c59ff 17 // unused commands and addresses have been commented out - simply un-comment them to use them
andrewcrussell 0:3110d82c59ff 18 // but note that if you do this, you will have to decode them, otherwise they will just fall through
andrewcrussell 0:3110d82c59ff 19 // and be ignored by the decoder. Only the ones un-commented out below are active in V1.0
andrewcrussell 0:3110d82c59ff 20 // Note you will also need to write the associated command processor functions
andrewcrussell 0:3110d82c59ff 21
andrewcrussell 0:3110d82c59ff 22 #define STANDBY 378 // toggle power ON and OFF
andrewcrussell 0:3110d82c59ff 23 #define MUTE 442 // toggle output signal on and off
andrewcrussell 0:3110d82c59ff 24 #define VUP 464
andrewcrussell 0:3110d82c59ff 25 #define VDOWN 432
andrewcrussell 0:3110d82c59ff 26 #define SELECT_R 480 // rotates input through inputs - must depress and then release each time
andrewcrussell 0:3110d82c59ff 27 #define SELECT_L 272 // rotates input through inputs - must depress and then release each time
andrewcrussell 0:3110d82c59ff 28 #define PREAMP 479 // this is the system code identifying an Apple Remote
andrewcrussell 0:3110d82c59ff 29
andrewcrussell 0:3110d82c59ff 30
andrewcrussell 0:3110d82c59ff 31
andrewcrussell 0:3110d82c59ff 32
andrewcrussell 0:3110d82c59ff 33
andrewcrussell 0:3110d82c59ff 34
andrewcrussell 0:3110d82c59ff 35
andrewcrussell 0:3110d82c59ff 36
andrewcrussell 0:3110d82c59ff 37
andrewcrussell 0:3110d82c59ff 38
andrewcrussell 0:3110d82c59ff 39
andrewcrussell 0:3110d82c59ff 40