UUtzinger_DRV8704  0.1.1
Arduino library for the DRV8704 dual H-bridge gate driver
drv8704_types.h File Reference

Public enums and data structures for the DRV8704 driver. More...

#include <stdint.h>
#include "drv8704_defs.h"
Include dependency graph for drv8704_types.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  DRV8704BridgeState
 Reported direction and runtime mode of one bridge. More...
 
struct  DRV8704Config
 High-level DRV8704 configuration snapshot. More...
 
struct  DRV8704CurrentLimitResult
 Derived chip-global current-limit settings and per-bridge consequences. More...
 
struct  DRV8704CurrentPresetConfig
 Timing and decay recommendation associated with a current-mode preset. More...
 
struct  DRV8704HealthCheck
 Minimal transport/bring-up health result. More...
 
struct  DRV8704Pins
 Pin assignment bundle for a DRV8704 instance. More...
 
struct  DRV8704PwmCapability
 Resolved platform PWM capabilities for the active backend. More...
 
struct  DRV8704PwmConfig
 Requested PWM generator settings. More...
 
struct  DRV8704Status
 Decoded device status and fault state. More...
 
struct  GateDriveConfig
 Gate-drive configuration group. More...
 

Enumerations

enum class  BridgeId : uint8_t { A = 0 , B }
 Bridge selector. More...
 
enum class  BridgeMode : uint8_t { Coast = 0 , Forward , Reverse , Brake }
 Runtime bridge command. More...
 
enum class  BridgeRuntimeState : uint8_t { Coast = 0 , Brake , CurrentDrive , PwmDriveWithCurrentLimit }
 High-level runtime state for one bridge. More...
 
enum class  CurrentModePreset : uint8_t {
  Heater = 0 , ThermoelectricCooler , MotorSmallInductance , MotorMediumInductance ,
  MotorLargeInductance
}
 Predefined load presets for current-mode timing and decay behavior. More...
 
enum class  DeadTime : uint8_t { Ns410 = 0 , Ns460 , Ns670 , Ns880 }
 Supported dead-time settings. More...
 
enum class  DecayMode : uint8_t { Slow = 0 , Fast = 2 , Mixed = 3 , AutoMixed = 5 }
 Supported current-decay modes. More...
 
enum class  Direction : uint8_t { Forward = 0 , Reverse }
 High-level direction selector for current mode and PWM mode. More...
 
enum class  FaultBit : uint8_t {
  Ots = 0 , Aocp , Bocp , Apdf ,
  Bpdf , Uvlo
}
 Selectable fault bits in the STATUS register. More...
 
enum class  GateDriveSinkCurrent : uint8_t { MilliAmps100 = 0 , MilliAmps200 , MilliAmps300 , MilliAmps400 }
 Supported sink current values for the predriver. More...
 
enum class  GateDriveSourceCurrent : uint8_t { MilliAmps50 = 0 , MilliAmps100 , MilliAmps150 , MilliAmps200 }
 Supported source current values for the predriver. More...
 
enum class  GateDriveTime : uint8_t { Ns263 = 0 , Ns525 , Ns1050 , Ns2100 }
 Supported gate-drive timing values. More...
 
enum class  OcpDeglitch : uint8_t { Us1p05 = 0 , Us2p10 , Us4p20 , Us8p40 }
 Supported OCP deglitch durations. More...
 
enum class  OcpThreshold : uint8_t { MilliVolts250 = 0 , MilliVolts500 , MilliVolts750 , MilliVolts1000 }
 Supported overcurrent thresholds. More...
 
enum class  PwmBackendType : uint8_t {
  None = 0 , GeneralAnalogWrite , Esp32Ledc , TeensyHardware ,
  StmHardware , Unsupported
}
 Supported platform PWM backend families. More...
 
enum class  RegisterAddress : uint8_t {
  Ctrl = 0x00 , Torque = 0x01 , Off = 0x02 , Blank = 0x03 ,
  Decay = 0x04 , Reserved = 0x05 , Drive = 0x06 , Status = 0x07
}
 Supported register addresses. More...
 
enum class  SenseGain : uint8_t { Gain5VperV = 0 , Gain10VperV , Gain20VperV , Gain40VperV }
 Supported sense amplifier gain settings. More...
 

Detailed Description

Public enums and data structures for the DRV8704 driver.

Enumeration Type Documentation

◆ BridgeId

enum BridgeId : uint8_t
strong

Bridge selector.

Enumerator

◆ BridgeMode

enum BridgeMode : uint8_t
strong

Runtime bridge command.

Enumerator
Coast 
Forward 
Reverse 
Brake 

◆ BridgeRuntimeState

enum BridgeRuntimeState : uint8_t
strong

High-level runtime state for one bridge.

Enumerator
Coast 
Brake 
CurrentDrive 
PwmDriveWithCurrentLimit 

◆ CurrentModePreset

enum CurrentModePreset : uint8_t
strong

Predefined load presets for current-mode timing and decay behavior.

Enumerator
Heater 
ThermoelectricCooler 
MotorSmallInductance 
MotorMediumInductance 
MotorLargeInductance 

◆ DeadTime

enum DeadTime : uint8_t
strong

Supported dead-time settings.

Enumerator
Ns410 
Ns460 
Ns670 
Ns880 

◆ DecayMode

enum DecayMode : uint8_t
strong

Supported current-decay modes.

Enumerator
Slow 
Fast 
Mixed 
AutoMixed 

◆ Direction

enum Direction : uint8_t
strong

High-level direction selector for current mode and PWM mode.

Enumerator
Forward 
Reverse 

◆ FaultBit

enum FaultBit : uint8_t
strong

Selectable fault bits in the STATUS register.

Enumerator
Ots 
Aocp 
Bocp 
Apdf 
Bpdf 
Uvlo 

◆ GateDriveSinkCurrent

enum GateDriveSinkCurrent : uint8_t
strong

Supported sink current values for the predriver.

Enumerator
MilliAmps100 
MilliAmps200 
MilliAmps300 
MilliAmps400 

◆ GateDriveSourceCurrent

enum GateDriveSourceCurrent : uint8_t
strong

Supported source current values for the predriver.

Enumerator
MilliAmps50 
MilliAmps100 
MilliAmps150 
MilliAmps200 

◆ GateDriveTime

enum GateDriveTime : uint8_t
strong

Supported gate-drive timing values.

Enumerator
Ns263 
Ns525 
Ns1050 
Ns2100 

◆ OcpDeglitch

enum OcpDeglitch : uint8_t
strong

Supported OCP deglitch durations.

Enumerator
Us1p05 
Us2p10 
Us4p20 
Us8p40 

◆ OcpThreshold

enum OcpThreshold : uint8_t
strong

Supported overcurrent thresholds.

Enumerator
MilliVolts250 
MilliVolts500 
MilliVolts750 
MilliVolts1000 

◆ PwmBackendType

enum PwmBackendType : uint8_t
strong

Supported platform PWM backend families.

Enumerator
None 
GeneralAnalogWrite 
Esp32Ledc 
TeensyHardware 
StmHardware 
Unsupported 

◆ RegisterAddress

enum RegisterAddress : uint8_t
strong

Supported register addresses.

Enumerator
Ctrl 
Torque 
Off 
Blank 
Decay 
Reserved 
Drive 
Status 

◆ SenseGain

enum SenseGain : uint8_t
strong

Supported sense amplifier gain settings.

Enumerator
Gain5VperV 
Gain10VperV 
Gain20VperV 
Gain40VperV