Skip to content

Commit

Permalink
rename sub to show intent better
Browse files Browse the repository at this point in the history
  • Loading branch information
hartmutbehrens committed Jan 16, 2013
1 parent bce2a5c commit 198e86c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions c2e_udp.c
Expand Up @@ -132,7 +132,7 @@ void UDP_send_msg(unsigned char *message, uint32_t size, struct ip_addr *ip_addr
udp_remove(pcb);
}

static void process_received_data(unsigned char *data, uint32_t size)
static void transfer_to_CAN(unsigned char *data, uint32_t size)
{
uint32_t position = 0;
while (position < size) // more than one CAN frame might be embedded
Expand Down Expand Up @@ -166,7 +166,7 @@ void UDP_receive(void *arg, struct udp_pcb *pcb, struct pbuf *p, struct ip_addr
if ( message_starts_with(data, C2E_DATA_ID) ) // received a message with CAN data, so send it out on the CAN i/f
{
uint32_t id_size = sizeof(C2E_DATA_ID);
process_received_data(&data[id_size], (p->len - id_size) );
transfer_to_CAN(&data[id_size], (p->len - id_size) );
}
if ( message_starts_with(data, C2E_BROADCAST_ID) ) // found a gateway, so add the IP address to the list of known gateways
{
Expand Down

0 comments on commit 198e86c

Please sign in to comment.