From cce0df1a7cc9cdb3c54dff475c19c74d4d7247bc Mon Sep 17 00:00:00 2001 From: skarg Date: Tue, 15 Dec 2015 17:31:20 +0000 Subject: [PATCH] Removed max-master timeout in NO TOKEN state as this was causing issues and didn't have any basis in the standard. Thank you, Michael Hall. --- bacnet-stack/src/mstp.c | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/bacnet-stack/src/mstp.c b/bacnet-stack/src/mstp.c index d53002c8..acdf1346 100644 --- a/bacnet-stack/src/mstp.c +++ b/bacnet-stack/src/mstp.c @@ -589,7 +589,7 @@ bool MSTP_Master_Node_FSM( uint8_t next_poll_station = 0; uint8_t next_this_station = 0; uint8_t next_next_station = 0; - uint16_t my_timeout = 10, ns_timeout = 0, mm_timeout = 0; + uint16_t my_timeout = 10, ns_timeout = 0; /* transition immediately to the next state */ bool transition_now = false; MSTP_MASTER_STATE master_state = mstp_port->master_state; @@ -950,11 +950,7 @@ bool MSTP_Master_Node_FSM( } else { ns_timeout = Tno_token + (Tslot * (mstp_port->This_Station + 1)); - mm_timeout = - Tno_token + (Tslot * (mstp_port->Nmax_master + 1)); - if ((mstp_port->SilenceTimer((void *) mstp_port) < ns_timeout) - || (mstp_port->SilenceTimer((void *) mstp_port) > - mm_timeout)) { + if (mstp_port->SilenceTimer((void *) mstp_port) < ns_timeout) { /* GenerateToken */ /* Assume that this node is the lowest numerical address */ /* on the network and is empowered to create a token. */