Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
NixieTube.h@0:34f3e0f37c55, 2016-12-05 (annotated)
- Committer:
- fischk08
- Date:
- Mon Dec 05 21:35:57 2016 +0000
- Revision:
- 0:34f3e0f37c55
- Child:
- 1:0470cc006ce7
V1
Who changed what in which revision?
| User | Revision | Line number | New contents of line |
|---|---|---|---|
| fischk08 | 0:34f3e0f37c55 | 1 | /* NixieTube.h */ |
| fischk08 | 0:34f3e0f37c55 | 2 | #ifndef NIXIETUBE_H_ |
| fischk08 | 0:34f3e0f37c55 | 3 | #define NIXIETUBE_H_ |
| fischk08 | 0:34f3e0f37c55 | 4 | |
| fischk08 | 0:34f3e0f37c55 | 5 | #include "mbed.h" |
| fischk08 | 0:34f3e0f37c55 | 6 | #include "rtos.h" |
| fischk08 | 0:34f3e0f37c55 | 7 | // How to deal with this problem https://developer.mbed.org/forum/mbed/topic/4388/ |
| fischk08 | 0:34f3e0f37c55 | 8 | class NixieTube |
| fischk08 | 0:34f3e0f37c55 | 9 | { |
| fischk08 | 0:34f3e0f37c55 | 10 | public: |
| fischk08 | 0:34f3e0f37c55 | 11 | NixieTube(PinName,PinName,PinName,PinName) ; |
| fischk08 | 0:34f3e0f37c55 | 12 | ~NixieTube(); |
| fischk08 | 0:34f3e0f37c55 | 13 | void start_nixie(); |
| fischk08 | 0:34f3e0f37c55 | 14 | void update_nixie_tube(int,int); |
| fischk08 | 0:34f3e0f37c55 | 15 | void set_dim(float,int); |
| fischk08 | 0:34f3e0f37c55 | 16 | private: |
| fischk08 | 0:34f3e0f37c55 | 17 | /** Copy constructor |
| fischk08 | 0:34f3e0f37c55 | 18 | * Disable because it is only declaration |
| fischk08 | 0:34f3e0f37c55 | 19 | */ |
| fischk08 | 0:34f3e0f37c55 | 20 | NixieTube(const NixieTube&); |
| fischk08 | 0:34f3e0f37c55 | 21 | |
| fischk08 | 0:34f3e0f37c55 | 22 | /** Copy assignment operators |
| fischk08 | 0:34f3e0f37c55 | 23 | * Disable because it is only declaration |
| fischk08 | 0:34f3e0f37c55 | 24 | */ |
| fischk08 | 0:34f3e0f37c55 | 25 | NixieTube& operator=(const NixieTube&); |
| fischk08 | 0:34f3e0f37c55 | 26 | DigitalOut _sdi; |
| fischk08 | 0:34f3e0f37c55 | 27 | DigitalOut _scl; |
| fischk08 | 0:34f3e0f37c55 | 28 | DigitalOut _rcl; |
| fischk08 | 0:34f3e0f37c55 | 29 | PwmOut _cen; |
| fischk08 | 0:34f3e0f37c55 | 30 | int digit1; |
| fischk08 | 0:34f3e0f37c55 | 31 | int digit2; |
| fischk08 | 0:34f3e0f37c55 | 32 | int digit3; |
| fischk08 | 0:34f3e0f37c55 | 33 | int digit4; |
| fischk08 | 0:34f3e0f37c55 | 34 | uint32_t delay1; |
| fischk08 | 0:34f3e0f37c55 | 35 | uint32_t delay2; |
| fischk08 | 0:34f3e0f37c55 | 36 | float brightness; |
| fischk08 | 0:34f3e0f37c55 | 37 | void nixie_thread(); |
| fischk08 | 0:34f3e0f37c55 | 38 | int nixie_id_convert(int); |
| fischk08 | 0:34f3e0f37c55 | 39 | void send_nixie_shiftreg(int, int, int); |
| fischk08 | 0:34f3e0f37c55 | 40 | Thread* thread; |
| fischk08 | 0:34f3e0f37c55 | 41 | |
| fischk08 | 0:34f3e0f37c55 | 42 | static void threadStarter(void const *p); |
| fischk08 | 0:34f3e0f37c55 | 43 | void threadWorker(); |
| fischk08 | 0:34f3e0f37c55 | 44 | Thread _thread; |
| fischk08 | 0:34f3e0f37c55 | 45 | |
| fischk08 | 0:34f3e0f37c55 | 46 | }; |
| fischk08 | 0:34f3e0f37c55 | 47 | |
| fischk08 | 0:34f3e0f37c55 | 48 | #endif /* NIXIETUBE_H_ */ |
| fischk08 | 0:34f3e0f37c55 | 49 |