radan | Дата: Четверг, 26.03.2009, 16:47 | Сообщение # 1 |
Группа: Удаленные
| Code '/////////////////////////////////////////////////////////////////////////////// '// Police Alarm With ATmega8 (Use 4%) // '// Compiler: Bascom 1.11.9.0 // '// Programmer: Behnam zakizadeh // '// Web: www.avr64.com // '// Email: Behnamzaki@hotmail.com // '/////////////////////////////////////////////////////////////////////////////// $regfile = "m8def.dat" $crystal = 1000000 Dim Frq As Word Dim D As Word Config Pind.0 = Output Spkr Alias Pind.0 '---------------------------------- Do For Frq = 50 To 20 Step -1 'Step -1 => Speed D = 51 - Frq Sound Spkr , D , Frq Next Frq For Frq = 20 To 50 Step 1 'Step 1 => Speed D = 51 - Frq Sound Spkr , D , Frq Next Frq Loop '---------------------------------- '( Do Sound Spkr , 420 , 60 Sound Spkr , 620 , 40 Loop Do For Frq = 1 To 80 Set Portd.0 Waitms 3 Reset Portd.0 Waitms 3 Next Frq Waitms 500 Loop ') End
|
|
| |