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

Search:

Type: Posts; User: UhClem

Page 1 of 3 1 2 3

Search: Search took 0.00 seconds.

  1. Replies
    12
    Views
    270

    A couple but they might confuse more than they...

    A couple but they might confuse more than they help. The first is something I wrote long ago for the SparkFun Logomatic. Straight up C and Arduino libraries nowhere to be found. My effort for the...
  2. Replies
    12
    Views
    270

    The SD specification shows a maximum FAT write...

    The SD specification shows a maximum FAT write time which can be up to 750ms. This is the time to update both copies of the FAT and the directory entry. Each of which probably requires a...
  3. Replies
    12
    Views
    270

    Open and close each file exactly once. If you...

    Open and close each file exactly once. If you want to make sure data is being written, use flush. Not too often as it can be really slow.
  4. Replies
    3
    Views
    149

    The data sheet shows an absolute maximum voltage...

    The data sheet shows an absolute maximum voltage on the I/O pins of OVdd+0.3V. With the USB supply pulled it is easy for external circuits to exceed that. Normally I wouldn't worry about I2C because...
  5. Replies
    8
    Views
    385

    There is always noise. The command to read the...

    There is always noise.

    The command to read the data registers will always return the value currently stored there even if it hasn't been updated in a long time. If the ODR is 400 and you read it...
  6. Replies
    8
    Views
    385

    All of the configuration details are hidden in...

    All of the configuration details are hidden in the library (not shown here) so I have no idea what it is doing. Things like the default ODR.

    With a serial data rate of 115Kbps you are not going to...
  7. Replies
    8
    Views
    385

    My code...

    My code isn't likely to help you much. Being very much a non-Arduino Forth sort of thing.
  8. Replies
    8
    Views
    385

    I2C is a bit slow for high data rates so SPI is...

    I2C is a bit slow for high data rates so SPI is the way to go. Also, the MPU9250 allows for higher SPI clock speeds when accessing just the data registers so check that out for your particular...
  9. Since the upper 16 bits are always zero, anything...

    Since the upper 16 bits are always zero, anything exceeding that is most likely the result of your processing.

    I looked at your original post again and realized that in your data plot you were...
  10. Kind of missing my point. Which was to find out...

    Kind of missing my point. Which was to find out what the bus clock is and set the ADC clock divider appropriately. (I am not an Arduino kind of guy so I have no idea if you used the analog library...
  11. It is in the device data sheet, which I grabbed...

    It is in the device data sheet, which I grabbed before I started. Most people use the library code and let it worry about such things.
  12. I can't tell if your ADC clock is in the required...

    I can't tell if your ADC clock is in the required range of 2Mhz to 12MHz but it appears that you are using the bus clock which typically runs much faster than that.
  13. The optimizer already does this.

    The optimizer already does this.
  14. Power while awake will depend mostly on your...

    Power while awake will depend mostly on your chosen clock rate so keep it it as slow as possible. If you really be asleep for only 75% of the time then the sleeping current draw doesn't matter as...
  15. Replies
    3
    Views
    272

    Differential input voltage range is VREFL to...

    Differential input voltage range is VREFL to 31/32 * VREFH. (table 31) The voltage limits for each pin are of course -0.3V to Vdd+0.3V.

    Note that while the voltage with respect to ground is always...
  16. Replies
    28
    Views
    1,308

    Use the existing 1024 point FFT on the 2KHz...

    Use the existing 1024 point FFT on the 2KHz bandwidth data to find the 50Hz band of interest. Then perform a frequency shift (like an analog mixer) to move that down closer to DC. Perhaps centered on...
  17. Replies
    28
    Views
    1,308

    There are fairly cheap ways to get into HF....

    There are fairly cheap ways to get into HF. https://www.hfsignals.com/

    Which is probably what I would do if I ever bothered to take the General test. Or perhaps even before since Tech does let me...
  18. Replies
    28
    Views
    1,308

    You still haven't mentioned a sample rate....

    You still haven't mentioned a sample rate. Assuming it is far above Nyquist you can decimate the data to reduce the sample rate. (Low pass filter to remove frequencies above the new Nyquist frequency...
  19. Replies
    28
    Views
    1,308

    FFT frequency resolution depends on sample rate...

    FFT frequency resolution depends on sample rate and number of samples. More samples gives higher resolution.
  20. Replies
    2
    Views
    184

    There are lots of ways to buffer the data. Here...

    There are lots of ways to buffer the data. Here is something I did long ago. The data is captured in an interrupt service routine while the foreground task just waits for there to be a full buffer...
  21. Replies
    13
    Views
    560

    It has been a while since I wrote that code and I...

    It has been a while since I wrote that code and I missed where I set A12EN which causes the hardware to do an auto CMD12 when the DMA finishes.

    Something that I find peculiar about transferStop()...
  22. Replies
    13
    Views
    560

    I do see that resetting the data path engine...

    I do see that resetting the data path engine (RSTD) is recommended when recovering from an error. I have never had to do that but I use the DMA system so perhaps that is something peculiar to the...
  23. Replies
    13
    Views
    560

    CMD12 isn't required to terminate multi-sector...

    CMD12 isn't required to terminate multi-sector I/O. I have written a couple of bare metal implementations for the 3.6 (C and Forth). Both do multi-sector writes and neither uses CMD12.
  24. Replies
    13
    Views
    560

    transferStop resets the SDHC data path (...

    transferStop resets the SDHC data path ( SDHC_SYSCTL |= SDHC_SYSCTL_RSTD;) which is not required for multi block transfers.
  25. Replies
    13
    Views
    560

    Is that better or worse than shutting down the...

    Is that better or worse than shutting down the clock? (SIM_SCGC3 &= ~SIM_SCGC3_SDHC;)

    I find your concern about using writes of less than 512 bytes of data very odd considering that I see at least...
  26. Replies
    13
    Views
    560

    Looking at the code for transferStop() what I see...

    Looking at the code for transferStop() what I see is something used to terminate a data transfer that is in progress. I don't know for sure what the intent was because nobody comments their code...
  27. Your diagram is incomplete as it doesn't show all...

    Your diagram is incomplete as it doesn't show all of the power connections. It is really easy to make a mistake and have ground current flow through your Teensy and turn traces into fuses. The Teensy...
  28. Replies
    13
    Views
    621

    Ratiometric means that the sensor output is...

    Ratiometric means that the sensor output is proportional to its excitation voltage and that the excitation voltage is identical to the ADC reference. Do that and the absolute value of the excitation...
  29. By providing power to the load cell from an...

    By providing power to the load cell from an independent supply you have to factor that supply voltage into the system calibration. This is why I prefer a ratiometric system where the sensor...
  30. Replies
    4
    Views
    353

    It sounds as though you have two ground...

    It sounds as though you have two ground connections. One for input power and another with your signal. The problem being that both are connected to the vehicle body. Creating a nice big loop to...
  31. Replies
    10
    Views
    483

    Enabled both the receiver and transmitter at the...

    Enabled both the receiver and transmitter at the same time so that you can receive what you are sending. Then compare the received packet to what was transmitted. If they are the same, there was no...
  32. Replies
    4
    Views
    356

    I have a Teensy 3.6 servicing MPU-9250 interrupts...

    I have a Teensy 3.6 servicing MPU-9250 interrupts at 32KHz. But I had to pay a lot of attention to how much time was required to transfer data. Even running the SPI port at 20MHz the timing is tight....
  33. It has been a long time since I looked at that...

    It has been a long time since I looked at that data sheet and I had completely forgotten about that footnote. Kind of unusual.

    But given that, the voltage limit of Vdd+0.3V is hard to explain. But...
  34. The pins have ESD protection diodes which can...

    The pins have ESD protection diodes which can cause trouble. Powered or not. It is entirely possible to run some micro-controllers with Vcc disconnected but drawing power from these diodes. (I have...
  35. Replies
    2
    Views
    240

    They start out identically. But in order to...

    They start out identically. But in order to switch the card into SPI mode you assert the CS pin while transmitting CMD0. SD mode (SDIO is actually a variant of SD cards) starts as 1 wire but you can...
  36. Sorry. I like the Teesy but dislike the Arduino...

    Sorry. I like the Teesy but dislike the Arduino environment. So much so that I went a different way for my logger.
  37. Why can't you do it in the ISR? Do you have...

    Why can't you do it in the ISR? Do you have something else going on that you haven't mentioned?

    While in general you do want to keep ISRs short, that is to keep from blocking other tasks. If there...
  38. Acquire the data in the ISR and store it in one...

    Acquire the data in the ISR and store it in one of many buffers. (Make the buffers at least 4KB in size and a nice power of 2.) The main routine just waits for there to be a full buffer and writes...
  39. Replies
    1
    Views
    183

    The output data rate in the ADXL345 depends on...

    The output data rate in the ADXL345 depends on its internal oscillator and the data sheet is silent on its accuracy and stability.
  40. Replies
    1
    Views
    410

    I suspect that this depends more on the software...

    I suspect that this depends more on the software (which you don't describe) than on the SD card.

    Any FAT library is going to create occasional pauses when it needs to search for a new cluster. If...
  41. Thread: Emmc

    by UhClem
    Replies
    15
    Views
    1,074

    MMC cards (and presumably eMMC) are a bit...

    MMC cards (and presumably eMMC) are a bit different and will require changes to the SD card drivers.

    I still have a 64MB MMC card gathering dust around here somewhere. I can't recall if I ever...
  42. Thread: Emmc

    by UhClem
    Replies
    15
    Views
    1,074

    The SDHC clock divisor is limited so for best...

    The SDHC clock divisor is limited so for best performance you need to carefully select the main clock. At 256MHz divide by six is the best you can do which means that the SD clock is slower than it...
  43. Replies
    2
    Views
    284

    There is a lot of code there, more than I really...

    There is a lot of code there, more than I really care to go through but a few things that jump out:

    You have no protection from writing data to a buffer after it is full. This will clobber...
  44. Replies
    16
    Views
    946

    You are doing it differently. I have a group of...

    You are doing it differently. I have a group of buffers. When one gets full, data goes into the next one. The main loop watches for a buffer to be full. When that happens, it writes the data to the...
  45. Replies
    16
    Views
    946

    It is about speed. Ideally interrupt service...

    It is about speed. Ideally interrupt service should be fast so that it doesn't hold up the rest of the code. As for calling other functions, the only problem I have noticed is the C compiler getting...
  46. Replies
    16
    Views
    946

    Yes. Writes to SD cards do that. Made worse by...

    Yes. Writes to SD cards do that. Made worse by using a FAT file system. Allocating a new cluster triggers a scan of the FAT (1 or more reads) and update. Which takes time. Dependent on the state of...
  47. Replies
    5
    Views
    376

    By writing to a lot of different files you bring...

    By writing to a lot of different files you bring the dynamics of that into play. FAT file systems have just so many entries in the initial directory table and will have to allocate more space after...
  48. I have to wonder why you are using an SPI...

    I have to wonder why you are using an SPI interface to the SD card when there is a dedicated SDHC high speed interface available.
  49. Replies
    33
    Views
    2,994

    According to the MPU9250 block diagram the I2C...

    According to the MPU9250 block diagram the I2C connection to the internal slave should be visible from the MPU9250 aux I2C pins. Monitoring that might give you some insight into where the problem...
  50. Replies
    5
    Views
    413

    I think you have an unrealistic expectation for...

    I think you have an unrealistic expectation for low pass filter performance.

    If you set the corner frequency to 200Hz and use a 400Hz sample rate then the attenuation will never be better than 3dB...
Results 1 to 50 of 109
Page 1 of 3 1 2 3