Import LinuxCNC source tree
This commit is contained in:
10
tests/source.0/expected
Normal file
10
tests/source.0/expected
Normal file
@@ -0,0 +1,10 @@
|
||||
1
|
||||
1
|
||||
0
|
||||
0
|
||||
1
|
||||
1
|
||||
0
|
||||
0
|
||||
0
|
||||
1
|
||||
13
tests/source.0/runstreamer
Normal file
13
tests/source.0/runstreamer
Normal file
@@ -0,0 +1,13 @@
|
||||
#!/bin/sh
|
||||
halstreamer << EOF
|
||||
1 1 0 0 # Test loading 1 into the FF
|
||||
1 0 0 0
|
||||
0 1 0 0 # Test loading 0
|
||||
0 0 0 0
|
||||
1 1 0 0 # Test that it is edge sensitive, not level
|
||||
0 1 0 0
|
||||
0 0 1 0 # Test that reset works
|
||||
1 1 1 0
|
||||
0 1 1 1 # Test that reset overrides set
|
||||
0 1 0 1 # Test that set works
|
||||
EOF
|
||||
14
tests/source.0/sourced.hal
Normal file
14
tests/source.0/sourced.hal
Normal file
@@ -0,0 +1,14 @@
|
||||
|
||||
net a streamer.0.pin.0
|
||||
net b streamer.0.pin.1
|
||||
net c streamer.0.pin.2
|
||||
net d streamer.0.pin.3
|
||||
|
||||
net a flipflop.0.data
|
||||
net b flipflop.0.clk
|
||||
net c flipflop.0.reset
|
||||
net d flipflop.0.set
|
||||
|
||||
net n0 flipflop.0.out sampler.0.pin.0
|
||||
|
||||
|
||||
15
tests/source.0/test.hal
Normal file
15
tests/source.0/test.hal
Normal file
@@ -0,0 +1,15 @@
|
||||
loadrt threads name1=fast period1=100000
|
||||
loadrt flipflop
|
||||
|
||||
loadrt sampler depth=1000 cfg=b
|
||||
loadrt streamer depth=32 cfg=bbbb
|
||||
|
||||
source sourced.hal
|
||||
|
||||
addf streamer.0 fast
|
||||
addf flipflop.0 fast
|
||||
addf sampler.0 fast
|
||||
|
||||
loadusr -w sh runstreamer
|
||||
start
|
||||
loadusr -w halsampler -n 10
|
||||
Reference in New Issue
Block a user