RS232 control for TVOne products
spk_tvone_mbed.h@0:533cfae24a1b, 2012-04-15 (annotated)
- Committer:
- tobyspark
- Date:
- Sun Apr 15 20:58:35 2012 +0000
- Revision:
- 0:533cfae24a1b
- Child:
- 1:349d6da461df
rolling files into library
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
tobyspark | 0:533cfae24a1b | 1 | // *spark audio-visual |
tobyspark | 0:533cfae24a1b | 2 | // RS232 Control for TV-One products |
tobyspark | 0:533cfae24a1b | 3 | // Good for 1T-C2-750, others will need some extra work |
tobyspark | 0:533cfae24a1b | 4 | // Copyright *spark audio-visual 2009-2011 |
tobyspark | 0:533cfae24a1b | 5 | |
tobyspark | 0:533cfae24a1b | 6 | #ifndef SPKTVOne_mBed_h |
tobyspark | 0:533cfae24a1b | 7 | #define SPKTVOne_mBed_h |
tobyspark | 0:533cfae24a1b | 8 | |
tobyspark | 0:533cfae24a1b | 9 | #include "spk_tvone.h" |
tobyspark | 0:533cfae24a1b | 10 | #include "mbed.h" |
tobyspark | 0:533cfae24a1b | 11 | |
tobyspark | 0:533cfae24a1b | 12 | class SPKTVOne |
tobyspark | 0:533cfae24a1b | 13 | { |
tobyspark | 0:533cfae24a1b | 14 | public: |
tobyspark | 0:533cfae24a1b | 15 | SPKTVOne(PinName txPin, PinName rxPin, PinName signWritePin = NC, PinName signErrorPin = NC, Serial *debugSerial = NULL); |
tobyspark | 0:533cfae24a1b | 16 | |
tobyspark | 0:533cfae24a1b | 17 | bool command(uint8_t channel, uint8_t window, int32_t func, int32_t payload); |
tobyspark | 0:533cfae24a1b | 18 | |
tobyspark | 0:533cfae24a1b | 19 | void setCustomResolutions(); |
tobyspark | 0:533cfae24a1b | 20 | bool setHDCPOff(); |
tobyspark | 0:533cfae24a1b | 21 | |
tobyspark | 0:533cfae24a1b | 22 | private: |
tobyspark | 0:533cfae24a1b | 23 | // Tx and Wait LED pins to go here |
tobyspark | 0:533cfae24a1b | 24 | void set1920x480(int resStoreNumber); |
tobyspark | 0:533cfae24a1b | 25 | void set1600x600(int resStoreNumber); |
tobyspark | 0:533cfae24a1b | 26 | |
tobyspark | 0:533cfae24a1b | 27 | Serial *serial; |
tobyspark | 0:533cfae24a1b | 28 | Serial *debug; |
tobyspark | 0:533cfae24a1b | 29 | |
tobyspark | 0:533cfae24a1b | 30 | DigitalOut *writeDO; |
tobyspark | 0:533cfae24a1b | 31 | DigitalOut *errorDO; |
tobyspark | 0:533cfae24a1b | 32 | Timeout signErrorTimeout; |
tobyspark | 0:533cfae24a1b | 33 | void signErrorOff(); |
tobyspark | 0:533cfae24a1b | 34 | }; |
tobyspark | 0:533cfae24a1b | 35 | |
tobyspark | 0:533cfae24a1b | 36 | #endif |