TAMP Exported Macros

Common Write and read registers Macros

group TAMP_LL_EM_WRITE_READ

Defines

LL_TAMP_WRITE_REG ( __REG__ , __VALUE__ ) STM32_WRITE_REG(TAMP->__REG__, (__VALUE__))

Write a value in TAMP register.

Parameters :
  • __REG__ – Register to be written

  • __VALUE__ – Value to be written in the register

LL_TAMP_READ_REG ( __REG__ ) STM32_READ_REG(TAMP->__REG__)

Read a value in TAMP register.

Parameters :
  • __REG__ – Register to be read

Return values :

Register – value

Helper macros

group TAMP_LL_EM_helper

Defines

LL_TAMP_GET_PULL_UP ( tamp_config_value ) ((tamp_config_value) & TAMP_FLTCR_TAMPPUDIS)

Helper macro to retrieve pull_up precharge configuration.

Parameters :
Return values :

Return – value can be one of the following values:

LL_TAMP_GET_PRECHARGE_DURATION ( tamp_config_value ) ((tamp_config_value) & TAMP_FLTCR_TAMPPRCH)

Helper macro to retrieve pull_up precharge duration configuration.

Parameters :
Return values :

Return – value can be one of the following values:

LL_TAMP_GET_FILTER_SAMPLE ( tamp_config_value ) ((tamp_config_value) & TAMP_FLTCR_TAMPFLT)

Helper macro to retrieve pull_up precharge configuration.

Parameters :
Return values :

Return – value can be one of the following values:

LL_TAMP_GET_FILTER_SAMPLE_FREQUENCY ( tamp_config_value ) ((tamp_config_value) & TAMP_FLTCR_TAMPFREQ)

Helper macro to retrieve pull_up precharge configuration.

Parameters :
Return values :

Return – value can be one of the following values:

LL_TAMP_GET_TRIGGER ( tamp_config_indiv_value ) ((((tamp_config_indiv_value) & \ LL_TAMP_ACTIVELEVEL_TAMP_ALL ) != 0U ) ?\ LL_TAMP_ACTIVELEVEL_TAMP : LL_TAMP_ACTIVELEVEL_DEACTIVATE_ALL )

Helper macro to retrieve the trigger edge or level.

Parameters :
Return values :

Return – value can be one of the following values:

LL_TAMP_GET_NOERASE ( tamp_config_indiv_value ) ((((tamp_config_indiv_value) &\ LL_TAMP_NOERASE_TAMPER_ALL ) != 0U ) ?\ LL_TAMP_NOERASE_TAMPER : LL_TAMP_ERASE_ACTIVATE_ALL )

Helper macro to retrieve the mode of the tamper.

Parameters :
Return values :

Return – value can be one of the following values:

LL_TAMP_GET_MASK ( tamp_config_indiv_value ) ((((tamp_config_indiv_value) &\ LL_TAMP_MASK_TAMPER_ALL ) != 0U ) ?\ LL_TAMP_MASK_TAMPER : LL_TAMP_MASK_NONE )

Helper macro to retrieve the mask of the tamper.

Parameters :
Return values :

Return – value can be one of the following values:

LL_TAMP_INTERNAL_GET_NOERASE ( itamp_config_indiv_value ) ((((itamp_config_indiv_value) &\ LL_TAMP_ITAMP_NOERASE_TAMPER_ALL

) != 0U ) \

?

LL_TAMP_ITAMP_NOERASE_TAMPER : \ LL_TAMP_ITAMP_ERASE_ACTIVE_ALL )

Helper macro to retrieve the mode of the internal tamper.

Parameters :
Return values :

Return – value can be one of the following values:

LL_TAMP_ACTIVE_GET_FILTER ( atamp_config_value ) ((atamp_config_value) & TAMP_ATCR1_FLTEN)

Helper macro to retrieve the active filtering status.

Parameters :
Return values :

Return – value can be one of the following values:

LL_TAMP_ACTIVE_GET_OUTPUT_PERIOD ( atamp_config_value )

(((atamp_config_value) &\

TAMP_ATCR1_ATPER) >> TAMP_ATCR1_ATPER_Pos)


Helper macro to retrieve the period when the output signals changes.

Parameters :
Return values :

Return – value is between 0 and 7.

LL_TAMP_ACTIVE_GET_PRESCALER ( atamp_config_value ) ((atamp_config_value) & TAMP_ATCR1_ATCKSEL)

Helper macro to retrieve the asysnchronous prescaler.

Parameters :
Return values :

Return – value can be one of the following values:

LL_TAMP_ACTIVE_GET_SHARING ( atamp_config_value ) ((atamp_config_value) & TAMP_ATCR1_ATOSHARE)

Helper macro to retrieve the sharing status of the active tampers.

Parameters :
Return values :

Return – value can be one of the following values: