1 /** 2 * @file simo.h 3 * @brief SIMO function prototypes and data types. 4 */ 5 6 /****************************************************************************** 7 * 8 * Copyright (C) 2022-2023 Maxim Integrated Products, Inc. (now owned by 9 * Analog Devices, Inc.), 10 * Copyright (C) 2023-2024 Analog Devices, Inc. 11 * 12 * Licensed under the Apache License, Version 2.0 (the "License"); 13 * you may not use this file except in compliance with the License. 14 * You may obtain a copy of the License at 15 * 16 * http://www.apache.org/licenses/LICENSE-2.0 17 * 18 * Unless required by applicable law or agreed to in writing, software 19 * distributed under the License is distributed on an "AS IS" BASIS, 20 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 21 * See the License for the specific language governing permissions and 22 * limitations under the License. 23 * 24 ******************************************************************************/ 25 26 /* Define to prevent redundant inclusion */ 27 #ifndef LIBRARIES_PERIPHDRIVERS_INCLUDE_MAX32655_SIMO_H_ 28 #define LIBRARIES_PERIPHDRIVERS_INCLUDE_MAX32655_SIMO_H_ 29 30 /* **** Includes **** */ 31 #include "mxc_device.h" 32 #include "simo_regs.h" 33 34 #ifdef __cplusplus 35 extern "C" { 36 #endif 37 38 /** 39 * @defgroup simo SIMO 40 * @ingroup periphlibs 41 * @{ 42 */ 43 44 /* **** Definitions **** */ 45 #define VREGO_LOW_RANGE_BASE 500 46 #define VREGO_HIGH_RANGE_BASE 600 47 48 /* **** Function Prototypes **** */ 49 void MXC_SIMO_SetVregO_A(uint32_t voltage); 50 void MXC_SIMO_SetVregO_B(uint32_t voltage); 51 void MXC_SIMO_SetVregO_C(uint32_t voltage); 52 void MXC_SIMO_SetVregO_D(uint32_t voltage); 53 54 void MXC_SIMO_setIpkA(uint32_t peak_current); 55 void MXC_SIMO_setIpkB(uint32_t peak_current); 56 void MXC_SIMO_setIpkC(uint32_t peak_current); 57 void MXC_SIMO_setIpkD(uint32_t peak_current); 58 59 void MXC_SIMO_setMaxTon(uint32_t ontime); 60 61 void MXC_SIMO_setAlertThresholdA(uint32_t threshold); 62 void MXC_SIMO_setAlertThresholdB(uint32_t threshold); 63 void MXC_SIMO_setAlertThresholdC(uint32_t threshold); 64 void MXC_SIMO_setAlertThresholdD(uint32_t threshold); 65 66 void MXC_SIMO_setZeroCrossCalA(uint32_t zerocross); 67 void MXC_SIMO_setZeroCrossCalB(uint32_t zerocross); 68 void MXC_SIMO_setZeroCrossCalC(uint32_t zerocross); 69 void MXC_SIMO_setZeroCrossCalD(uint32_t zerocross); 70 71 uint32_t MXC_SIMO_GetOutReadyA(void); 72 uint32_t MXC_SIMO_GetOutReadyB(void); 73 uint32_t MXC_SIMO_GetOutReadyC(void); 74 uint32_t MXC_SIMO_GetOutReadyD(void); 75 76 /**@} end of group simo */ 77 78 #ifdef __cplusplus 79 } 80 #endif 81 82 #endif // LIBRARIES_PERIPHDRIVERS_INCLUDE_MAX32655_SIMO_H_ 83