
USB Controlled Multicolor Signal Beacon User Manual
29
④
NE_SetBuz
Item
Description
Name
int NE_SetBuz(BuzzerPatterns buzPattern, int volume, int count)
Overview
Specify the alarm pattern, volume, and number of times to make this product
sound the alarm.
The LED unit maintains its current state.
Argument
buzPattern
:
Specify the alarm patterm. Refer to “
☞
7.3 (5-3)
Alarm pattern” for details.
volume
:
Specify the volume.
If “0” is specified, there will be no sound.
If “1” to “10” is specified, the volume will be set according to the numerical
value.
count
:
If “0” is specified, it operates continuously.
If “1” to “14” is specified, it sounds the defined number of times.
Return Value
If successful, returns 0.
If an error occurs, a value less than 0 is returned.
Refer to “
☞
7.3
(6) Error” for details.
Precautions
It i
s necessary to call “NE_OpenDevice” before calling this function.
Program
Example
int open_state, send_state;
open_state = NE_OpenDevice();
if(open_state == 0){
send_state = NE_SetBuz (BuzzerPatterns. Pattern1, 5, 14);
/* Pattern1, Volume 5, 14 times repeat */
}
NE_CloseDevice();