Answer only on one SmartPort ID

Receiver polls all active IDs, then tries one inactive. Answering multiple IDs will starve other devices on bus and it will increase probability of address collision.
With 1 active address poll interval is ~24ms
This commit is contained in:
Petr Ledvina 2015-03-31 12:24:07 +02:00
parent 7f3f53d880
commit 3faa8a200b
1 changed files with 1 additions and 4 deletions

View File

@ -162,10 +162,7 @@ static void smartPortDataReceive(uint16_t c)
if (lastChar == FSSP_START_STOP) { if (lastChar == FSSP_START_STOP) {
smartPortState = SPSTATE_WORKING; smartPortState = SPSTATE_WORKING;
smartPortLastRequestTime = now; smartPortLastRequestTime = now;
if ((c == FSSP_SENSOR_ID1) || if (c == FSSP_SENSOR_ID1) {
(c == FSSP_SENSOR_ID2) ||
(c == FSSP_SENSOR_ID3) ||
(c == FSSP_SENSOR_ID4)) {
smartPortHasRequest = 1; smartPortHasRequest = 1;
// we only responde to these IDs // we only responde to these IDs
// the X4R-SB does send other IDs, we ignore them, but take note of the time // the X4R-SB does send other IDs, we ignore them, but take note of the time