mirror of https://github.com/sfeakes/AqualinkD.git
Version 2.2.0b
parent
fb88438651
commit
f4b7bd91ff
|
@ -79,7 +79,8 @@ Designed to mimic AqualinkRS6 All Button keypad and (like the keypad) is used to
|
|||
* RS Serial protocol. AqualinkD has all Jandy control protocols except RS Serial.
|
||||
* Update homekit-aqualinkd to use new API & features.
|
||||
|
||||
# Update in (Pre) Release 2.2.0a
|
||||
# Update in (Pre) Release 2.2.0b
|
||||
* 2.2.0a (had some issues with compiler optimisation), please don't use or compile yourself.
|
||||
* Fixed RS-4 bug.
|
||||
* Increased timeout for startup probe
|
||||
* This release WILL require you to make aqualinkd.conf changes. <b>Make sure to read wiki section https://github.com/sfeakes/AqualinkD/wiki#Version_2</b>
|
||||
|
|
19
aq_panel.c
19
aq_panel.c
|
@ -59,6 +59,25 @@ void addPanelIAQTouchInterface() {
|
|||
_aqconfig_.paneltype_mask &= ~RSP_ONET;
|
||||
}
|
||||
|
||||
int PANEL_SIZE() {
|
||||
if ((_aqconfig_.paneltype_mask & RSP_4) == RSP_4)
|
||||
return 4;
|
||||
else if ((_aqconfig_.paneltype_mask & RSP_6) == RSP_6)
|
||||
return 6;
|
||||
else if ((_aqconfig_.paneltype_mask & RSP_8) == RSP_8)
|
||||
return 8;
|
||||
else if ((_aqconfig_.paneltype_mask & RSP_12) == RSP_12)
|
||||
return 10;
|
||||
else if ((_aqconfig_.paneltype_mask & RSP_10) == RSP_10)
|
||||
return 12;
|
||||
else if ((_aqconfig_.paneltype_mask & RSP_14) == RSP_14)
|
||||
return 14;
|
||||
else if ((_aqconfig_.paneltype_mask & RSP_16) == RSP_16)
|
||||
return 16;
|
||||
|
||||
LOG(AQUA_LOG,LOG_ERR, "Internal error, panel size not set, using 8\n");
|
||||
return 8;
|
||||
}
|
||||
//bool setPanel(const char *str);
|
||||
/*
|
||||
void panneltest() {
|
||||
|
|
|
@ -46,8 +46,10 @@ void changePanelToExtendedIDProgramming();
|
|||
#define isONET_ENABLED ((_aqconfig_.paneltype_mask & RSP_ONET) == RSP_ONET)
|
||||
#define isIAQT_ENABLED ((_aqconfig_.paneltype_mask & RSP_IAQT) == RSP_IAQT)
|
||||
#define isEXTP_ENABLED ((_aqconfig_.paneltype_mask & RSP_EXT_PROG) == RSP_EXT_PROG)
|
||||
//int PANEL_SIZE();
|
||||
int PANEL_SIZE();
|
||||
//
|
||||
//#define PANEL_SIZE PANEL_SIZE()
|
||||
/*
|
||||
#define PANEL_SIZE ((_aqconfig_.paneltype_mask & RSP_4) == RSP_4)?4:(\
|
||||
((_aqconfig_.paneltype_mask & RSP_6) == RSP_6)?6:(\
|
||||
((_aqconfig_.paneltype_mask & RSP_8) == RSP_8)?8:(\
|
||||
|
@ -55,7 +57,7 @@ void changePanelToExtendedIDProgramming();
|
|||
((_aqconfig_.paneltype_mask & RSP_12) == RSP_12)?12:(\
|
||||
((_aqconfig_.paneltype_mask & RSP_14) == RSP_14)?14:(\
|
||||
((_aqconfig_.paneltype_mask & RSP_16) == RSP_16)?16:0))))))
|
||||
|
||||
*/
|
||||
|
||||
|
||||
#ifndef AQ_RS16
|
||||
|
|
|
@ -333,7 +333,8 @@ void queueGetProgramData(emulation_type source_type, struct aqualinkdata *aq_dat
|
|||
} else if ( source_type == IAQTOUCH) {
|
||||
aq_programmer(AQ_GET_IAQTOUCH_SETPOINTS, NULL, aq_data);
|
||||
if (_aqconfig_.use_panel_aux_labels)
|
||||
aq_programmer(AQ_GET_IAQTOUCH_AUX_LABELS, NULL, aq_data);
|
||||
aq_programmer(AQ_GET_AUX_LABELS, NULL, aq_data);
|
||||
//aq_programmer(AQ_GET_IAQTOUCH_AUX_LABELS, NULL, aq_data);
|
||||
#endif
|
||||
#ifdef AQ_PDA
|
||||
} else if ( source_type == AQUAPDA) {
|
||||
|
|
10
aqualinkd.c
10
aqualinkd.c
|
@ -204,7 +204,7 @@ int16_t RS16_endswithLEDstate(char *msg)
|
|||
aqledstate state = LED_S_UNKNOWN;
|
||||
|
||||
//if (_aqconfig_.rs_panel_size < 16)
|
||||
if (PANEL_SIZE < 16)
|
||||
if (PANEL_SIZE() < 16)
|
||||
return false;
|
||||
|
||||
sp = strrchr(msg, ' ');
|
||||
|
@ -361,8 +361,8 @@ void _processMessage(char *message, bool reset)
|
|||
#ifdef AQ_RS16
|
||||
//if ( _aqconfig_.rs_panel_size >= 16) {
|
||||
//if ( (int)PANEL_SIZE >= 16) { // NSF No idea why this fails on RS-4, but it does. Come back and find out why
|
||||
if ( 16 <= (int)PANEL_SIZE ) {
|
||||
printf("Panel size %d What the fuck am I doing here\n",PANEL_SIZE);
|
||||
if ( PANEL_SIZE() >= 16 ) {
|
||||
printf("Panel size %d What the fuck am I doing here\n",PANEL_SIZE());
|
||||
if ((msg_loop & MSG_RS13BUTTON) != MSG_RS13BUTTON)
|
||||
_aqualink_data.aqbuttons[13].led->state = OFF;
|
||||
if ((msg_loop & MSG_RS14BUTTON) != MSG_RS14BUTTON)
|
||||
|
@ -575,7 +575,7 @@ void _processMessage(char *message, bool reset)
|
|||
|
||||
#ifdef AQ_RS16
|
||||
//else if ( _aqconfig_.rs_panel_size >= 16 && (rs16 = RS16_endswithLEDstate(msg)) != 0 )
|
||||
else if (PANEL_SIZE >= 16 && (rs16 = RS16_endswithLEDstate(msg)) != 0 )
|
||||
else if (PANEL_SIZE() >= 16 && (rs16 = RS16_endswithLEDstate(msg)) != 0 )
|
||||
{
|
||||
msg_loop |= rs16;
|
||||
// Do nothing, just stop other else if statments executing
|
||||
|
@ -1041,7 +1041,7 @@ int main(int argc, char *argv[])
|
|||
LOG(AQUA_LOG,LOG_NOTICE, "Panel set to %s%s-%d %s%s %s\n",
|
||||
isRS_PANEL?"RS":"",
|
||||
isPDA_PANEL?"PDA":"", // No need for both of these, but for error validation leave it in.
|
||||
PANEL_SIZE,
|
||||
PANEL_SIZE(),
|
||||
isCOMBO_PANEL?"Combo Pool/Spa":"",
|
||||
isSINGLE_DEV_PANEL?"Pool/Spa Only":"",
|
||||
isDUAL_EQPT_PANEL?"Dual Equipment":"");
|
||||
|
|
|
@ -619,7 +619,9 @@ void *get_aqualink_iaqtouch_aux_labels( void *ptr )
|
|||
*/
|
||||
const char *buf;
|
||||
int aux;
|
||||
for(i=1; i < 18; i++) // NSF Need to take out hard code of 18
|
||||
// Loop over panel buttons or lines which ever is lowest.
|
||||
//for(i=1; i < 18; i++) // NSF Need to take out hard code of 18
|
||||
for(i=1; i < PANEL_SIZE(); i++)
|
||||
{
|
||||
buf = iaqtGetTableInfoLine(i);
|
||||
//printf("**** BUF '%s'\n",aux,buf);
|
||||
|
|
|
@ -387,8 +387,8 @@ bool log_qeuiptment_status(struct aqualinkdata *aq_data)
|
|||
}
|
||||
|
||||
#ifdef AQ_RS16
|
||||
//else if (PANEL_SIZE >= 16 ) { // This fails on RS4, comeback and find out why. // Run over devices that have no status LED's on RS12&16 panels.
|
||||
else if ( 16 <= (int)PANEL_SIZE ) {
|
||||
else if (PANEL_SIZE() >= 16 ) { // This fails on RS4, comeback and find out why. // Run over devices that have no status LED's on RS12&16 panels.
|
||||
//else if ( 16 <= (int)PANEL_SIZE ) {
|
||||
int j;
|
||||
for (i=2; i <= ONETOUCH_LINES; i++) {
|
||||
for (j = aq_data->rs16_vbutton_start; j <= aq_data->rs16_vbutton_end; j++) {
|
||||
|
@ -464,7 +464,7 @@ void rs16led_update(struct aqualinkdata *aq_data, int updated) {
|
|||
static unsigned char updates = '\0';
|
||||
int i;
|
||||
|
||||
if (PANEL_SIZE < 16)
|
||||
if (PANEL_SIZE() < 16)
|
||||
return;
|
||||
|
||||
if (updated == -1) {
|
||||
|
@ -529,7 +529,7 @@ bool new_menu(struct aqualinkdata *aq_data)
|
|||
// End of equiptment status chain of menus, reset any pump that wasn't listed in menus
|
||||
pump_update(aq_data, -1);
|
||||
#ifdef AQ_RS16
|
||||
if (PANEL_SIZE >= 16)
|
||||
if (PANEL_SIZE() >= 16)
|
||||
rs16led_update(aq_data, -1);
|
||||
#endif
|
||||
}
|
||||
|
|
Binary file not shown.
Loading…
Reference in New Issue