aUCBLogo Demos and Tests / makewav2
to makewav2
rate=44100
size=rate
wavsize=48+size*2
wav=IntArray int wavsize/4
setWriter wav
typebin (list
[RIFF]
wavsize
[WAVE]
[fmt\ ]
16
Int16 1
Int16 1
rate
rate*2
Int16 2
Int16 16
[data]
size*2
)
repeat size
[ phi=360*repcount/rate
typebin Int16 16383*( (sin 40*phi)
- (sin 41*phi) )
]
setWriter []
playWave wav 1+8
ignore readChar
playWave [] 0
end