An RC5 decoder and preamp controller. Written on the LPC11U24, Ported to LPC1114 and now 100% stable (January 2016)
Dependents: AppleRemoteController_copy_Production_Version AppleRemoteController_Reference_Only
Pindef1114.h@9:c9fb1f8e2ab8, 23 months ago (annotated)
- Committer:
- andrewcrussell
- Date:
- Mon Nov 14 14:18:18 2022 +0000
- Revision:
- 9:c9fb1f8e2ab8
- Parent:
- 4:d900d90588d0
Renamed Apple Remote nov 22
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
andrewcrussell | 2:674e2dd56e7d | 1 | /************************************ Pinfef1114.h *******************************/ |
andrewcrussell | 3:f0cd7c22ca94 | 2 | /****************** for the RC5 preamplifier copntroller program ****************/ |
andrewcrussell | 1:bb881a434906 | 3 | DigitalOut FWD1(dp1); // these are the motor 'H' bridge drive signals |
andrewcrussell | 2:674e2dd56e7d | 4 | DigitalOut REV1(dp2); // when the volume controll motor is not being driven |
andrewcrussell | 2:674e2dd56e7d | 5 | // they are all OFF |
andrewcrussell | 0:83d4a20e7bc7 | 6 | |
andrewcrussell | 3:f0cd7c22ca94 | 7 | DigitalOut muteout(dp13); // drives the mute relay via a mosfet or transistor |
andrewcrussell | 9:c9fb1f8e2ab8 | 8 | DigitalOut muteLED(dp14); |
andrewcrussell | 4:d900d90588d0 | 9 | //InterruptIn mute_int(dp11); // mute p/button interrupt |
andrewcrussell | 4:d900d90588d0 | 10 | //DigitalIn mute(dp11); // mute input from associated pushbutton |
andrewcrussell | 0:83d4a20e7bc7 | 11 | |
andrewcrussell | 3:f0cd7c22ca94 | 12 | DigitalOut stby_pa(dp25); // power amplifier standby control which follows the premap |
andrewcrussell | 3:f0cd7c22ca94 | 13 | // but with suitable delays |
andrewcrussell | 3:f0cd7c22ca94 | 14 | |
andrewcrussell | 3:f0cd7c22ca94 | 15 | InterruptIn rc5int(dp17); // this is the R/C interrupt triggered by the IRx data out |
andrewcrussell | 3:f0cd7c22ca94 | 16 | DigitalIn rc5dat(dp17); // data is read in from here - its coming from the IRx data out |
andrewcrussell | 0:83d4a20e7bc7 | 17 | |
andrewcrussell | 2:674e2dd56e7d | 18 | |
andrewcrussell | 2:674e2dd56e7d | 19 | InterruptIn select_int(dp28); // select rotary encoder interrupt - we use the 'A' O/P to generate the interrupt |
andrewcrussell | 0:83d4a20e7bc7 | 20 | DigitalIn sela(dp28); // select input rotary enc input A |
andrewcrussell | 0:83d4a20e7bc7 | 21 | DigitalIn selb(dp27); // select input rotary enc input B |
andrewcrussell | 0:83d4a20e7bc7 | 22 | |
andrewcrussell | 0:83d4a20e7bc7 | 23 | DigitalIn stdby(dp26); // standby function p/button input |
andrewcrussell | 0:83d4a20e7bc7 | 24 | InterruptIn stdby_int(dp26); // standby p/button interrupt in |
andrewcrussell | 0:83d4a20e7bc7 | 25 | |
andrewcrussell | 1:bb881a434906 | 26 | |
andrewcrussell | 3:f0cd7c22ca94 | 27 | //InterruptIn tone_pb(dp15); |
andrewcrussell | 3:f0cd7c22ca94 | 28 | //DigitalIn tone(dp15); |
andrewcrussell | 3:f0cd7c22ca94 | 29 | //DigitalOut tone(dp25); // can only be turned on and off at this stage by the r/control |
andrewcrussell | 1:bb881a434906 | 30 | |
andrewcrussell | 9:c9fb1f8e2ab8 | 31 | //InterruptIn recloop_int(dp14); //record loop interrupt |
andrewcrussell | 1:bb881a434906 | 32 | DigitalIn recloop_in(dp14); // record loop p/button input |
andrewcrussell | 3:f0cd7c22ca94 | 33 | DigitalOut recloop_out(dp16); // drives record loop LED |
andrewcrussell | 3:f0cd7c22ca94 | 34 | DigitalOut recloop_rly(dp10); |
andrewcrussell | 0:83d4a20e7bc7 | 35 | |
andrewcrussell | 3:f0cd7c22ca94 | 36 | BusOut select_drv(dp24,dp4, dp5, dp6, dp9, dp10); //these are the select relay drivers |
andrewcrussell | 0:83d4a20e7bc7 | 37 | // note that we do not explicitly define the input select output ports because we just move the active |
andrewcrussell | 0:83d4a20e7bc7 | 38 | // output port bit around in a continuos loop with each depress of the select button. Drive the associated |
andrewcrussell | 0:83d4a20e7bc7 | 39 | // input relays via a mosfet or transistor |
andrewcrussell | 0:83d4a20e7bc7 | 40 | |
andrewcrussell | 0:83d4a20e7bc7 | 41 | // DigitalOut myled(LED1); // for test purposes only - on the mbed module - comment out when not used |
andrewcrussell | 0:83d4a20e7bc7 | 42 | // DigitalOut myled2(LED2); |
andrewcrussell | 4:d900d90588d0 | 43 | //DigitalOut bitstreamsync(dp18); //this is a sync pin that is toggled during IR read - used for debug only |
andrewcrussell | 1:bb881a434906 | 44 | |
andrewcrussell | 1:bb881a434906 | 45 | |
andrewcrussell | 1:bb881a434906 | 46 | |
andrewcrussell | 1:bb881a434906 | 47 | |
andrewcrussell | 2:674e2dd56e7d | 48 |