|
Last change
on this file since 9 was
3,
checked in by markus, 7 years ago
|
|
Setup project structure
|
|
File size:
1.2 KB
|
| Line | |
|---|
| 1 | /* IRLibSendBase.h |
|---|
| 2 | * Part of IRLib Library for Arduino receiving, decoding, and sending |
|---|
| 3 | * infrared signals. See COPYRIGHT.txt and LICENSE.txt for more information. |
|---|
| 4 | */ |
|---|
| 5 | /* |
|---|
| 6 | * This module contains the base classes for sending. You will not create instances |
|---|
| 7 | * of these classes, rather you will use them as base classes in creating derived |
|---|
| 8 | * protocol specific decoders. Each protocol specific send class begins |
|---|
| 9 | * by calling enableIROut(uint8_t kHz) to set the carrier frequency. |
|---|
| 10 | * It then calls mark(int usec) and space(inc usec) to transmit marks and |
|---|
| 11 | * spaces of varying length of microseconds in the manner which the protocol defines. |
|---|
| 12 | */ |
|---|
| 13 | #ifndef IRLIBSENDBASE_H |
|---|
| 14 | #define IRLIBSENDBASE_H |
|---|
| 15 | |
|---|
| 16 | #include "IRLibProtocols.h" |
|---|
| 17 | |
|---|
| 18 | class IRsendBase { |
|---|
| 19 | public: |
|---|
| 20 | IRsendBase(); |
|---|
| 21 | void sendGeneric(uint32_t data, uint8_t numBits, uint16_t headMark, uint16_t headSpace, |
|---|
| 22 | uint16_t markOne, uint16_t markZero, uint16_t spaceOne, uint16_t spaceZero, |
|---|
| 23 | uint8_t kHz, bool stopBits, uint32_t maxExtent=0); |
|---|
| 24 | protected: |
|---|
| 25 | void enableIROut(uint8_t khz); |
|---|
| 26 | void mark(uint16_t usec); |
|---|
| 27 | void space(uint16_t usec); |
|---|
| 28 | uint32_t extent; |
|---|
| 29 | uint8_t onTime,offTime,iLength;//used by bit-bang output. |
|---|
| 30 | }; |
|---|
| 31 | |
|---|
| 32 | #endif //IRLIBSENDBASE_H |
|---|
| 33 | |
|---|
Note: See
TracBrowser
for help on using the repository browser.