ApraLinuxUtils 1.0.0
C++ utility library for embedded Linux systems
 
Loading...
Searching...
No Matches
I2CTransactionMessage.h
Go to the documentation of this file.
1/*
2 * I2CTransactionMessage.h
3 *
4 * Copyright (c) 2024 Apra Labs
5 *
6 * This file is part of ApraUtils.
7 *
8 * Licensed under the MIT License.
9 * See LICENSE file in the project root for full license information.
10 */
11
12#ifndef INCLUDES_APRA_MODELS_I2CTRANSACTIONMESSAGE_H_
13#define INCLUDES_APRA_MODELS_I2CTRANSACTIONMESSAGE_H_
14
15#include <models/Message.h>
16#include <models/I2CMessage.h>
17#include <models/I2CError.h>
19
20namespace apra
21{
23{
24public:
26 I2C_Transaction_Message(uint16_t chipNumber,
27 vector<I2C_Message> messageQueue,
28 uint64_t transactionDelayUsec = 0);
32 void setError(I2CError error);
33 vector<I2C_Message>& getAllMessages();
34 void registerEventHandle(void *callback, void *context);
35 void publishTransaction();
36 uint16_t m_chipNumber;
39 vector<I2C_Message> m_messages;
40protected:
44};
45
46} /* namespace apra */
47
48#endif /* INCLUDES_APRA_MODELS_I2CTRANSACTIONMESSAGE_H_ */
void * I2CEventCallback(void *context, apra::I2C_Transaction_Message message)
vector< I2C_Message > & getAllMessages()
void registerEventHandle(void *callback, void *context)
I2C_Transaction_Message & operator=(const I2C_Transaction_Message &other)