Quantcast
Channel: MCS Electronics Forum
Viewing all articles
Browse latest Browse all 20690

BASCOM-AVR Old versions : Timer : REPLY

$
0
0
in the following codes the timer value is 1200 how can increase and decrease timer value by pressing up and down keys '-----------------------[Definitions] $regfile = "m32def.dat" $crystal = 100000 $baud = 9600 '---------------------- '-----------------------[Timer1 Configuration] Config Timer1 = Timer , Prescale = 1024 Start Timer1 '---------------------- '-----------------------[GPIO Configuration] Config Porta.0 = Output : Led Alias Porta.0 '---------------------- '-----------------------[Variables] Dim A As Byte '~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ '--->[Main Program] Do If Timer1 = 1200 Then 'Tcnt1 Timer1 = 0 : Toggle Led End If Loop End '---<[End Main]

Viewing all articles
Browse latest Browse all 20690

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>