Skip to main content
aboutsummaryrefslogtreecommitdiffstats
blob: 933ec228c475a8b3b519e1f3887e69013afccad9 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
/**
 * @author generated by eTrice
 *
 * Header File of ActorClass AFileReader
 * 
 */

#ifndef _AFILEREADER_H_
#define _AFILEREADER_H_

#include "etDatatypes.h"
#include "messaging/etMessage.h"

#include "FileReaderProtocol.h"


typedef struct AFileReader AFileReader;

/* const part of ActorClass (ROM) */
typedef struct AFileReader_const {
	/* simple ports */
	const FileReaderProtocolPort outPort;
	
	/* data receive ports */

	/* saps */
	
	/* replicated ports */
	
	/* services */
} AFileReader_const;


/* constant for state machine data */
#define AFILEREADER_HISTORY_SIZE 2

/* variable part of ActorClass (RAM) */
struct AFileReader {
	const AFileReader_const* const constData;
	
	/* data send ports */

	/*--------------------- attributes ---------------------*/
	FILE* f;
	
	
		/* state machine variables */
		etInt16 state;
		etInt16 history[AFILEREADER_HISTORY_SIZE];
};

void AFileReader_init(AFileReader* self);

void AFileReader_receiveMessage(void* self, void* ifitem, const etMessage* msg);


/*--------------------- operations ---------------------*/


#endif /* _AFILEREADER_H_ */

Back to the top