Newer
Older
// Auto-generated template file: command_ECHO1.tpl.c
// Generation timestamp: 2021-06-21 19:42:34.864200
#include "../typedefs.h"
#include "../communication.h"
#include "../hardware.h"
err_t command_ECHO1(void) {
// Command: ECHO1
// Description: Echo (1 byte)
//
// Request code: CMDCODE_ECHO1_REQ
// Response code: CMDCODE_ECHO1_REQ
// Request payload (length in bytes is 1):
// field #0 (1 byte) [type: uint8_t ] : VALUE (Echoed byte)
// Response payload (length in bytes is 1):
// field #0 (1 byte) [type: uint8_t ] : VALUE (Echoed byte)
// Auto-generated section: request payload fields reading
uint8_t req_value = (uint8_t)communication_request_payload_retrieve_uint8_t();
// End of auto-generated section
// USER CODE HERE
// TODO implement command callback function command_ECHO1
// TODO: assign response field VALUE in command ECHO1 callback
uint8_t resp_value = -1;
// Auto-generated section: response payload fields writing
communication_response_payload_appender_reset();
communication_response_payload_append_uint8_t((uint8_t)resp_value);
return NOERR;
// End of auto-generated section
}