Renamed mbus_recv_frame_dummy() to more descriptive mbus_purge_frames()
This commit is contained in:
parent
e70c07e8f3
commit
5f9052b284
@ -116,7 +116,7 @@ main(int argc, char **argv)
|
||||
return 1;
|
||||
}
|
||||
|
||||
mbus_recv_frame_dummy(handle);
|
||||
mbus_purge_frames(handle);
|
||||
|
||||
//
|
||||
// resend SND_NKE, maybe the first get lost
|
||||
@ -135,7 +135,7 @@ main(int argc, char **argv)
|
||||
return 1;
|
||||
}
|
||||
|
||||
mbus_recv_frame_dummy(handle);
|
||||
mbus_purge_frames(handle);
|
||||
|
||||
if (strlen(addr_str) == 16)
|
||||
{
|
||||
|
@ -114,7 +114,7 @@ main(int argc, char **argv)
|
||||
if (ret == -2)
|
||||
{
|
||||
/* check for more data (collision) */
|
||||
mbus_recv_frame_dummy(handle);
|
||||
mbus_purge_frames(handle);
|
||||
printf("Collision at address %d\n", address);
|
||||
continue;
|
||||
}
|
||||
@ -122,7 +122,7 @@ main(int argc, char **argv)
|
||||
if (mbus_frame_type(&reply) == MBUS_FRAME_TYPE_ACK)
|
||||
{
|
||||
/* check for more data (collision) */
|
||||
if (mbus_recv_frame_dummy(handle))
|
||||
if (mbus_purge_frames(handle))
|
||||
{
|
||||
printf("Collision at address %d\n", address);
|
||||
|
||||
|
@ -97,7 +97,7 @@ main(int argc, char **argv)
|
||||
if (ret == -2)
|
||||
{
|
||||
/* check for more data (collision) */
|
||||
mbus_recv_frame_dummy(handle);
|
||||
mbus_purge_frames(handle);
|
||||
printf("Collision at address %d\n", address);
|
||||
continue;
|
||||
}
|
||||
@ -105,7 +105,7 @@ main(int argc, char **argv)
|
||||
if (mbus_frame_type(&reply) == MBUS_FRAME_TYPE_ACK)
|
||||
{
|
||||
/* check for more data (collision) */
|
||||
if (mbus_recv_frame_dummy(handle))
|
||||
if (mbus_purge_frames(handle))
|
||||
{
|
||||
printf("Collision at address %d\n", address);
|
||||
continue;
|
||||
|
@ -1454,7 +1454,7 @@ mbus_recv_frame(mbus_handle * handle, mbus_frame *frame)
|
||||
return result;
|
||||
}
|
||||
|
||||
int mbus_recv_frame_dummy(mbus_handle *handle)
|
||||
int mbus_purge_frames(mbus_handle *handle)
|
||||
{
|
||||
int err, received;
|
||||
mbus_frame reply;
|
||||
@ -1810,14 +1810,14 @@ mbus_select_secondary_address(mbus_handle * handle, const char *mask)
|
||||
if (ret == -2)
|
||||
{
|
||||
/* check for more data (collision) */
|
||||
mbus_recv_frame_dummy(handle);
|
||||
mbus_purge_frames(handle);
|
||||
return MBUS_PROBE_COLLISION;
|
||||
}
|
||||
|
||||
if (mbus_frame_type(&reply) == MBUS_FRAME_TYPE_ACK)
|
||||
{
|
||||
/* check for more data (collision) */
|
||||
if (mbus_recv_frame_dummy(handle))
|
||||
if (mbus_purge_frames(handle))
|
||||
{
|
||||
return MBUS_PROBE_COLLISION;
|
||||
}
|
||||
|
@ -205,7 +205,7 @@ int mbus_recv_frame(mbus_handle * handle, mbus_frame *frame);
|
||||
*
|
||||
* @return Zero when nothing received, one otherwise.
|
||||
*/
|
||||
int mbus_recv_frame_dummy(mbus_handle * handle);
|
||||
int mbus_purge_frames(mbus_handle * handle);
|
||||
|
||||
/**
|
||||
* Sends frame using "unified" handle
|
||||
|
Loading…
x
Reference in New Issue
Block a user