F´ Flight Software - C/C++ Documentation NASA-v1.6.0
A framework for building embedded system applications to NASA flight quality standards.
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
AsyncTesterHelpers.cpp
Go to the documentation of this file.
1// ======================================================================
2// \title AsyncTesterHelpers.cpp
3// \author T. Chieu
4// \brief cpp file for async tester helper functions
5//
6// \copyright
7// Copyright (C) 2009-2023 California Institute of Technology.
8// ALL RIGHTS RESERVED. United States Government Sponsorship
9// acknowledged.
10//
11// ======================================================================
12
13#include "test/ut/Tester.hpp"
14
15void Tester ::connectAsyncPorts() {
16 // arrayArgsAsync
17 for (NATIVE_INT_TYPE i = 0; i < 2; ++i) {
18 this->connect_to_arrayArgsAsync(i, this->component.get_arrayArgsAsync_InputPort(i));
19 }
20
21 // enumArgsAsync
22 for (NATIVE_INT_TYPE i = 0; i < 2; ++i) {
23 this->connect_to_enumArgsAsync(i, this->component.get_enumArgsAsync_InputPort(i));
24 }
25
26 // noArgsAsync
27 for (NATIVE_INT_TYPE i = 0; i < 2; ++i) {
28 this->connect_to_noArgsAsync(i, this->component.get_noArgsAsync_InputPort(i));
29 }
30
31 // primitiveArgsAsync
32 for (NATIVE_INT_TYPE i = 0; i < 2; ++i) {
33 this->connect_to_primitiveArgsAsync(i, this->component.get_primitiveArgsAsync_InputPort(i));
34 }
35
36 // stringArgsAsync
37 for (NATIVE_INT_TYPE i = 0; i < 2; ++i) {
38 this->connect_to_stringArgsAsync(i, this->component.get_stringArgsAsync_InputPort(i));
39 }
40
41 // structArgsAsync
42 for (NATIVE_INT_TYPE i = 0; i < 2; ++i) {
43 this->connect_to_structArgsAsync(i, this->component.get_structArgsAsync_InputPort(i));
44 }
45
46 // serialAsync
47 for (NATIVE_INT_TYPE i = 0; i < 3; ++i) {
48 this->connect_to_serialAsync(i, this->component.get_serialAsync_InputPort(i));
49 }
50
51 // serialAsyncAssert
52 this->connect_to_serialAsyncAssert(0, this->component.get_serialAsyncAssert_InputPort(0));
53
54 // serialAsyncBlockPriority
55 this->connect_to_serialAsyncBlockPriority(0, this->component.get_serialAsyncBlockPriority_InputPort(0));
56
57 // serialAsyncDropPriority
58 this->connect_to_serialAsyncDropPriority(0, this->component.get_serialAsyncDropPriority_InputPort(0));
59}
60
62 return component.doDispatch();
63}
PlatformIntType NATIVE_INT_TYPE
Definition BasicTypes.h:51