mirror of https://github.com/arendst/Tasmota.git
commit
b2f03d3197
|
@ -66,9 +66,13 @@ RA8876::RA8876(int8_t cs,int8_t mosi,int8_t miso,int8_t sclk,int8_t bp) : Render
|
|||
//#define RA8876_CS_LOW digitalWrite(m_csPin, LOW)
|
||||
//#define RA8876_CS_HIGH digitalWrite(m_csPin, HIGH)
|
||||
|
||||
#ifdef ESP8266
|
||||
#define RA8876_CS_LOW GPOC=(1<<m_csPin);
|
||||
#define RA8876_CS_HIGH GPOS=(1<<m_csPin);
|
||||
|
||||
#else
|
||||
#define RA8876_CS_LOW digitalWrite(1<<m_csPin,0);
|
||||
#define RA8876_CS_HIGH digitalWrite(1<<m_csPin,1);
|
||||
#endif
|
||||
/*
|
||||
extern void ICACHE_RAM_ATTR RA8876_digitalWrite(uint8_t pin, uint8_t val) {
|
||||
//stopWaveform(pin);
|
||||
|
|
|
@ -17,6 +17,7 @@
|
|||
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
|
||||
#ifdef USE_SCRIPT
|
||||
#ifndef USE_RULES
|
||||
/*********************************************************************************************\
|
||||
|
@ -60,6 +61,10 @@ keywords if then else endif, or, and are better readable for beginners (others m
|
|||
#define SCRIPT_MAXPERM (PMEM_SIZE)-4/sizeof(float)
|
||||
#define MAX_SCRIPT_SIZE MAX_RULE_SIZE*MAX_RULE_SETS
|
||||
|
||||
|
||||
uint32_t EncodeLightId(uint8_t relay_id);
|
||||
uint32_t DecodeLightId(uint32_t hue_id);
|
||||
|
||||
// offsets epoch readings by 1.1.2019 00:00:00 to fit into float with second resolution
|
||||
#define EPOCH_OFFSET 1546300800
|
||||
|
||||
|
@ -2028,6 +2033,7 @@ char *getop(char *lp, uint8_t *operand) {
|
|||
}
|
||||
|
||||
|
||||
#ifdef ESP8266
|
||||
#if defined(ARDUINO_ESP8266_RELEASE_2_3_0) || defined(ARDUINO_ESP8266_RELEASE_2_4_0) || defined(ARDUINO_ESP8266_RELEASE_2_4_1)
|
||||
// All version before core 2.4.2
|
||||
// https://github.com/esp8266/Arduino/issues/2557
|
||||
|
@ -2050,6 +2056,12 @@ uint16_t GetStack(void) {
|
|||
return (4 * (sp - g_pcont->stack));
|
||||
}
|
||||
#endif
|
||||
#else
|
||||
uint16_t GetStack(void) {
|
||||
register uint8_t *sp asm("a1");
|
||||
return (sp - pxTaskGetStackStart(NULL));
|
||||
}
|
||||
#endif
|
||||
|
||||
char *GetStringResult(char *lp,uint8_t lastop,char *cp,JsonObject *jo) {
|
||||
uint8_t operand=0;
|
||||
|
|
Loading…
Reference in New Issue