Forum Rule: Always post complete source code & details to reproduce any issue!

Search:

Type: Posts; User: kpc

Page 1 of 6 1 2 3 4

Search: Search took 0.01 seconds.

  1. Thread: S/pdif

    by kpc
    Replies
    99
    Views
    38,181

    When watching on an oscilloscope, the stream...

    When watching on an oscilloscope, the stream seems like I want it to be, no gaps and the proper frequency. You are right, the __REV's are temporary. Also the 16 bit copying and outputting should be...
  2. Thread: S/pdif

    by kpc
    Replies
    99
    Views
    38,181

    OK now the file with the right bitstream (I...

    OK now the file with the right bitstream (I think).
    I now use 16 bit DMA copying and also 16 bit output from the I2S module. I know it is very ugly but it seems to do the trick for now.
    I had to...
  3. Replies
    4
    Views
    1,265

    Does it work without the display attached? Maybe...

    Does it work without the display attached? Maybe too much current draw.
  4. Thread: S/pdif

    by kpc
    Replies
    99
    Views
    38,181

    This is how I got this far. Still trying to...

    This is how I got this far.
    Still trying to convince the I2S module to output the correct number of bits without gaps, so not fully functional yet.
    It is already integrated in the audio lib. Like I...
  5. Thread: S/pdif

    by kpc
    Replies
    99
    Views
    38,181

    I do not know what Frank's intentions are, but I...

    I do not know what Frank's intentions are, but I just want to hook it up to my amplifier, so syncing between multiple inputs is not an issue for me.
    I assume here that my amplifier has a PLL to...
  6. Thread: S/pdif

    by kpc
    Replies
    99
    Views
    38,181

    Actually, I now left my clock at 11.29 MHz, since...

    Actually, I now left my clock at 11.29 MHz, since apparently the minimum bit clock divider is 2 (reg value 0).
  7. Thread: S/pdif

    by kpc
    Replies
    99
    Views
    38,181

    @Frank B, Unless you are using pure synthetic...

    @Frank B, Unless you are using pure synthetic waveforms, you cannot use 44100. With the audio shield it was possible, but the Teensy ADC clock needs to be an integer division of the system clock....
  8. Thread: S/pdif

    by kpc
    Replies
    99
    Views
    38,181

    Sorry, you are right. There was a small mistake,...

    Sorry, you are right. There was a small mistake, I had 192 L+R frames, seems 192 is the total number of frames, code was adjusted.
  9. Thread: S/pdif

    by kpc
    Replies
    99
    Views
    38,181

    I think I got it, only tested on PC. /* This...

    I think I got it, only tested on PC.


    /* This code is free to use */
    /* Kire Pudsje, May 2015 */
    #include <stdio.h>
    #include <stdint.h>
    #include <arpa/inet.h> // htonl

    // table assumes...
  10. Thread: S/pdif

    by kpc
    Replies
    99
    Views
    38,181

    I checked the status bits, and keeping everything...

    I checked the status bits, and keeping everything 0 is what we need.
    This boils down to: 44.1 kHz, no copyright, 1000ppm clock.
    I do not have luck with the raspi code. When testing with all zeros...
  11. Thread: S/pdif

    by kpc
    Replies
    99
    Views
    38,181

    In my encoding, I only calculate the parity on...

    In my encoding, I only calculate the parity on the final three bytes, the preamble is even by definition, as are the following 4 LSB bits, since for 16 bit data these will be zeros.
    Since the header...
  12. Thread: S/pdif

    by kpc
    Replies
    99
    Views
    38,181

    I am also playing a little with spdif. Nothing...

    I am also playing a little with spdif. Nothing working yet, but it seems that only very few modifications to output_i2s are needed.
    Also my interpretation of the spec might be wrong, but I get a...
  13. Replies
    12
    Views
    3,174

    The nice thing was that they mostly talked to...

    The nice thing was that they mostly talked to 'normal' people in the live videos.
    In Massimo's speech, on the sheet with libraries, 3 out of the 4 libraries he showed came from you. Just getting...
  14. Replies
    6
    Views
    2,018

    When i google for "multi-channel adc i2s", the...

    When i google for "multi-channel adc i2s", the first two links already seem promissing
    http://www.nxp.com/documents/data_sheet/UDA1338H.pdf
    http://www.ti.com/product/pcm3168a
    Have not checked...
  15. Thread: S/pdif

    by kpc
    Replies
    99
    Views
    38,181

    You can find some versions of IEC60958 on...

    You can find some versions of IEC60958 on law.resource.org.
    According to the spec:

    This is before encoding, since after encoding, the number of ones is fixed. For each unencoded bit due to the...
  16. Replies
    12
    Views
    3,174

    @Paul I am currently scanning through the "Live...

    @Paul
    I am currently scanning through the "Live from Bay Area Maker Faire 2015" videos on youtube. 17 hours of video!
    Wondering if they also talked to you.
    Keynote speech Massimo Banzi: The State...
  17. Thread: S/pdif

    by kpc
    Replies
    99
    Views
    38,181

    The master clock is used for the delta/sigma...

    The master clock is used for the delta/sigma modulator and the digital filters. The actual multiplication factor is determined by the I2S device, 256 is a commonly used factor. The SGTL5000 on the...
  18. Thread: S/pdif

    by kpc
    Replies
    99
    Views
    38,181

    I see you used F_CPU, I think you should use...

    I see you used F_CPU, I think you should use F_PLL.
    Furthermore, beware that the actual register values are the calulated values minus one.

    Edit: In Audio/output_i2s.cpp Paul lists the values he...
  19. Thread: S/pdif

    by kpc
    Replies
    99
    Views
    38,181

    I did not verify your FRACT/DIV values, but you...

    I did not verify your FRACT/DIV values, but you might want to check this thread. This code will perform the calculations based on the pll clock frequency setting. It might seem a pretty big function,...
  20. Thread: Fft256

    by kpc
    Replies
    22
    Views
    4,646

    OK, will try to verify here, but not before the...

    OK, will try to verify here, but not before the weekend.
  21. Thread: S/pdif

    by kpc
    Replies
    99
    Views
    38,181

    You might (ab)use the I2S FIFO to generate the...

    You might (ab)use the I2S FIFO to generate the SPDIF signal. The I2S clock has somewhat more flexibility and allows you to generate the exact clockrate.

    Edit: This suggestion above will not work...
  22. Thread: Fft256

    by kpc
    Replies
    22
    Views
    4,646

    Are you sure you are getting data? Bin 128 is the...

    Are you sure you are getting data? Bin 128 is the DC term so it looks like there is at least some offset present.
    An easy way to check (if you have an oscilloscope) is to connect the AudioInputI2S...
  23. Replies
    6
    Views
    1,571

    Just a bad example, since phase accumulator is...

    Just a bad example, since phase accumulator is private, but cannot think of a better example right away
    If you for example want to increment the phase by 90 degrees


    sine.phase_accumulator +=...
  24. Replies
    6
    Views
    1,571

    It is because the data is processed in blocks....

    It is because the data is processed in blocks. When the audio processing is triggered it will halt the main program and go into an interrupt routine that handles all audio stuff. This will calculate...
  25. Replies
    13
    Views
    2,655

    missing Contents?

    missing Contents?
  26. Replies
    13
    Views
    2,655

    1.6.3 might have the file somewhere else, in a...

    1.6.3 might have the file somewhere else, in a shell, cd to the arduino directory and perform:
    find -name mk20dx256.ld
  27. Replies
    13
    Views
    2,655

    You did not modify the LDFLAGS= and $TARGET lines

    You did not modify the LDFLAGS= and $TARGET lines
  28. Replies
    13
    Views
    2,655

    These are small snippets. The LDFLAGS= and...

    These are small snippets. The LDFLAGS= and $TARGET is already in Pauls Makefile. Just put the LINKFILE and the ifeq part before these lines.
  29. Replies
    13
    Views
    2,655

    OK, finally arrived at home. Indeed one of my...

    OK, finally arrived at home. Indeed one of my modications was to find the linkerscript.


    LINKFILE ?= mk20dx256.ld
    ifeq ($(wildcard $(LINKFILE)),)
    LINKSCRIPT ?=...
  30. Replies
    13
    Views
    2,655

    Did you set ARDUINOPATH?

    Did you set ARDUINOPATH?
  31. Replies
    22
    Views
    5,320

    Have a look at...

    Have a look at
    hardware/teensy/avr/cores/teensy3/Makefile
  32. Replies
    10
    Views
    3,186

    We seem to be out of sync, so there is some cross...

    We seem to be out of sync, so there is some cross posting happening.
    Can you verify that you have a weak signal, state the magnitude of the signal.
    Also see my previous remark about...
  33. Replies
    10
    Views
    3,186

    There is no scale to the plot, but it looks like...

    There is no scale to the plot, but it looks like you have a very weak signal, and you are not using the dynamic range fully. Maybe increase the gain of your amplifiers.
    If the signal is not very...
  34. Replies
    10
    Views
    3,186

    You might want to check pedvides library...

    You might want to check pedvides library. He is currently trying to support LC.
    Can you elaborate on what you mean with accuracy? Looking at your waveforms, it is not the effective resolution of the...
  35. Thread: PCB-production

    by kpc
    Replies
    85
    Views
    22,062

    For good performance of the antenna, you do not...

    For good performance of the antenna, you do not want it to be near any other metal. Either lift it up a few centimeters (ie more space between the two pcb's), Or shift it so that the antenna...
  36. Thread: PCB-production

    by kpc
    Replies
    85
    Views
    22,062

    At first sight it looks OK. I appreciate...

    At first sight it looks OK. I appreciate especially the two resistors, that keep a well defined CS state during start-up.
    Maybe it is me, but when clicking your link, I see
  37. Replies
    12
    Views
    3,174

    Was wondering if they used the NXP name yet, but...

    Was wondering if they used the NXP name yet, but I just checked their website, not even a single reference to NXP on their main homepage. Would be nice to here if these guys have any news/thoughts on...
  38. Thread: PCB-production

    by kpc
    Replies
    85
    Views
    22,062

    I can imagine my remarks can be considered like...

    I can imagine my remarks can be considered like critique and that I seem to be a know-it-all. This is probably partly cultural. However, my intentions are to help people.

    @Constantin, it is not my...
  39. Replies
    34
    Views
    15,880

    Try reading the error message it states where it...

    Try reading the error message it states where it can be found
    previous declaration of 'double y1(double)'
    y1 is one of the bessel functions
  40. Thread: PCB-production

    by kpc
    Replies
    85
    Views
    22,062

    I agree, it can seem contradictionary, but for...

    I agree, it can seem contradictionary, but for different frequencies different effects play a role, so you should always be aware of what background someone has and with what application.
    For...
  41. Replies
    6
    Views
    3,915

    The mic input is intended for an electret...

    The mic input is intended for an electret microphone. The board you are using already has a line-out signal, so connect it to line-in.
    For an example look at: File - Examples - Audio - Analysis -...
  42. Replies
    166
    Views
    100,247

    In the right picture it looks like you are adding...

    In the right picture it looks like you are adding the signals with the oscilloscope in the digital domain.
    Oscilloscopes in general have very bad dynamic range. To increase the dynamic range,...
  43. Replies
    40
    Views
    6,943

    I might not completely get the idea, but you need...

    I might not completely get the idea, but you need to generate a low/high impedance from a sensor pin to ground?
    Why not put one resistor to ground (the high impedance) and then connect the other to...
  44. Replies
    26
    Views
    6,440

    @Paul Sorry if I missed the news. But I notice...

    @Paul

    Sorry if I missed the news. But I notice you are talking in past tense. Court case settled?
  45. Replies
    26
    Views
    6,440

    OK and how do you think how the teensy would...

    OK and how do you think how the teensy would handle all these concurrency issues? Essentially you are asking for the teensy to become an RTOS.
    Most arduino libraries are already set up, so that they...
  46. Thread: Fft256

    by kpc
    Replies
    22
    Views
    4,646

    First, the compilation error seemed trivial. I...

    First, the compilation error seemed trivial.
    I did put your cpp and header file in the same directory as the sketch.
    I noticed that I had to add utility to the include


    #include...
  47. Thread: Fft256

    by kpc
    Replies
    22
    Views
    4,646

    Just for information: By testing the fft...

    Just for information:
    By testing the fft function above, I was trying to obtain a symmetric spectrum by disabling the cosine amplitude.
    I noticed that both AudioSynthWaveformSine and also...
  48. Thread: Fft256

    by kpc
    Replies
    22
    Views
    4,646

    There is one little bug, that is also in the...

    There is one little bug, that is also in the original FFT code, which depending on your usage might trouble you. In the header outputflag should be volatile


    volatile bool outputflag;

    Just...
  49. Thread: Fft256

    by kpc
    Replies
    22
    Views
    4,646

    Did you test it yet? I would start by applying a...

    Did you test it yet? I would start by applying a sine and cosine generator to both inputs.

    My remark about the reads was more towards when you use the read(unsigned int binFirst, unsigned int...
  50. Replies
    22
    Views
    4,265

    @defragster, this error is because nested...

    @defragster, this error is because nested comments are not allowed. The usual trick to comment big sections is to use the preprocessor


    #if 0
    lots of stuff here, including comments.
    #endif
Results 1 to 50 of 285
Page 1 of 6 1 2 3 4