@@ -57,6 +57,8 @@ class ScpiClient {
5757 * @brief Get the library version as a decimal integer. For example, version
5858 * 1.3.2 would return 10302.
5959 *
60+ * @since v1.1.0
61+ *
6062 * @return Library version.
6163 */
6264 static unsigned int Version () noexcept ;
@@ -985,6 +987,200 @@ class ScpiClient {
985987 */
986988 ErrorCode MeasureAllCellCurrents (std::span<float > currents) const ;
987989
990+ /* *
991+ * @brief Retrieve the rolling average of the last 10 voltage measurements for
992+ * a single cell.
993+ *
994+ * At the default sample rate, this is a 10ms window. With filtering on, the
995+ * length of this window will change.
996+ *
997+ * @since v1.1.0
998+ *
999+ * @par Requires
1000+ * Firmware v1.2.0
1001+ *
1002+ * @param[in] cell target cell index
1003+ *
1004+ * @return Result containing the average cell voltage or an error code.
1005+ */
1006+ Result<float > MeasureAverageCellVoltage (unsigned int cell) const ;
1007+
1008+ /* *
1009+ * @brief Retrieve the rolling average of the last 10 voltage measurements for
1010+ * all cells.
1011+ *
1012+ * At the default sample rate, this is a 10ms window. With filtering on, the
1013+ * length of this window will change.
1014+ *
1015+ * @since v1.1.0
1016+ *
1017+ * @par Requires
1018+ * Firmware v1.2.0
1019+ *
1020+ * @return Result containing an array of average cell voltages or an error
1021+ * code.
1022+ */
1023+ Result<std::array<float , kCellCount >> MeasureAllAverageCellVoltages () const ;
1024+
1025+ /* *
1026+ * @brief Retrieve the rolling average of the last 10 voltage measurements for
1027+ * all cells.
1028+ *
1029+ * At the default sample rate, this is a 10ms window. With filtering on, the
1030+ * length of this window will change.
1031+ *
1032+ * @note It is recommended that the array and span overloads be preferred over
1033+ * this overload whenever possible.
1034+ *
1035+ * @since v1.1.0
1036+ *
1037+ * @par Requires
1038+ * Firmware v1.2.0
1039+ *
1040+ * @param[out] voltages array to store the average voltages
1041+ * @param[in] count length of the array (must not be greater than the total
1042+ * cell count)
1043+ *
1044+ * @return An error code.
1045+ */
1046+ ErrorCode MeasureAllAverageCellVoltages (float * voltages,
1047+ std::size_t count) const ;
1048+
1049+ /* *
1050+ * @brief Retrieve the rolling average of the last 10 voltage measurements for
1051+ * all cells.
1052+ *
1053+ * At the default sample rate, this is a 10ms window. With filtering on, the
1054+ * length of this window will change.
1055+ *
1056+ * @since v1.1.0
1057+ *
1058+ * @par Requires
1059+ * Firmware v1.2.0
1060+ *
1061+ * @param[out] voltages an array of average cell voltages
1062+ *
1063+ * @return An error code.
1064+ */
1065+ ErrorCode MeasureAllAverageCellVoltages (
1066+ std::array<float , kCellCount >& voltages) const ;
1067+
1068+ /* *
1069+ * @brief Retrieve the rolling average of the last 10 voltage measurements for
1070+ * all cells.
1071+ *
1072+ * At the default sample rate, this is a 10ms window. With filtering on, the
1073+ * length of this window will change.
1074+ *
1075+ * @since v1.1.0
1076+ *
1077+ * @par Requires
1078+ * Firmware v1.2.0
1079+ *
1080+ * @param[out] voltages an array of cell voltages (must not be longer than the
1081+ * total cell count)
1082+ *
1083+ * @return An error code.
1084+ */
1085+ ErrorCode MeasureAllAverageCellVoltages (std::span<float > voltages) const ;
1086+
1087+ /* *
1088+ * @brief Retrieve the rolling average of the last 10 current measurements for
1089+ * a single cell.
1090+ *
1091+ * At the default sample rate, this is a 10ms window. With filtering on, the
1092+ * length of this window will change.
1093+ *
1094+ * @since v1.1.0
1095+ *
1096+ * @par Requires
1097+ * Firmware v1.2.0
1098+ *
1099+ * @param[in] cell target cell index
1100+ *
1101+ * @return Result containing the average cell current or an error code.
1102+ */
1103+ Result<float > MeasureAverageCellCurrent (unsigned int cell) const ;
1104+
1105+ /* *
1106+ * @brief Retrieve the rolling average of the last 10 current measurements for
1107+ * all cells.
1108+ *
1109+ * At the default sample rate, this is a 10ms window. With filtering on, the
1110+ * length of this window will change.
1111+ *
1112+ * @since v1.1.0
1113+ *
1114+ * @par Requires
1115+ * Firmware v1.2.0
1116+ *
1117+ * @return Result containing an array of average cell currents or an error
1118+ * code.
1119+ */
1120+ Result<std::array<float , kCellCount >> MeasureAllAverageCellCurrents () const ;
1121+
1122+ /* *
1123+ * @brief Retrieve the rolling average of the last 10 current measurements for
1124+ * all cells.
1125+ *
1126+ * At the default sample rate, this is a 10ms window. With filtering on, the
1127+ * length of this window will change.
1128+ *
1129+ * @note It is recommended that the array and span overloads be preferred over
1130+ * this overload whenever possible.
1131+ *
1132+ * @since v1.1.0
1133+ *
1134+ * @par Requires
1135+ * Firmware v1.2.0
1136+ *
1137+ * @param[out] currents array to store the average currents
1138+ * @param[in] count length of the array (must not be greater than the total
1139+ * cell count)
1140+ *
1141+ * @return An error code.
1142+ */
1143+ ErrorCode MeasureAllAverageCellCurrents (float * currents,
1144+ std::size_t count) const ;
1145+
1146+ /* *
1147+ * @brief Retrieve the rolling average of the last 10 current measurements for
1148+ * all cells.
1149+ *
1150+ * At the default sample rate, this is a 10ms window. With filtering on, the
1151+ * length of this window will change.
1152+ *
1153+ * @since v1.1.0
1154+ *
1155+ * @par Requires
1156+ * Firmware v1.2.0
1157+ *
1158+ * @param[out] currents an array of average cell currents
1159+ *
1160+ * @return An error code.
1161+ */
1162+ ErrorCode MeasureAllAverageCellCurrents (
1163+ std::array<float , kCellCount >& currents) const ;
1164+
1165+ /* *
1166+ * @brief Retrieve the rolling average of the last 10 current measurements for
1167+ * all cells.
1168+ *
1169+ * At the default sample rate, this is a 10ms window. With filtering on, the
1170+ * length of this window will change.
1171+ *
1172+ * @since v1.1.0
1173+ *
1174+ * @par Requires
1175+ * Firmware v1.2.0
1176+ *
1177+ * @param[out] currents an array of cell currents (must not be longer than the
1178+ * total cell count)
1179+ *
1180+ * @return An error code.
1181+ */
1182+ ErrorCode MeasureAllAverageCellCurrents (std::span<float > currents) const ;
1183+
9881184 /* *
9891185 * @brief Query a single cell's operating mode.
9901186 *
0 commit comments