В итоге проблема была в излишне частом дрыгании ногами. МК у меня работал на частоте 8МГц, а между установкой и снятием напряжения с ноги я ставил всего 10-15 NOP-ов..
Когда я написал простую функцию задержки на 0xFF циклов и таким образом сильно снизил частоту ШИМ, динамик звонко запищал!
Получившийся код ниже
cmd_beep:
push temp
ldi temp, 0x01 ; длительность писка
cmd_beep_loop:
dec temp
push temp
ldi temp, 0xFF
cmd_beep_loop2:
SBI BUZZER_PORT, BUZZER_PIN
rcall delay
CBI BUZZER _PORT, BUZZER_PIN
rcall delay
dec temp
cpi temp, 0x00
brne cmd_beep_loop2
pop temp
cpi temp, 0x00
brne cmd_beep_loop
pop temp
ret
delay:
push temp
ldi temp, 0xFF
delay_loop:
dec temp
cpi temp, 0x00
brne delay_loop
pop temp
ret
We put all our recommendations through a 25-step reviews course of and verify them every three months to ensure they're still delivering on high quality games. Before 1992, slot machines were only in casinos and small shops, but 메리트카지노 later slot golf equipment began showing round the} nation. The hottest and quite a few had been "Vulcan 777" and "Taj Mahal". Since 2009, when gambling establishments had been banned, nearly all slot golf equipment disappeared and are found only in a specially approved gambling zones. With microprocessors now ubiquitous, the computer systems inside modern slot machines enable producers to assign a special probability to each symbol on every reel.
ОтветитьУдалить