I would like to use Duktape on my embedded device (ARM processor) to execute Javascript which will download a music stream and play it.
Question 1: Has anyone done that before? Is that possible at all (sound ouput)?
Question 2: If it is possible then I would also like to grab the PCM output and redirect it (not play on the SoundDriver directly). A pointer where to start would be great.
Thanks in advance for any help getting started folks!
Duktape provides an Ecmascript E5.1 compatible Javascript engine but doesn't provide any browser or platform bindings like DOM, network access, etc.
Duktape is intended to be embedded in a program so that you implement useful platform bindings in C code, and then use them from Javascript. In your case you could implement functions to download and play individual files, and then use Javascript code to call them to e.g. implement a playlist in Javascript.