untested new onewire commands (all except search algos)
This commit is contained in:
@@ -33,6 +33,14 @@ void com_respond_buf(TF_ID frame_id, TF_TYPE type, const uint8_t *buf, uint32_t
|
||||
}
|
||||
|
||||
|
||||
void com_respond_pb(TF_ID frame_id, TF_TYPE type, PayloadBuilder *pb)
|
||||
{
|
||||
uint32_t len;
|
||||
uint8_t *buf = pb_close(pb, &len);
|
||||
com_respond_buf(frame_id, type, buf, len);
|
||||
}
|
||||
|
||||
|
||||
void com_respond_ok(TF_ID frame_id)
|
||||
{
|
||||
com_respond_buf(frame_id, MSG_SUCCESS, NULL, 0);
|
||||
|
||||
@@ -34,6 +34,15 @@ com_respond_snprintf(TF_ID frame_id, TF_TYPE type, const char *format, ...);
|
||||
*/
|
||||
void com_respond_buf(TF_ID frame_id, TF_TYPE type, const uint8_t *buf, uint32_t len);
|
||||
|
||||
/**
|
||||
* Respond using a payload builder's content
|
||||
*
|
||||
* @param type - response type byte
|
||||
* @param frame_id - ID of the original msg
|
||||
* @param pb - builder
|
||||
*/
|
||||
void com_respond_pb(TF_ID frame_id, TF_TYPE type, PayloadBuilder *pb);
|
||||
|
||||
/**
|
||||
* Respond to a TF message with empty body and MSG_SUCCESS type.
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user