KM3NeT CLB  2.0
KM3NeT CLB v2 Embedded Software
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
acdc.h File Reference

ACDC Uart driver (. More...

#include "stdbool.h"
#include "cfg_board.h"
#include "errorcode.h"
#include "drv/wb/suart.h"

Go to the source code of this file.

Data Structures

struct  AcdcFrame
 

Macros

#define E_ACDC_TIMEOUT   E_ACDC + 1
 Receive timeout.
 
#define E_ACDC_TIMEOUT_DESCR   "ACDC Response Timeout"
 
#define ACDC_BAUDRATE_DEFAULT   SUART_BAUDRATE_9600
 Default Baudrate.
 
#define TSCALE   1
 
#define TOFF   0
 
#define VSCALE   1
 
#define VOFF   300
 
#define ISCALE   10
 
#define IOFF   0
 

Functions

void acdcInit (bool active)
 Initializes the ACDC. More...
 
void acdcEnable (bool ena)
 enables the ACDC rx More...
 
int acdcGetNFrames (AcdcFrame *framevect, int nRequested)
 
static void acdcClearBuffer ()
 

Detailed Description

ACDC Uart driver (.

Definition in file acdc.h.

Function Documentation

void acdcEnable ( bool  ena)

enables the ACDC rx

Parameters
ena=if true => start rx , otherwise it stops rx

Definition at line 58 of file acdc.c.

void acdcInit ( bool  active)

Initializes the ACDC.

Parameters
active=true if receiver has to be enabled , false if not

Definition at line 35 of file acdc.c.