mirror of
https://github.com/anklimov/lighthub
synced 2025-12-06 11:49:51 +03:00
Cross-compilaton for all platforms & binaries
This commit is contained in:
File diff suppressed because it is too large
Load Diff
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
Binary file not shown.
@@ -1517,6 +1517,33 @@ void printFirmwareVersionAndBuildOptions() {
|
|||||||
#else
|
#else
|
||||||
debugSerial<<F("\n(-)RESTART_LAN_ON_MQTT_ERRORS");
|
debugSerial<<F("\n(-)RESTART_LAN_ON_MQTT_ERRORS");
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
#ifdef CSSHDC_DISABLE
|
||||||
|
debugSerial<<F("\n(-)CCS811 & HDC1080");
|
||||||
|
#else
|
||||||
|
debugSerial<<F("\n(+)CCS811 & HDC1080");
|
||||||
|
#endif
|
||||||
|
#ifndef AC_DISABLE
|
||||||
|
debugSerial<<F("\n(+)AC HAIER");
|
||||||
|
#else
|
||||||
|
debugSerial<<F("\n(-)AC HAIER");
|
||||||
|
#endif
|
||||||
|
#ifndef MOTOR_DISABLE
|
||||||
|
debugSerial<<F("\n(+)MOTOR CTR");
|
||||||
|
#else
|
||||||
|
debugSerial<<F("\n(-)MOTOR CTR");
|
||||||
|
#endif
|
||||||
|
#ifndef SPILED_DISABLE
|
||||||
|
debugSerial<<F("\n(+)SPI LED");
|
||||||
|
#else
|
||||||
|
debugSerial<<F("\n(-)SPI LED");
|
||||||
|
#endif
|
||||||
|
#ifndef FASTLED
|
||||||
|
debugSerial<<F("\n(+)FASTLED");
|
||||||
|
#else
|
||||||
|
debugSerial<<F("\n(+)ADAFRUIT LED");
|
||||||
|
#endif
|
||||||
debugSerial<<endl;
|
debugSerial<<endl;
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -86,7 +86,7 @@ switch (item->getCmd())
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (pinFeedback && (g_APinDescription[pinFeedback].ulPinAttribute & PIN_ATTR_ANALOG) == PIN_ATTR_ANALOG)
|
if (pinFeedback && isAnalogPin(pinFeedback))
|
||||||
{
|
{
|
||||||
curPos=map(analogRead(pinFeedback),feedbackClosed,feedbackOpen,0,100);
|
curPos=map(analogRead(pinFeedback),feedbackClosed,feedbackOpen,0,100);
|
||||||
if (curPos<0) curPos=0;
|
if (curPos<0) curPos=0;
|
||||||
@@ -113,7 +113,7 @@ if (dif<-POS_ERR)
|
|||||||
//PIN_ATTR_ANALOG
|
//PIN_ATTR_ANALOG
|
||||||
// uint32_t attr = g_APinDescription[pinUp].ulPinAttribute;
|
// uint32_t attr = g_APinDescription[pinUp].ulPinAttribute;
|
||||||
// if ((attr & PIN_ATTR_PWM) == PIN_ATTR_PWM) ;
|
// if ((attr & PIN_ATTR_PWM) == PIN_ATTR_PWM) ;
|
||||||
|
#ifndef ESP32
|
||||||
if (digitalPinHasPWM(pinUp))
|
if (digitalPinHasPWM(pinUp))
|
||||||
{
|
{
|
||||||
int velocity = map(-dif, 0, 10, 0, 255);
|
int velocity = map(-dif, 0, 10, 0, 255);
|
||||||
@@ -121,6 +121,7 @@ if (digitalPinHasPWM(pinUp))
|
|||||||
analogWrite(pinUp,velocity);
|
analogWrite(pinUp,velocity);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
#endif
|
||||||
{
|
{
|
||||||
digitalWrite(pinUp,HIGH);
|
digitalWrite(pinUp,HIGH);
|
||||||
}
|
}
|
||||||
@@ -132,6 +133,7 @@ if (dif>POS_ERR)
|
|||||||
digitalWrite(pinUp,LOW);
|
digitalWrite(pinUp,LOW);
|
||||||
|
|
||||||
if (!item->getExt()) item->setExt(millis()+maxOnTime);
|
if (!item->getExt()) item->setExt(millis()+maxOnTime);
|
||||||
|
#ifndef ESP32
|
||||||
if (digitalPinHasPWM(pinDown))
|
if (digitalPinHasPWM(pinDown))
|
||||||
{
|
{
|
||||||
int velocity = map(dif, 0, 10, 0, 255);
|
int velocity = map(dif, 0, 10, 0, 255);
|
||||||
@@ -139,6 +141,7 @@ if (digitalPinHasPWM(pinDown))
|
|||||||
analogWrite(pinDown,velocity);
|
analogWrite(pinDown,velocity);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
#endif
|
||||||
{
|
{
|
||||||
digitalWrite(pinDown,HIGH);
|
digitalWrite(pinDown,HIGH);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -218,3 +218,33 @@
|
|||||||
#else
|
#else
|
||||||
#define W5500_ETHERNET_SHIELD
|
#define W5500_ETHERNET_SHIELD
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
#if defined(ARDUINO_ARCH_AVR)
|
||||||
|
#define PINS_COUNT NUM_DIGITAL_PINS
|
||||||
|
#define isAnalogPin(p) ((p >= 54) && (p<=69))
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined(__SAM3X8E__)
|
||||||
|
#define isAnalogPin(p) (g_APinDescription[p].ulPinAttribute & PIN_ATTR_ANALOG) == PIN_ATTR_ANALOG
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined(ARDUINO_ARCH_STM32)
|
||||||
|
#define PINS_COUNT NUM_DIGITAL_PINS
|
||||||
|
#define isAnalogPin(p) ((p >= 44) && (p<=57))
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined(ESP8266)
|
||||||
|
#define PINS_COUNT NUM_DIGITAL_PINS
|
||||||
|
#define isAnalogPin(p) ( p ==17 )
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined(ARDUINO_ARCH_ESP32)
|
||||||
|
#define PINS_COUNT NUM_DIGITAL_PINS
|
||||||
|
#define isAnalogPin(p) ((p ==4) || (p>=12)&& (p<=15) || (p>=25)&& (p<=27)||(p>=32)&& (p<=33) || (p>=37)&& (p<=38))
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if defined(NRF5)
|
||||||
|
#define PINS_COUNT NUM_DIGITAL_PINS
|
||||||
|
#define isAnalogPin(p) ((p >= 14) && (p<=21))
|
||||||
|
#endif
|
||||||
|
|||||||
7663
spare_files/flows (4).json
Normal file
7663
spare_files/flows (4).json
Normal file
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user