This is a simple class written to flash out morse code. It can be used to flash out data from the terminal or from a buffer
MorseCode.h@0:c3c4f0cd78cd, 2013-09-18 (annotated)
- Committer:
- mr63
- Date:
- Wed Sep 18 16:27:24 2013 +0000
- Revision:
- 0:c3c4f0cd78cd
This is a simple Class that was written to "flash" out Morse Code. It can be used to flash out data from the terminal, or from a buffer. The main function gives examples of both.
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
mr63 | 0:c3c4f0cd78cd | 1 | #include "mbed.h" |
mr63 | 0:c3c4f0cd78cd | 2 | |
mr63 | 0:c3c4f0cd78cd | 3 | class MorseCode{ |
mr63 | 0:c3c4f0cd78cd | 4 | public: |
mr63 | 0:c3c4f0cd78cd | 5 | MorseCode(PinName pin); |
mr63 | 0:c3c4f0cd78cd | 6 | |
mr63 | 0:c3c4f0cd78cd | 7 | void blink_buffer (unsigned char * Pbuffer); |
mr63 | 0:c3c4f0cd78cd | 8 | bool Print_ASCII_Char(unsigned char letter); |
mr63 | 0:c3c4f0cd78cd | 9 | float get_unit(); |
mr63 | 0:c3c4f0cd78cd | 10 | void set_unit(float); |
mr63 | 0:c3c4f0cd78cd | 11 | |
mr63 | 0:c3c4f0cd78cd | 12 | private : |
mr63 | 0:c3c4f0cd78cd | 13 | // objects |
mr63 | 0:c3c4f0cd78cd | 14 | DigitalOut _pin; |
mr63 | 0:c3c4f0cd78cd | 15 | void blink_letter (unsigned int letter); |
mr63 | 0:c3c4f0cd78cd | 16 | void Dash(); |
mr63 | 0:c3c4f0cd78cd | 17 | void Dot(); |
mr63 | 0:c3c4f0cd78cd | 18 | |
mr63 | 0:c3c4f0cd78cd | 19 | }; |
mr63 | 0:c3c4f0cd78cd | 20 |