圣龙扬特-AVR电子
标题:
tlc5615 DA转换
[打印本页]
作者:
赵彬
时间:
2013-6-27 14:53
标题:
tlc5615 DA转换
$regfile
=
"m8def.dat"
$crystal
=
8000000
$baud
=
4800
'8M晶振频率
$hwstack
=
32
'设置堆栈大小
$swstack
=
10
$framesize
=
40
Config
Portd
.
4
=
Output
Config
Portd
.
5
=
Output
Config
Portd
.
6
=
Output
Vdata
Alias
Portd
.
6
'数据输出口
Vclk
Alias
Portd
.
4
'时钟输出口
Cs
Alias
Portd
.
5
Dim
A
As
Word
A
=
20
A
=
A
*
64
Cs
=
1
Vclk
=
0
Vdata
=
0
Do
Cs
=
0
Vclk
=
0
Vdata
=
0
nop
Shiftout
Vdata
,
Vclk
,
A
,
1
,
12
nop
Cs
=
1
Loop
End
欢迎光临 圣龙扬特-AVR电子 (http://avr.cnta.net/)
Powered by Discuz! X2.5