AirsoftTimer software based on mbed
Dependencies: mbed TextLCD keypad
main.cpp@27:f29805113454, 2017-02-09 (annotated)
- Committer:
- sillevl
- Date:
- Thu Feb 09 12:28:56 2017 +0000
- Revision:
- 27:f29805113454
- Parent:
- 11:50572814f73e
ARCHIVE WIP, not working (crashes, cause unknown)
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
sillevl | 1:c80248c83025 | 1 | #include "mbed.h" |
sillevl | 2:f8e46daca111 | 2 | |
sillevl | 2:f8e46daca111 | 3 | |
sillevl | 4:2c91c9eccf3a | 4 | #include "Airsofttimer.h" |
sillevl | 1:c80248c83025 | 5 | #include "TextLCD.h" |
sillevl | 1:c80248c83025 | 6 | |
sillevl | 7:baf207d88603 | 7 | PinName buttonpin = P0_5; |
sillevl | 7:baf207d88603 | 8 | PinName keypin = P0_4; |
sillevl | 7:baf207d88603 | 9 | PinName buzzerpin = P2_3; |
sillevl | 11:50572814f73e | 10 | LedPins ledpins = {P2_4, P2_5}; // left, right |
sillevl | 4:2c91c9eccf3a | 11 | KeyboardPins keyboardpins = {{P0_8, P0_9, P0_10, P0_11}, {P0_16, P0_17, P0_18}}; |
sillevl | 4:2c91c9eccf3a | 12 | LcdPins lcdpins = {P1_30, P1_31, P0_23, P0_24, P0_25, P0_26}; |
sillevl | 2:f8e46daca111 | 13 | |
sillevl | 4:2c91c9eccf3a | 14 | Pinouts pinouts = { |
sillevl | 7:baf207d88603 | 15 | buttonpin, |
sillevl | 7:baf207d88603 | 16 | keypin, |
sillevl | 7:baf207d88603 | 17 | ledpins, |
sillevl | 7:baf207d88603 | 18 | buzzerpin, |
sillevl | 4:2c91c9eccf3a | 19 | keyboardpins, |
sillevl | 7:baf207d88603 | 20 | lcdpins |
sillevl | 4:2c91c9eccf3a | 21 | }; |
sillevl | 2:f8e46daca111 | 22 | |
sillevl | 1:c80248c83025 | 23 | int main() |
sillevl | 1:c80248c83025 | 24 | { |
sillevl | 4:2c91c9eccf3a | 25 | Airsofttimer airsofttimer(pinouts); |
sillevl | 1:c80248c83025 | 26 | } |
sillevl | 2:f8e46daca111 | 27 | |
sillevl | 2:f8e46daca111 | 28 | |
sillevl | 4:2c91c9eccf3a | 29 | //DigitalOut heartbeatLed(LED1); |
sillevl | 4:2c91c9eccf3a | 30 | //DigitalOut led2(LED2); |
sillevl | 4:2c91c9eccf3a | 31 | //DigitalOut led3(LED3); |
sillevl | 4:2c91c9eccf3a | 32 | //DigitalOut led4(LED4); |
sillevl | 2:f8e46daca111 | 33 |