Here is an annotated interactive session that I hope answers John's questions (Octave version is 5.2.0, on Windows 10, arduino version looks like 0.6.0):
>> pkg load arduino
>> a=arduino()
a =
arduino object with fields of:
port = \\.\COM4
board = uno
libraries = {
i2c
spi
servo
shiftregister
}
availablepins = {
d0 - d13
a0 - a5
}
>> playTone(a,'D10',440,1) %piezo speaker is attached to D10 and makes a tone that never stops
>> playTone(a,'D10',300,1) %frequency changes but never stops
>> playTone(a,'D10',0,1) %sound stops
>> playTone(a,'D10',180,3) %makes a tone that never stops
>> playTone(a,'D10',440,0) %frequency changes but never stops
>> version %I think this gives the version of octave
ans = 5.2.0
>> pkg list %It looks like arduino package version is 0.6.0
Package Name | Version | Installation directory
---------------------+---------+-----------------------
arduino *| 0.6.0 | ...\OCTAVE~1.0\mingw64\share\octave\packages\arduino-0.6.0
audio | 2.0.0 | C:\Octave\OCTAVE~1.0\mingw64\share\octave\packages\audio-2.0.0
communications | 1.2.2 | ...\mingw64\share\octave\packages\communications-1.2.2
It is my understanding that the last parameter is supposed to be duration in seconds. So I'd expect the tones to stop after that time has elapsed.
Thanks.
-Cathy