diff options
Diffstat (limited to 'firmware/target/arm/s3c2440/gigabeat-fx/wmcodec-meg-fx.c')
-rw-r--r-- | firmware/target/arm/s3c2440/gigabeat-fx/wmcodec-meg-fx.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/firmware/target/arm/s3c2440/gigabeat-fx/wmcodec-meg-fx.c b/firmware/target/arm/s3c2440/gigabeat-fx/wmcodec-meg-fx.c index 01b177da6c..eea4c58e4b 100644 --- a/firmware/target/arm/s3c2440/gigabeat-fx/wmcodec-meg-fx.c +++ b/firmware/target/arm/s3c2440/gigabeat-fx/wmcodec-meg-fx.c | |||
@@ -99,14 +99,15 @@ void TIMER3(void) | |||
99 | INTPND = TIMER3_MASK; | 99 | INTPND = TIMER3_MASK; |
100 | } | 100 | } |
101 | 101 | ||
102 | void pcmbuf_beep(unsigned int frequency, size_t duration, int amplitude) | 102 | void beep_play(unsigned int frequency, unsigned int duration, |
103 | unsigned int amplitude) | ||
103 | { | 104 | { |
104 | #define TIMER3_TICK_SEC (TIMER_FREQ / TIMER234_PRESCALE) | 105 | #define TIMER3_TICK_SEC (TIMER_FREQ / TIMER234_PRESCALE) |
105 | 106 | ||
106 | unsigned long tcnt, tcmp; | 107 | unsigned long tcnt, tcmp; |
107 | int oldstatus; | 108 | int oldstatus; |
108 | 109 | ||
109 | if (amplitude <= 0) | 110 | if (frequency == 0 || duration == 0 || amplitude == 0) |
110 | { | 111 | { |
111 | beep_stop(); /* won't hear it anyway */ | 112 | beep_stop(); /* won't hear it anyway */ |
112 | return; | 113 | return; |