Skip to content

Commit

Permalink
Bug fix
Browse files Browse the repository at this point in the history
  • Loading branch information
akkoyun committed Mar 20, 2024
1 parent 77ae2b6 commit f20399a
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 10 deletions.
2 changes: 1 addition & 1 deletion library.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "MAX78630",
"version": "4.11.0",
"version": "4.11.1",
"keywords": "MAX78630, Maxim, Silergy, Energy, Electric, Poly, Phase, Metering, Measure, Active, Reactive, Apparent, Voltage, Current, Power Factor, Cos Fi, Temperature, Fundamental, Harmonic, Defect, Alarm, Min, Max",
"description": "The EnergyBoard is an energy measurement module for poly phase power-monitoring systems. It is designed for real-time monitoring for a variety of typical three-phase configurations in industrial applications. The EnergyBoard provides up to six analog inputs for interfacing to voltage and current sensors. Scaled voltages from the sensors are fed to the single converter front-end using a high-resolution delta-sigma converter. Supported current sensors include current transformers (CTs), Rogowski coils, and resistive shunts.",
"authors":
Expand Down
2 changes: 1 addition & 1 deletion library.properties
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name=MAX78630
version=4.11.0
version=4.11.1
author=Gunce Akkoyun <[email protected]>
maintainer=Gunce Akkoyun <[email protected]>
sentence=Enables reading polyphase energy-monitor parameters of LVX EnergyBoard.
Expand Down
16 changes: 8 additions & 8 deletions src/MAX78630.h
Original file line number Diff line number Diff line change
Expand Up @@ -526,7 +526,7 @@
}

// Alarm Mask Function.
uint32_t Alarm_Mask(const uint8_t _Function = __MAX78630_GET__, const uint8_t _Mask, const uint8_t _Bit, const bool _Status) {
uint32_t Alarm_Mask(const uint8_t _Function, const uint8_t _Mask, const uint8_t _Bit, const bool _Status) {

// Control for Mask
if (_Mask == __MASK_AL1__) {
Expand Down Expand Up @@ -665,7 +665,7 @@
}

// Baud Rate Function
uint32_t Baud(const uint8_t _Function = __MAX78630_GET__, const uint32_t _Baud) {
uint32_t Baud(const uint8_t _Function, const uint32_t _Baud) {

// Define Register
Register BAUD {0x00, 0x51, 0}; // Baud rate for UART interface
Expand Down Expand Up @@ -746,7 +746,7 @@
/* Min Max Functions */

// Min Record Value Function
float Min_Value(const bool _Function = __MAX78630_GET__, const uint8_t _MM_ADDR, const uint16_t _Scale = 1) {
float Min_Value(const uint8_t _Function, const uint8_t _MM_ADDR, const uint16_t _Scale = 1) {

// Control for Function
if (_Function == __MAX78630_SET__) return(0);
Expand Down Expand Up @@ -886,7 +886,7 @@
}

// Max Record Value Function
float Max_Value(const bool _Function = __MAX78630_GET__, const uint8_t _MM_ADDR, const uint16_t _Scale = 1) {
float Max_Value(const uint8_t _Function, const uint8_t _MM_ADDR, const uint16_t _Scale = 1) {

// Control for Function
if (_Function == __MAX78630_SET__) return(0);
Expand Down Expand Up @@ -1190,7 +1190,7 @@
}

// Coefficients Function
float HPF_COEF(const bool _Function = __MAX78630_GET__, const uint8_t _Type, float _COEF) {
float HPF_COEF(const uint8_t _Function, const uint8_t _Type, float _COEF) {

// Control for Type
if (_Type == __Voltage__) {
Expand Down Expand Up @@ -1234,7 +1234,7 @@
}

// Offset Function
float Offset(const bool _Function = __MAX78630_GET__, const uint8_t _Type, const uint8_t _Phase, float _Offset) {
float Offset(const uint8_t _Function, const uint8_t _Type, const uint8_t _Phase, float _Offset) {

// Control for Type
if (_Type == __Current__) {
Expand Down Expand Up @@ -1408,7 +1408,7 @@
/* Limit Functions */

// Limit Function
float Limit(const uint8_t _Function = __MAX78630_GET__, const uint8_t _Limit_Type, float _Limit_Value) {
float Limit(const uint8_t _Function, const uint8_t _Limit_Type, float _Limit_Value) {

// Decide Type
switch (_Limit_Type) {
Expand Down Expand Up @@ -3075,7 +3075,7 @@
}

// Set Harmonic Channel Function. TODO: Not Tested.
uint8_t Harmonic(const bool _Function = __MAX78630_GET__, uint32_t _Harmonic) {
uint8_t Harmonic(const uint8_t _Function, uint32_t _Harmonic) {

// Define Register
Register HARM {0x00, 0x4B, 0}; // Harmonic Selector, default: 1 (fundamental)
Expand Down

0 comments on commit f20399a

Please sign in to comment.