LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Need Help playing a wav file on PDA

Does anyone have a SIMPLE example of playing a wav file on a PDA using LabView PDA. The only working example I can find from NI "Advance Sound Example for LabVIEW PDA for Pocket PC" is a jumbled of confusing functionality. I'm mainly looking for a simple "play" example, but a simple "record" example would be helpful also.
Thanks - Bruce
0 Kudos
Message 1 of 9
(5,275 Views)
Hey Bruce,

If you're looking for a full featured example to play .wav files on a PDA, I would definitely suggest sticking to the Advance Sound Example for LabVIEW PDA for Pocket PC. It seems that just about every consideration about the file and what the user would want to do was considered in its development.

If however, you would rather just have a simple play example as you state in your posting, look into the VIs in the sound palette. Playing a file can be as easy as using the Sound Play Wave File.vi, and recording can be as easy as configuring a Sound Read followed by Sound Write.

Good luck.
JaredA
0 Kudos
Message 2 of 9
(5,272 Views)
Thanks for the feedback. Yes, the key is I'm looking for a simple example. I can't tell how the Advanced one works because it is way too complicated (at least for me) with all the extra code for recording and pausing,etc. I tried paring it down for play only and I get nothing. Obviously I'm doing something wrong.

Regarding Sound Play Wave File.vi on the PDA: It won't compile when targeted to the PDA. NI support has told me that this library call method depends on full windows and will not work on Pocket PC. I'm learning that this PDA stuff is "bleeding" edge right now and support seems to still be gearing up on the PDA knowledge level.
0 Kudos
Message 3 of 9
(5,272 Views)
Hello,

Well, I looked through the example code I tried to break it down to the point where you could create a simple Play VI. Unfortunately, I don't have the PDA target, so I'm uncertain if the little example that I have attached will run or not. If not, I also took a screen shot so you can see what VIs I used. I'm pretty sure I only used VI's that I found on the example itself.

Good luck.
Download All
Message 4 of 9
(5,272 Views)
Jared, Thanks for the sample. I appreciate the effort!

I was eager to try it, but unfortunately it won't compile when targeted for the PDA. It generates some errors I've not encountered before. Here they are in order.

Unsupported prim - BuildPath
Unsupported node - PropNodeMeth 94852
Unsupported node - PropNodeMeth 5184
Error creating temp dir in CreateDirCpyFiles

I know my PDA stuff is OK, because I can compile the Advanced example and all my other code I'm working on. These types of errors usually mean an attempt was made to use something not applicable to the PDA.

I'm still working on paring down the advanced example, because this one will compile. I can't believe they provided such a complicated exam
ple for such a simple feature. The Advanced example has record,pause,file open,save etc. that I just don't need. It also uses a rather complicated case engine that is somewhat overwhelming for a newbie like me.

Thanks again for the attempt.

-Bruce
0 Kudos
Message 5 of 9
(5,272 Views)
For those who might be able to help. Here is the code for as far as I've been able to strip down the Advanced example. I need to get rid of the "open" portion. I just want to hardcode a filename (wav file) as a constant and then play the darn thing. I have to admit I don't understand the new "timed loop" feature and going smaller than what's attached always breaks.
0 Kudos
Message 6 of 9
(5,272 Views)
I finally figured this out. Attached is a sample vi that will play a wav file from a hardcoded filename. Thanks for all the suggestions. - Bruce
0 Kudos
Message 7 of 9
(5,272 Views)
Did you ever find out what the error messages mean ?

I'm getting exactly the same messages with a vi i have but dont know where to start debugging ?
0 Kudos
Message 8 of 9
(5,222 Views)
I received this same basic sequence of errors in another example VI when I tried to build it for PDA. The problem is in the SimpleErrorHandler.vi. If you replace that with the PDA Error Handler.vi the VI may compile without errors.
0 Kudos
Message 9 of 9
(5,048 Views)