mirror of
https://github.com/slsdetectorgroup/slsDetectorPackage.git
synced 2025-06-19 00:07:13 +02:00
Separate headers (#57)
* WIP, ctb * WIP, eiger * WIP, gotthard * WIP, jungfrau * WIP, gotthard2 * WIP, mythen3 * WIP, moench * fixed gotthard apiversioning mismatch with gotthard2
This commit is contained in:
54
slsDetectorServers/slsDetectorServer/include/ALTERA_PLL.h
Executable file
54
slsDetectorServers/slsDetectorServer/include/ALTERA_PLL.h
Executable file
@ -0,0 +1,54 @@
|
||||
#pragma once
|
||||
|
||||
#include <inttypes.h>
|
||||
|
||||
/**
|
||||
* Set Defines
|
||||
* @param creg control register
|
||||
* @param preg parameter register
|
||||
* @param rprmsk reconfig parameter reset mask
|
||||
* @param wpmsk write parameter mask
|
||||
* @param prmsk pll reset mask
|
||||
* @param amsk address mask
|
||||
* @param aofst address offset
|
||||
*/
|
||||
void ALTERA_PLL_SetDefines(uint32_t creg, uint32_t preg, uint32_t rprmsk, uint32_t wpmsk, uint32_t prmsk, uint32_t amsk, int aofst);
|
||||
|
||||
/**
|
||||
* Reset only PLL
|
||||
*/
|
||||
void ALTERA_PLL_ResetPLL ();
|
||||
|
||||
/**
|
||||
* Reset PLL Reconfiguration and PLL
|
||||
*/
|
||||
void ALTERA_PLL_ResetPLLAndReconfiguration ();
|
||||
|
||||
/**
|
||||
* Set PLL Reconfig register
|
||||
* @param reg register
|
||||
* @param val value
|
||||
*/
|
||||
void ALTERA_PLL_SetPllReconfigReg(uint32_t reg, uint32_t val);
|
||||
|
||||
/**
|
||||
* Write Phase Shift
|
||||
* @param phase phase shift
|
||||
* @param clkIndex clock index
|
||||
* @param pos 1 if up down direction of shift is positive, else 0
|
||||
*/
|
||||
void ALTERA_PLL_SetPhaseShift(int32_t phase, int clkIndex, int pos);
|
||||
|
||||
/**
|
||||
* Set PLL mode register to polling mode
|
||||
*/
|
||||
void ALTERA_PLL_SetModePolling();
|
||||
/**
|
||||
* Calculate and write output frequency
|
||||
* @param clkIndex clock index
|
||||
* @param pllVCOFreqMhz PLL VCO Frequency in Mhz
|
||||
* @param value frequency to set to
|
||||
* @param frequency set
|
||||
*/
|
||||
int ALTERA_PLL_SetOuputFrequency (int clkIndex, int pllVCOFreqMhz, int value);
|
||||
|
Reference in New Issue
Block a user