MAX32680 Peripheral Driver API
Peripheral Driver API for the MAX32680
All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Modules
sema.h
1
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_MAX32680_SEMA_H_
28#define LIBRARIES_PERIPHDRIVERS_INCLUDE_MAX32680_SEMA_H_
29
30/* **** Includes **** */
31#include "mxc_device.h"
32#include "mxc_sys.h"
33#include "sema_regs.h"
34
35#ifdef __cplusplus
36extern "C" {
37#endif
38
45/* **** Function Prototypes **** */
46
51int MXC_SEMA_Init(void);
52
58int MXC_SEMA_GetSema(unsigned sema);
59
66int MXC_SEMA_CheckSema(unsigned sema);
67
73uint32_t MXC_SEMA_Status(void);
74
79void MXC_SEMA_FreeSema(unsigned sema);
80
86
89#ifdef __cplusplus
90}
91#endif
92
93#endif // LIBRARIES_PERIPHDRIVERS_INCLUDE_MAX32680_SEMA_H_
int MXC_SEMA_CheckSema(unsigned sema)
Check a semaphore.
void MXC_SEMA_FreeSema(unsigned sema)
Frees the semaphore.
int MXC_SEMA_Shutdown(void)
Shutdown the semaphore peripheral.
int MXC_SEMA_Init(void)
Initialize the semaphore peripheral.
int MXC_SEMA_GetSema(unsigned sema)
Attempt to get a semaphore.
uint32_t MXC_SEMA_Status(void)
Check all semaphores.
Registers, Bit Masks and Bit Positions for the SEMA Peripheral Module.