本文整理汇总了C++中CY_GET_REG16函数的典型用法代码示例。如果您正苦于以下问题:C++ CY_GET_REG16函数的具体用法?C++ CY_GET_REG16怎么用?C++ CY_GET_REG16使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了CY_GET_REG16函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: HeartbeatCounter_ReadPeriod
/*******************************************************************************
* Function Name: HeartbeatCounter_ReadPeriod
********************************************************************************
* Summary:
* Reads the current period value without affecting counter operation.
*
* Parameters:
* void:
*
* Return:
* (uint32) Present period value.
*
*******************************************************************************/
uint32 HeartbeatCounter_ReadPeriod(void)
{
#if(HeartbeatCounter_UsingFixedFunction)
return ((uint32)CY_GET_REG16(HeartbeatCounter_PERIOD_LSB_PTR));
#else
return (CY_GET_REG32(HeartbeatCounter_PERIOD_LSB_PTR));
#endif /* (HeartbeatCounter_UsingFixedFunction) */
}
示例2: hallTickTimer_ReadPeriod
/*******************************************************************************
* Function Name: hallTickTimer_ReadPeriod
********************************************************************************
*
* Summary:
* This function returns the current value of the Period.
*
* Parameters:
* void
*
* Return:
* The present value of the counter.
*
*******************************************************************************/
uint32 hallTickTimer_ReadPeriod(void)
{
#if(hallTickTimer_UsingFixedFunction)
return ((uint32)CY_GET_REG16(hallTickTimer_PERIOD_LSB_PTR));
#else
return (CY_GET_REG32(hallTickTimer_PERIOD_LSB_PTR));
#endif /* (hallTickTimer_UsingFixedFunction) */
}
示例3: Timer_Look_ahead_mode_ReadCapture
/*******************************************************************************
* Function Name: Timer_Look_ahead_mode_ReadCapture
********************************************************************************
*
* Summary:
* This function returns the last value captured.
*
* Parameters:
* void
*
* Return:
* Present Capture value.
*
*******************************************************************************/
uint32 Timer_Look_ahead_mode_ReadCapture(void)
{
#if(Timer_Look_ahead_mode_UsingFixedFunction)
return ((uint32)CY_GET_REG16(Timer_Look_ahead_mode_CAPTURE_LSB_PTR));
#else
return (CY_GET_REG24(Timer_Look_ahead_mode_CAPTURE_LSB_PTR));
#endif /* (Timer_Look_ahead_mode_UsingFixedFunction) */
}
示例4: HeartbeatCounter_ReadCapture
/*******************************************************************************
* Function Name: HeartbeatCounter_ReadCapture
********************************************************************************
* Summary:
* This function returns the last value captured.
*
* Parameters:
* void
*
* Return:
* (uint32) Present Capture value.
*
*******************************************************************************/
uint32 HeartbeatCounter_ReadCapture(void)
{
#if(HeartbeatCounter_UsingFixedFunction)
return ((uint32)CY_GET_REG16(HeartbeatCounter_STATICCOUNT_LSB_PTR));
#else
return (CY_GET_REG32(HeartbeatCounter_STATICCOUNT_LSB_PTR));
#endif /* (HeartbeatCounter_UsingFixedFunction) */
}
示例5: ChargeDelay_ReadPeriod
/*******************************************************************************
* Function Name: ChargeDelay_ReadPeriod
********************************************************************************
*
* Summary:
* Reads the period value used by the PWM hardware.
*
* Parameters:
* None
*
* Return:
* uint8/16: Period value
*
*******************************************************************************/
uint8 ChargeDelay_ReadPeriod(void)
{
#if(ChargeDelay_UsingFixedFunction)
return ((uint8)CY_GET_REG16(ChargeDelay_PERIOD_LSB_PTR));
#else
return (CY_GET_REG8(ChargeDelay_PERIOD_LSB_PTR));
#endif /* (ChargeDelay_UsingFixedFunction) */
}
示例6: Timer_Look_ahead_mode_ReadPeriod
/*******************************************************************************
* Function Name: Timer_Look_ahead_mode_ReadPeriod
********************************************************************************
*
* Summary:
* This function returns the current value of the Period.
*
* Parameters:
* void
*
* Return:
* The present value of the counter.
*
*******************************************************************************/
uint32 Timer_Look_ahead_mode_ReadPeriod(void)
{
#if(Timer_Look_ahead_mode_UsingFixedFunction)
return ((uint32)CY_GET_REG16(Timer_Look_ahead_mode_PERIOD_LSB_PTR));
#else
return (CY_GET_REG24(Timer_Look_ahead_mode_PERIOD_LSB_PTR));
#endif /* (Timer_Look_ahead_mode_UsingFixedFunction) */
}
示例7: QuadDecoder_Cnt8_ReadPeriod
/*******************************************************************************
* Function Name: QuadDecoder_Cnt8_ReadPeriod
********************************************************************************
* Summary:
* Reads the current period value without affecting counter operation.
*
* Parameters:
* void:
*
* Return:
* (uint8) Present period value.
*
*******************************************************************************/
uint8 QuadDecoder_Cnt8_ReadPeriod(void)
{
#if(QuadDecoder_Cnt8_UsingFixedFunction)
return ((uint8)CY_GET_REG16(QuadDecoder_Cnt8_PERIOD_LSB_PTR));
#else
return (CY_GET_REG8(QuadDecoder_Cnt8_PERIOD_LSB_PTR));
#endif /* (QuadDecoder_Cnt8_UsingFixedFunction) */
}
示例8: ChargeDelay_ReadCompare
/*******************************************************************************
* Function Name: ChargeDelay_ReadCompare
********************************************************************************
*
* Summary:
* Reads the compare value for the compare output when the PWM Mode parameter is
* set to Dither mode, Center Aligned mode, or One Output mode.
*
* Parameters:
* None
*
* Return:
* uint8/uint16: Current compare value
*
*******************************************************************************/
uint8 ChargeDelay_ReadCompare(void)
{
#if(ChargeDelay_UsingFixedFunction)
return ((uint8)CY_GET_REG16(ChargeDelay_COMPARE1_LSB_PTR));
#else
return (CY_GET_REG8(ChargeDelay_COMPARE1_LSB_PTR));
#endif /* (ChargeDelay_UsingFixedFunction) */
}
示例9: TimerC_ReadCapture
/*******************************************************************************
* Function Name: TimerC_ReadCapture
********************************************************************************
*
* Summary:
* This function returns the last value captured.
*
* Parameters:
* void
*
* Return:
* Present Capture value.
*
*******************************************************************************/
uint8 TimerC_ReadCapture(void)
{
#if(TimerC_UsingFixedFunction)
return ((uint8)CY_GET_REG16(TimerC_CAPTURE_LSB_PTR));
#else
return (CY_GET_REG8(TimerC_CAPTURE_LSB_PTR));
#endif /* (TimerC_UsingFixedFunction) */
}
示例10: QuadDecoder_Cnt8_ReadCapture
/*******************************************************************************
* Function Name: QuadDecoder_Cnt8_ReadCapture
********************************************************************************
* Summary:
* This function returns the last value captured.
*
* Parameters:
* void
*
* Return:
* (uint8) Present Capture value.
*
*******************************************************************************/
uint8 QuadDecoder_Cnt8_ReadCapture(void)
{
#if(QuadDecoder_Cnt8_UsingFixedFunction)
return ((uint8)CY_GET_REG16(QuadDecoder_Cnt8_STATICCOUNT_LSB_PTR));
#else
return (CY_GET_REG8(QuadDecoder_Cnt8_STATICCOUNT_LSB_PTR));
#endif /* (QuadDecoder_Cnt8_UsingFixedFunction) */
}
示例11: OSC1_Freq_Timer_3_ReadCapture
/*******************************************************************************
* Function Name: OSC1_Freq_Timer_3_ReadCapture
********************************************************************************
*
* Summary:
* This function returns the last value captured.
*
* Parameters:
* void
*
* Return:
* Present Capture value.
*
*******************************************************************************/
uint32 OSC1_Freq_Timer_3_ReadCapture(void)
{
#if(OSC1_Freq_Timer_3_UsingFixedFunction)
return ((uint32)CY_GET_REG16(OSC1_Freq_Timer_3_CAPTURE_LSB_PTR));
#else
return (CY_GET_REG24(OSC1_Freq_Timer_3_CAPTURE_LSB_PTR));
#endif /* (OSC1_Freq_Timer_3_UsingFixedFunction) */
}
示例12: OSC1_Freq_Timer_3_ReadPeriod
/*******************************************************************************
* Function Name: OSC1_Freq_Timer_3_ReadPeriod
********************************************************************************
*
* Summary:
* This function returns the current value of the Period.
*
* Parameters:
* void
*
* Return:
* The present value of the counter.
*
*******************************************************************************/
uint32 OSC1_Freq_Timer_3_ReadPeriod(void)
{
#if(OSC1_Freq_Timer_3_UsingFixedFunction)
return ((uint32)CY_GET_REG16(OSC1_Freq_Timer_3_PERIOD_LSB_PTR));
#else
return (CY_GET_REG24(OSC1_Freq_Timer_3_PERIOD_LSB_PTR));
#endif /* (OSC1_Freq_Timer_3_UsingFixedFunction) */
}
示例13: MotorPWM_ReadPeriod
/*******************************************************************************
* Function Name: MotorPWM_ReadPeriod
********************************************************************************
*
* Summary:
* Reads the period value used by the PWM hardware.
*
* Parameters:
* None
*
* Return:
* uint8/16: Period value
*
*******************************************************************************/
uint8 MotorPWM_ReadPeriod(void)
{
#if(MotorPWM_UsingFixedFunction)
return ((uint8)CY_GET_REG16(MotorPWM_PERIOD_LSB_PTR));
#else
return (CY_GET_REG8(MotorPWM_PERIOD_LSB_PTR));
#endif /* (MotorPWM_UsingFixedFunction) */
}
示例14: MotorPWM_ReadCompare
/*******************************************************************************
* Function Name: MotorPWM_ReadCompare
********************************************************************************
*
* Summary:
* Reads the compare value for the compare output when the PWM Mode parameter is
* set to Dither mode, Center Aligned mode, or One Output mode.
*
* Parameters:
* None
*
* Return:
* uint8/uint16: Current compare value
*
*******************************************************************************/
uint8 MotorPWM_ReadCompare(void)
{
#if(MotorPWM_UsingFixedFunction)
return ((uint8)CY_GET_REG16(MotorPWM_COMPARE1_LSB_PTR));
#else
return (CY_GET_REG8(MotorPWM_COMPARE1_LSB_PTR));
#endif /* (MotorPWM_UsingFixedFunction) */
}
示例15: hallTickTimer_ReadCapture
/*******************************************************************************
* Function Name: hallTickTimer_ReadCapture
********************************************************************************
*
* Summary:
* This function returns the last value captured.
*
* Parameters:
* void
*
* Return:
* Present Capture value.
*
*******************************************************************************/
uint32 hallTickTimer_ReadCapture(void)
{
#if(hallTickTimer_UsingFixedFunction)
return ((uint32)CY_GET_REG16(hallTickTimer_CAPTURE_LSB_PTR));
#else
return (CY_GET_REG32(hallTickTimer_CAPTURE_LSB_PTR));
#endif /* (hallTickTimer_UsingFixedFunction) */
}