We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 01e8265 commit 72f450fCopy full SHA for 72f450f
inst/examples/example_spi_mcp3002.m
@@ -14,7 +14,10 @@
14
## along with this program. If not, see
15
## <https://www.gnu.org/licenses/>.
16
17
-## test program for octave - arduino - mcp3002 10 bit ADC (spi)
+% test program for octave - arduino - mcp3002 10 bit ADC (spi)
18
+
19
+sel_pin = "d10"
20
21
# Assuming connections of
22
# Arduino MCP3002
23
# D10 - 1 (CS)
@@ -32,7 +35,7 @@
32
35
# talk to the mpc3002 via spi - SS = D10 on uno
33
36
# set msb mode
34
37
#spi = spidev(ar, "d10")
- spi = device(ar, "spichipselectpin", "d10")
38
+ spi = device(ar, "spichipselectpin", sel_pin)
39
40
# command (bits) in MSB mode to device
41
# [START SGL ODN MSBF X X X X] [ X X X X X X X X ]
0 commit comments