
ACR89U-A1 – Application Programming Interface info@acs.com.hk
Version 1.01
www.acs.com.hk
Page 13 of 78
4.2. Buzzer API Functions
4.2.1. Data Structures
4.2.1.1. Buzzer_ScriptDataType
[Buzzer_Msg.h]
struct Buzzer_Script
{
UINT8 BuzzerTime: 7;
UINT8 BuzzerOn: 1;
};
typedef struct Buzzer_Script Buzzer_ScriptDataType;
Used by Buzzer_Msg_SendScript.
Example:
const Buzzer_ScriptDataType Buzzer_SampleScript1 [] =
{
{1, TRUE}, // buzzer on 100ms
{2, FALSE}, // buzzer off 200ms
{3, TRUE}, // buzzer on 300ms
...
{0, FALSE} // mandatory script end
};
Data Member Value Description
BuzzerTime
Bit field
0 to 127
The time of a buzzer on/off state:
This value represents a multiple of 100 ms.
BuzzerOn
Bit field
TRUE or FALSE
The on/off state of buzzer:
TRUR – buzzer on
FALSE – buzzer off
Table 3: Buzzer_ScriptDataTaype Data Structure
4.2.2. Functions
4.2.2.1. Buzzer_Msg_SendScript
This function sends buzzer script to buzzer driver.
[Buzzer_Msg.h]
BOOLEAN Buzzer_Msg_SendScript (
Buzzer_ScriptDataType const* const Script );
Parameters:
Script [in] Storage space of the script data. If this parameter is a local variable, it should be the
data type of “static const” for compiling safety. Using global const variable for this
parameter is more preferred.
Comments to this Manuals