Peter Drescher's library for the Embedded Artists E-paper display, but modified to also support the LPC4088 QuickStart Board
Fork of EaEpaper by
Diff: EPD.h
- Revision:
- 3:6fb3e296a6fd
- Parent:
- 0:fedcef5319f5
diff -r 1f3672176ca3 -r 6fb3e296a6fd EPD.h --- a/EPD.h Sun Nov 10 19:32:53 2013 +0000 +++ b/EPD.h Wed Dec 04 12:51:40 2013 +0000 @@ -16,7 +16,7 @@ #define EPD_H #include "mbed.h" -#include "BurstSPI.h" +//#include "BurstSPI.h" #define PROGMEM @@ -41,12 +41,21 @@ DigitalOut EPD_Pin_PANEL_ON; DigitalOut EPD_Pin_BORDER; DigitalOut EPD_Pin_DISCHARGE; +#if defined(TARGET_LPC4088) + DigitalOut EPD_Pin_PWM; +#elif PwmOut EPD_Pin_PWM; +#endif DigitalOut EPD_Pin_RESET; DigitalIn EPD_Pin_BUSY; DigitalOut EPD_Pin_EPD_CS; +#if defined(TARGET_LPC4088) + SPI spi_; + Ticker pwmTicker; +#elif BurstSPI spi_; - +#endif + EPD_size size; uint16_t stage_time; uint16_t factored_stage_time; @@ -64,6 +73,12 @@ void SPI_put(uint8_t c); void SPI_put_wait(uint8_t c, DigitalIn busy_pin); void SPI_send(DigitalOut cs_pin, const uint8_t *buffer, uint16_t length); + + void PWM_start(); + void PWM_stop(); +#if defined(TARGET_LPC4088) + void PWM_flip(); +#endif public: // power up and power down the EPD panel