summaryrefslogtreecommitdiffstats
path: root/tests/insn_SV.awl
blob: 4d9b73465753540bbd0a23097201f85891384fd3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
	// Start timer and let it expire
	CLR
	SV		T 10
	SET
	R		T 10
	U		T 10
	__ASSERT==	__STW VKE,	0
	SET
	L		S5T#100MS
	SV		T 10
	U		T 10
	__ASSERT==	__STW VKE,	1
	__SLEEP		101
	U		T 10
	__ASSERT==	__STW VKE,	0


	// Start timer and reset VKE before it expires
	CLR
	SV		T 10
	SET
	R		T 10
	U		T 10
	__ASSERT==	__STW VKE,	0
	SET
	L		S5T#100MS
	SV		T 10
	U		T 10
	__ASSERT==	__STW VKE,	1
	CLR
	SV		T 10
	U		T 10
	__ASSERT==	__STW VKE,	1
	__SLEEP		101
	U		T 10
	__ASSERT==	__STW VKE,	0


	// Reset signal
	CLR
	SV		T 10
	SET
	R		T 10
	U		T 10
	__ASSERT==	__STW VKE,	0
	SET
	L		S5T#100MS
	SV		T 10
	U		T 10
	__ASSERT==	__STW VKE,	1
	SET
	R		T 10
	U		T 10
	__ASSERT==	__STW VKE,	0
	__SLEEP		101
	U		T 10
	__ASSERT==	__STW VKE,	0
bues.ch cgit interface