a

Dependencies:   mbed mbed-rtos

Embed: (wiki syntax)

« Back to documentation index

VNH Class Reference

VNH Class Reference

VNH class. More...

#include <vnh.hpp>

Inherits drivers::ICurrentGetter, and drivers::ICommandSetter.

Public Member Functions

 VNH (PinName, PinName, PinName, PinName)
 VNH class constructor.
 ~VNH ()
 VNH class destructor.
void Start (void)
 Start method.
void Stop (void)
 Stop method.
void Run (float speed)
 Run method.
void Brake ()
 Brake method.
void Inverse (float f_speed)
 Inverse method.
float GetCurrent (void)
 Get current method.

Detailed Description

VNH class.

It is used for implementing motor bridge control.

Definition at line 41 of file vnh.hpp.


Constructor & Destructor Documentation

VNH ( PinName  _pwm,
PinName  _ina,
PinName  _inb,
PinName  _current 
)

VNH class constructor.

Constructor method

Parameters:
_pwmPWM pin
_inapin A
_inbpin B
_currentcurrent analog pin

Definition at line 28 of file vnh.cpp.

~VNH (  )

VNH class destructor.

Destructor method

Definition at line 45 of file vnh.cpp.


Member Function Documentation

void Brake (  )

Brake method.

Definition at line 128 of file vnh.cpp.

float GetCurrent ( void   )

Get current method.

Returns:
Current value

Definition at line 85 of file vnh.cpp.

void Inverse ( float  f_speed )

Inverse method.

Parameters:
f_speedspeed value

Definition at line 116 of file vnh.cpp.

void Run ( float  speed ) [virtual]

Run method.

Parameters:
speedspeed value

Reimplemented from ICommandSetter.

Definition at line 75 of file vnh.cpp.

void Start ( void   )

Start method.

Definition at line 54 of file vnh.cpp.

void Stop ( void   )

Stop method.

Definition at line 65 of file vnh.cpp.