28#ifndef LIBRARIES_PERIPHDRIVERS_INCLUDE_MAX32680_OWM_H_
29#define LIBRARIES_PERIPHDRIVERS_INCLUDE_MAX32680_OWM_H_
32#include "mxc_device.h"
67#define READ_ROM_COMMAND 0x33
68#define MATCH_ROM_COMMAND 0x55
69#define SEARCH_ROM_COMMAND 0xF0
70#define SKIP_ROM_COMMAND 0xCC
71#define OD_SKIP_ROM_COMMAND 0x3C
72#define OD_MATCH_ROM_COMMAND 0x69
73#define RESUME_COMMAND 0xA5
uint8_t long_line_mode
Definition: owm.h:63
mxc_owm_ext_pu_t ext_pu_mode
Definition: owm.h:62
uint8_t int_pu_en
Definition: owm.h:61
int MXC_OWM_ReadROM(uint8_t *ROMCode)
Starts 1-Wire communication with Read ROM command.
int MXC_OWM_SetExternalPullup(mxc_owm_ext_pu_t ext_pu_mode)
Enables/Disables the External pullup.
void MXC_OWM_SetOverdrive(int enable)
Enables/Disables Overdrive speed.
int MXC_OWM_SkipROM(void)
Starts 1-Wire communication with Skip ROM command.
int MXC_OWM_Reset(void)
Send 1-Wire reset pulse. Will block until transaction is complete.
void MXC_OWM_EnableInt(int flags)
Enables interrupts.
int MXC_OWM_ODMatchROM(uint8_t *ROMCode)
Starts 1-Wire communication with Overdrive Match ROM command.
int MXC_OWM_SetInternalPullup(int enable)
Enables/Disables the Internal pullup.
int MXC_OWM_BitBang_Disable(void)
Disable Bit Bang mode.
int MXC_OWM_MatchROM(uint8_t *ROMCode)
Starts 1-Wire communication with Match ROM command.
void MXC_OWM_Shutdown(void)
Shutdown OWM module.
int MXC_OWM_SetSearchROMAccelerator(int enable)
Enable/Disable Search ROM Accelerator mode.
int MXC_OWM_GetPresenceDetect(void)
Get the presence pulse detect status.
int MXC_OWM_Init(const mxc_owm_cfg_t *cfg)
Initialize and enable OWM module.
void MXC_OWM_ClearFlags(uint32_t mask)
Clear interrupt flags.
int MXC_OWM_BitBang_Read(void)
Read current value of wire.
int MXC_OWM_ReadBit(void)
Read one bit of data. Will block until transaction is complete.
int MXC_OWM_TouchBit(uint8_t bit)
Send and receive one bit of data. Will block until transaction is complete.
int MXC_OWM_WriteBit(uint8_t bit)
Write one bit of data. Will block until transaction is complete.
int MXC_OWM_TouchByte(uint8_t data)
Send and receive one byte of data. Will block until transaction is complete.
mxc_owm_ext_pu_t
Enumeration type for specifying options for 1-Wire external pullup mode.
Definition: owm.h:51
int MXC_OWM_BitBang_Write(int state)
Set value of wire.
int MXC_OWM_Read(uint8_t *data, int len)
Read multiple bytes of data. Will block until transaction is complete.
void MXC_OWM_SetExtPullup(int enable)
Enables/Disables the External pullup.
int MXC_OWM_ODSkipROM(void)
Starts 1-Wire communication with Overdrive Skip ROM command.
void MXC_OWM_DisableInt(int flags)
Disables interrupts.
int MXC_OWM_SetForcePresenceDetect(int enable)
Enables/Disables driving of OWM_IO low during presence detection.
int MXC_OWM_SystemClockUpdated(void)
Call to correct divider if system clock has changed.
int MXC_OWM_BitBang_Init(int initialState)
Prepare OWM for bit bang mode.
int MXC_OWM_Resume(void)
Starts 1-Wire communication with Resume command.
int MXC_OWM_SearchROM(int newSearch, uint8_t *ROMCode)
Starts 1-Wire communication with Search ROM command.
int MXC_OWM_ReadByte(void)
Read one byte of data. Will block until transaction is complete.
unsigned MXC_OWM_GetFlags(void)
Get interrupt flags.
int MXC_OWM_Write(uint8_t *data, int len)
Write multiple bytes of data. Will block until transaction is complete.
int MXC_OWM_WriteByte(uint8_t data)
Write one byte of data. Will block until transaction is complete.
@ MXC_OWM_EXT_PU_ACT_LOW
Definition: owm.h:53
@ MXC_OWM_EXT_PU_ACT_HIGH
Definition: owm.h:52
@ MXC_OWM_EXT_PU_UNUSED
Definition: owm.h:54
Structure type for 1-Wire Master configuration.
Definition: owm.h:60
Registers, Bit Masks and Bit Positions for the OWM Peripheral Module.