diff --git a/Configurations/RTApp-AtcaIop.cfg b/Configurations/RTApp-AtcaIop.cfg index e2fe0a4..70a029c 100644 --- a/Configurations/RTApp-AtcaIop.cfg +++ b/Configurations/RTApp-AtcaIop.cfg @@ -7,11 +7,15 @@ Class = "EPICS::EPICSPV" PVName = "ISTTOK:central:MARTe2-Status" PVType = "int32" + NumberOfElements = "1" + Timeout = 2.0 } +PV_COMMAND = { Class = "EPICS::EPICSPV" PVName = "ISTTOK:central:MARTe2-Command" PVType = "uint32" + NumberOfElements = "1" + Timeout = 2.0 Event = { Destination = "StateMachine" PVValue = "Function" @@ -22,6 +26,8 @@ Class = "EPICS::EPICSPV" PVName = "ISTTOK:central:MARTe2-Reset" PVType = "uint32" + NumberOfElements = "1" + Timeout = 2.0 Event = { Destination = "StateMachine" PVValue = "Ignore" @@ -500,6 +506,7 @@ $IsttokApp = { DataSource = "DDB1" Type = "float32" NumberOfElements = "14" + NumberOfDimensions = "1" } } } @@ -549,11 +556,13 @@ $IsttokApp = { EO = { DataSource = AtcaIopConfig_DS Type = int32 + NumberOfDimensions = "1" NumberOfElements = "16" Trigger = 1 } WO = { DataSource = AtcaIopConfig_DS + NumberOfDimensions = "1" NumberOfElements = "16" Type = float32 } @@ -707,10 +716,12 @@ $IsttokApp = { CounterLi = { DataSource = "EPICSCAOutput" Type = "uint32" + NumberOfElements = "1" } TimeLi = { DataSource = "EPICSCAOutput" Type = "uint32" + NumberOfElements = "1" } TimeoutCountLi = { DataSource = "EPICSCAOutput" diff --git a/DataSources/AtcaIop/AtcaIopADC.cpp b/DataSources/AtcaIop/AtcaIopADC.cpp index fe70b2a..08d55a1 100644 --- a/DataSources/AtcaIop/AtcaIopADC.cpp +++ b/DataSources/AtcaIop/AtcaIopADC.cpp @@ -712,7 +712,6 @@ ErrorManagement::ErrorType AtcaIopADC::Execute(ExecutionInfo& info) { float64 t = counterAndTimer[1]; t /= 1e6; - // Compute simulated Sinus Signals return err; } diff --git a/DataSources/AtcaIop/AtcaIopConfig.cpp b/DataSources/AtcaIop/AtcaIopConfig.cpp index 54bd375..56b6a57 100644 --- a/DataSources/AtcaIop/AtcaIopConfig.cpp +++ b/DataSources/AtcaIop/AtcaIopConfig.cpp @@ -54,7 +54,6 @@ namespace MARTe { DataSourceI(), MessageI() { devFileDescriptor = -1; - //numberOfDACsEnabled = 0u; //isMaster = 0u; deviceName = ""; boardId = 0u; @@ -62,7 +61,6 @@ namespace MARTe { uint32 n; synchCounter = 0u; - //channelsMemory = NULL_PTR(float32 *); eoValues = NULL_PTR(int32 *); woValues = NULL_PTR(float32 *); eoWriteFlag = false; @@ -88,9 +86,6 @@ namespace MARTe { if (woValues != NULL_PTR(float32 *)) { delete[] woValues; } - //if (channelsMemory != NULL_PTR(float32 *)) { - //delete[] channelsMemory; - //} } bool AtcaIopConfig::AllocateMemory() { @@ -114,14 +109,6 @@ namespace MARTe { else { ok = false; } - /* - bool ok = (signalIdx < (ATCA_IOP_MAX_DAC_CHANNELS)); - if (ok) { - if (channelsMemory != NULL_PTR(float32 *)) { - signalAddress = &(channelsMemory[signalIdx]); - } - } - */ return ok; } @@ -313,7 +300,6 @@ namespace MARTe { ErrorManagement::ErrorType err; REPORT_ERROR(ErrorManagement::Information, "AtcaIopConfig::WriteEoWo. Got Message!"); - //ret = err.ErrorsCleared(); eoWriteFlag = true; return err; } @@ -339,13 +325,12 @@ namespace MARTe { REPORT_ERROR(ErrorManagement::ParametersError, "Fail Write wo0:%6.3f", woValues[0]); ok = false; } - /* Reset is done by fiber + /* Reset may be done by fiber... */ rv = ioctl(devFileDescriptor, ATCA_PCIE_IOPT_RST_INTEG); if (rv ) { - REPORT_ERROR(ErrorManagement::ParametersError, "Fail reset Integrators"); + REPORT_ERROR(ErrorManagement::ParametersError, "Fail reset Integrator regs"); ok = false; } - */ return ok; } @@ -353,4 +338,4 @@ namespace MARTe { CLASS_METHOD_REGISTER(AtcaIopConfig, WriteEoWo) } -// vim: syntax=cpp ts=4 sw=4 sts=4 sr et +// vim: syntax=cpp ts=2 sw=2 sts=2 sr et diff --git a/DataSources/AtcaIop/AtcaIopConfig.h b/DataSources/AtcaIop/AtcaIopConfig.h index d1f8eb2..2fc3ec0 100644 --- a/DataSources/AtcaIop/AtcaIopConfig.h +++ b/DataSources/AtcaIop/AtcaIopConfig.h @@ -58,7 +58,8 @@ namespace MARTe { const uint32 ATCA_IOP_MAX_ADC_CHANNELS = 16u; /** - * @brief A DataSource which provides an analogue output interface to the ATCA IOP boards. + * @brief A DataSource which provides an interface to config EO, WO parameters on + * the ATCA IOP board. * @details The configuration syntax is (names are only given as an example): * *
@@ -158,7 +159,6 @@ namespace MARTe {
* @return true if all the mandatory parameters are correctly specified and if the specified optional parameters have valid values.
uint32 synchCounter;
*/
-
virtual bool Initialise(StructuredDataI & data);
@@ -168,9 +168,6 @@ namespace MARTe {
* are valid and consistent with the board parameters set during the initialisation phase.
* In particular the following conditions shall be met:
* - At least one triggering signal was requested by a GAM (with the property Trigger = 1)
- * - All the DAC channels have type float32.
- uint32 synchCounter;
- * - The number of samples of all the DAC channels is exactly one.
* @return true if all the parameters are valid and consistent with the board parameters and if the board can be successfully configured with
* these parameters.
*/
@@ -184,12 +181,11 @@ namespace MARTe {
virtual bool Synchronise();
/**
- * @brief Set flag to write Eo, Wo Synchronisly
+ * @brief Set flag to write synchronously Eo, Wo parameters
* @details This method
* It can be called within a
* MARTe message.
*/
- //ErrorManagement::ErrorType Reset();
ErrorManagement::ErrorType WriteEoWo();
@@ -209,10 +205,6 @@ namespace MARTe {
int32 devFileDescriptor;
uint32 synchCounter;
- /**
- * DAC values
- */
-// int32 dacValues[ATCA_IOP_N_DACs];
/**
* EO values Signal
@@ -226,11 +218,6 @@ namespace MARTe {
bool eoWriteFlag;
- /**
- * The signal memory
- */
-// float32 *channelsMemory;
-
/**
* Filter to receive the RPC which allows to change the...
@@ -242,8 +229,10 @@ namespace MARTe {
*/
bool triggerSet;
+ /**
+ * Perform ioctl functions
+ */
bool IoWriteEoWo();
- //int32 SetDacReg(uint32 channel, float32 val) const;
};
}
diff --git a/Startup/calib_pulses.txt b/Startup/calib_pulses.txt
index 973a2f2..1002d6b 100644
--- a/Startup/calib_pulses.txt
+++ b/Startup/calib_pulses.txt
@@ -63,3 +63,11 @@ caput -a ISTTOK:central:ATCAIOP1-EO 14 -393 -28 134 -45 -211 7 -157 -248 -469 -3
New : ISTTOK:central:ATCAIOP1-WO 16 -0.051 -0.036 -0.289 -0.049 0.024 -0.209 -0.114 -0.09 -0.221 -0.006 -0.167 -0.157 0 0 0 0
Pulse = 52706 : 4kA 4 semi cycles
+5 June 2025
+Pulse => 52960
+Connected IPLB probe to channel 13
+
+Pulse => 162
+➜ ~ caput -a ISTTOK:central:ATCAIOP1-EO 14 -395 -32 140 -5 -206 2 -157 -251 -467 -326 -113 -179 -272 -291
+➜ ~ caput -a ISTTOK:central:ATCAIOP1-WO 14 -0.001 0.022 0.131 0.017 0.092 -0.096 0.034 -0.090 -0.175 -0.006 -0.118 -0.029 0.077 69.493
+