You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
19 lines
583 B
19 lines
583 B
#include "protocol_event_bus_sender.hpp"
|
|
|
|
#include "api/api.hpp"
|
|
namespace iflytop {
|
|
using namespace std;
|
|
|
|
void ProtocolEventBusSender::initialize(IZCanCmder* zcan_cmder) { m_zcan_cmder = zcan_cmder; }
|
|
|
|
void ProtocolEventBusSender::push_reg_state_change_event(int32_t moduleid, int32_t event_id, int32_t eventval) {
|
|
zcr_cmd_header_t rx_cmd_header = {0};
|
|
int32_t data[4];
|
|
data[0] = kreg_change_event;
|
|
data[1] = moduleid;
|
|
data[2] = event_id;
|
|
data[3] = eventval;
|
|
m_zcan_cmder->triggerEvent(&rx_cmd_header, (uint8_t*)data, sizeof(data));
|
|
}
|
|
|
|
} // namespace iflytop
|