Skip to content

Commit

Permalink
Merge pull request #14 from PDXostc/enable_loopback_processing
Browse files Browse the repository at this point in the history
Enable process of loopback signals
  • Loading branch information
magnusfeuer committed Apr 17, 2019
2 parents f03dd7b + 3d2ab5f commit 414f70e
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
4 changes: 4 additions & 0 deletions rmc_internal.h
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,10 @@ typedef struct rmc_connection {
// are tied toegther through the circ_buf_init() call.
// One byte extra needed by circ buf for housekeeping reasons.
// FIXME: Use shared circular buffer across all rmc_connections for both read and write.
// Right now we allocate 128K of ram even if the rmc_connection_t struct is not
// in use (nobody connected), or if there are currently no buffered data.
// At the very least allocate memory only for rmc_connections that are
// actually connected
uint8_t read_buf_data[RMC_MAX_PACKET];

// Circular buffer of pending data read.
Expand Down
4 changes: 2 additions & 2 deletions rmc_sub_read.c
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,9 @@ static int decode_unsubscribed_multicast(rmc_sub_context_t* ctx,
return 0;
}


if (pack_hdr->node_id == ctx->node_id) {
RMC_LOG_DEBUG("Ignoring announce from self.");
return 0;
RMC_LOG_COMMENT("Processing announce from self.");
}

RMC_LOG_COMMENT("Len[%d] Pid[%lu] - Announce!",
Expand Down

0 comments on commit 414f70e

Please sign in to comment.