forked from gatsby/df_datalink
enhanced code inherence
This commit is contained in:
@@ -26,6 +26,7 @@
|
|||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include <math.h>
|
#include <math.h>
|
||||||
#include "phy_layer.h"
|
#include "phy_layer.h"
|
||||||
|
#include "phy_reg.h"
|
||||||
#include "util.h"
|
#include "util.h"
|
||||||
#include "error.h"
|
#include "error.h"
|
||||||
#ifndef EMULATION
|
#ifndef EMULATION
|
||||||
@@ -481,13 +482,13 @@ int32_t Phy_InstInit(PHY_INST **instPtr, PHY_CONFIG *phyConfig)
|
|||||||
goto init_error;
|
goto init_error;
|
||||||
}
|
}
|
||||||
|
|
||||||
memccpy(antConfigBram.config.MemBaseAddress,
|
memcpy((void*)antConfigBram.Config.MemBaseAddress,
|
||||||
antSubnrrwPattern, sizeof(antSubnrrwPattern));
|
antSubnrrwPattern, sizeof(antSubnrrwPattern));
|
||||||
uint32_t phyMainCtrl = PhyRead(*instPtr, PHY_MAIN_CTRL);
|
uint32_t phyMainCtrl = PhyRead(*instPtr, PHY_MAIN_CTRL);
|
||||||
phyMainCtrl &= ~PHY_MAIN_CTRL_NSCAN_MASK;
|
phyMainCtrl &= ~PHY_MAIN_CTRL_NSCAN_MASK;
|
||||||
phyMainCtrl |= PHY_MAIN_CTRL_NSCAN_MASK &
|
phyMainCtrl |= PHY_MAIN_CTRL_NSCAN_MASK &
|
||||||
(L1_NUM_ANT_SUBNRRW_PATTERN << PHY_MAIN_CTRL_NSCAN_SHIFT);
|
(L1_NUM_ANT_SUBNRRW_PATTERN << PHY_MAIN_CTRL_NSCAN_SHIFT);
|
||||||
PhyWrite(*instPtr, phyMainCtrl);
|
PhyWrite(*instPtr, PHY_MAIN_CTRL, phyMainCtrl);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Initialize the XAdc driver. */
|
/* Initialize the XAdc driver. */
|
||||||
|
|||||||
@@ -26,7 +26,6 @@
|
|||||||
|
|
||||||
/***************************** Include Files *********************************/
|
/***************************** Include Files *********************************/
|
||||||
#include <stdint.h>
|
#include <stdint.h>
|
||||||
#include "phy_reg.h"
|
|
||||||
#include "common.h"
|
#include "common.h"
|
||||||
#ifndef EMULATION
|
#ifndef EMULATION
|
||||||
#include "xbram.h"
|
#include "xbram.h"
|
||||||
|
|||||||
@@ -26,8 +26,8 @@
|
|||||||
#include "util.h"
|
#include "util.h"
|
||||||
|
|
||||||
/***************** Macros (Inline Functions) Definitions *********************/
|
/***************** Macros (Inline Functions) Definitions *********************/
|
||||||
#define PhyRead(instPtr, addr) IO_In32(instPtr->phyCofig.baseAddr + addr)
|
#define PhyRead(instPtr, addr) IO_In32((instPtr)->phyCofig.baseAddr + addr)
|
||||||
#define PhyWrite(instPtr, addr, value) IO_Out32(instPtr->phyCofig.baseAddr + addr, value)
|
#define PhyWrite(instPtr, addr, value) IO_Out32((instPtr)->phyCofig.baseAddr + addr, value)
|
||||||
|
|
||||||
/************************** Constant Definitions *****************************/
|
/************************** Constant Definitions *****************************/
|
||||||
/**
|
/**
|
||||||
|
|||||||
Reference in New Issue
Block a user