How to find the Freqs bins Ok, so I'm kind of moving forward with implementing the STFT. I realise that I was taking the entire FFT and not the first half.

The problem that I'm having now is, understanding how to get the Freq bins, what calculation should I use? For example, I have been using this formula:

(10 * log10(sqrt(v[i][j].re * v[i][j].re + v[i][j].im * v[i][j].im)));


Which, I realise that this is for decibels. Currently, my graph looks like the following:



I know this makes sense to me now, this is finally starting to come together! 

Would this algorithm work?:

I take the magnitude of each of the elements inside the bin `mags = (re * re + im + im) I then find the maximum index of the bin, multiply it by the Fs and divide by the bin size?

If I did this, however, would this only give me 1 result for each block?
Your Y axis likely should be scaled to frequency (Hz), not FFT bin index [0..127].  The frequency scale would be something like the bin_index * sample_rate / FFT_length .