LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Help with the MIDI read function

Since my last post, I have gotten NI LabVIEW 8.5 and DSP module 2.5.  Using the MIDI read function I was able to get it to read from MIDI-Yoke and plot onto some graphs.

My problem, however, is that I'm not sure how exactly the MIDI file is being read.  The DSP module update files say that the information is sent as an array of 5 notes.  This is clear to see that it is reading in these 5 values.  When I plot wire the MIDI read to a graph however and/or output through a DSP board, It seems as though I am only getting one of those values.

Can anyone tell me if I am doing anything wrong or how to get all the values from the MIDI read plotted and outputed.

Thanks
0 Kudos
Message 1 of 13
(3,966 Views)

Hi Joeyio,

Thank you for contacting National Instruments.  If the MIDI read VI is returning an array of 5 elements, they should all appear on the graph you wire that output to.  Is there anyway you could post a screenshot or a short example program of what you currently have set up?

I look forward to hearing back from you.

 

Regards,

Kevin H

National Instruments
WSN/Wireless DAQ Product Support Engineer
0 Kudos
Message 2 of 13
(3,939 Views)
First of all, I'll explain briefly what I'm working on.  I'm trying to use the MIDI read function to read a MIDI file and apply concepts of DSP to create a real-time learning module to make the concepts of DSP easier to understand for students.

Ok, I was just doing very simple programs to get the basics of the MIDI read function.  I simply wired the MIDI read control to a multi-purpose graph, a waveform chart, and a waveform graph.  I did this with and without a filter to examine differences in frequency plots, and like I said earlier, I was really just playing around with the control.  I then added an analog output.  When I listened, it seemed I was getting all the rythms, but in a really high frequency along with a few real low frequency booms (like bass drum).  I was wondering if that was because I was only getting one frequency from the array that is read in through the MIDI read. 

Is there something I'm missing, or can you better explain this MIDI read control to me?

Thank you
0 Kudos
Message 3 of 13
(3,930 Views)
Hey Joeyio,
 
After playing around the with MIDI read control, it looks like it is returning the value for each channel in the file (5 channels).  When I wire that to a graph, I then see the all five values plotted on the graph at the same time, on one line.  Are you seeing this same behavior, or does it appear that only one note (out of five) is appearing on that graph?  A screenshot of the graph you are talking about would be great to look at as well!
 
Regards,
 
Kevin H
National Instruments
WSN/Wireless DAQ Product Support Engineer
0 Kudos
Message 4 of 13
(3,914 Views)
Attached is a screenshot of my front panel.

Yes it seems as the array is being read in through the MIDI read (all 5 values are showing up).  On the graphs, I suppose it would be all five values plotted at once.  This makes sense to me, and what I initially thought.  What made me skeptical of the function was that when I outputted the signal, I didn't hear the same sound as was being inputed.  As I previously mentioned, I could only hear a really high pitched sound, that was the rythm of the particular MIDI file.  It wasn't the original sound.  (I was testing the output.  I would like to add synths, filters, etc. and be able to output this so that the changes can be heard, not just seen on graphs)

Thanks for the help,

Joeyio

0 Kudos
Message 5 of 13
(3,907 Views)
Hey Joey,
 
What DSP board are you using.  Also, how are you listening to the file?  Are you using the onboard speaker, or some other external speaker?
 
Regards,
 
Kevin H
National Instruments
WSN/Wireless DAQ Product Support Engineer
0 Kudos
Message 6 of 13
(3,893 Views)
I'm using the Speedy-33 external DSP board.  I'm running the signal to an analog output, and I've tried using external speakers (headphones and speakers).  Both produced the same result.  I was thinking that the problem may be from the board itself, but I am not sure.  Any ideas?

Thanks  
0 Kudos
Message 7 of 13
(3,890 Views)

Hey Joey,

I have a tracked down a Speedy 33, so now I want to replicate what you have going on.  Is there anyway you can upload your project file here?  I think it will be much easier for me to see what you have going on if I am actually able to test and run it here on my end!  Also, be sure to let me know any other details you think I may need to know when I recreate it here.

Regards,

Kevin H

National Instruments
WSN/Wireless DAQ Product Support Engineer
0 Kudos
Message 8 of 13
(3,874 Views)
What I'm doing is very simple.  I put an analog out and ran the MIDI read function straight to it.

Thanks 
0 Kudos
Message 9 of 13
(3,869 Views)
Hey Joeyio,
 
I have hooked up everything here, and I believe I am getting the same results as you are.  I am hearing nothing but a high frequency that goes to the beat of the song.  I am assuming you are expecting to hear the midi file itself in this output?  This is my first time working with the Speedy, and there does not seem to be very much documentation on the Midi Read control.  Let me do some research, and find out what needs to be done in order to hear the midi file from this output.
 
Regards,
 
Kevin H
National Instruments
WSN/Wireless DAQ Product Support Engineer
0 Kudos
Message 10 of 13
(3,858 Views)