Jump to content

Search the Community

Showing results for tags 'sampling'.

More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


  • News
    • Announcements
    • Suggestions
    • New users say Hi!
  • Spotlight!
    • Sponsor Spotlight
    • Sponsor Giveaways
  • Energia
    • Energia - MSP
    • Energia - TivaC/CC3XXX
    • Energia - C2000
    • Energia Libraries
  • MSP Technical Forums
    • General
    • Compilers and IDEs
    • Development Kits
    • Programmers and Debuggers
    • Code vault
    • Projects
    • Booster Packs
    • Energia
  • Tiva-C, Hercules, CCXXXX ARM Technical Forums
    • General
    • SensorTag
    • Tiva-C, Hercules, CC3XXX Launchpad Booster Packs
    • Code Vault
    • Projects
    • Compilers and IDEs
    • Development Kits and Custom Boards
  • Beagle ARM Cortex A8 Technical Forums
    • General
    • Code Snippets and Scripts
    • Cases, Capes and Plugin Boards
    • Projects
  • General Electronics Forum
    • General Electronics
    • Other Microcontrollers
  • Connect
    • Embedded Systems/Test Equipment Deals
    • Buy, Trade and Sell
    • The 43oh Store
    • Community Projects
    • Fireside Chat
  • C2000 Technical Forums
    • General
    • Development Kits
    • Code Vault
    • Projects
    • BoosterPacks


There are no results to display.

Find results in...

Find results that contain...

Date Created

  • Start


Last Updated

  • Start


Filter by number of...


  • Start



Website URL





Found 3 results

  1. I'm creating a kind of Yak Bak for a project I'm working on for my small son. The basic idea is that I'll start recording audio when one button is pressed, and start playing it back when another has been pressed. My initial plan was to just use something like an msp430g2553's onboard ADC to sample a microphone, and play it back using a PWM output. From what I can tell, I should sample my audio at 8 kHz to satisfy the Nyquist theorem. It looks like an msp430g2553 (and all comparable processors I've looked at) have a maximum sampling rate of at most, 500 samples/second -- taken from the minimum conversion time listed in the msp430g2553 datasheet. Those two numbers are obviously not the same, which leads me to believe I'm going to run into issues. How would you guys recommend handling this? I could beef up my processor, but that might require a bit more soldering ability than I currently have. Or I could go with a standalone ADC chip, but I'll have to read the data in sometime, and I'm not convinced my processor would be able to keep up. Thanks!
  2. I'm using a Tiva C series launchpad (TM4C123G) to sample analog data using an external ADC (ADC0804). The ADC is clocked at 1.4MHz. The SysCtlClockSet command was used to set clock freq to 80MHz. A square wave is being generated on a pin, with a frequency same as the sampling rate, using the code given below. So this gives us the sampling rate on an oscilloscope. For some reason the sampling rate is TOO low. It is only ~330KHz with NO command in the loop. It drops to about ~280KHz with one digitalRead and to just a few hundred Hz with a SerialPrintln(). What is causing it to run so slow and how can it be improved? #include <tm4c123ge6pm.h> #include <stdint.h> #include <stdbool.h> #include <pin_map.h> #include <sysctl.h> int db0 = PB_3; int db1 = PC_4; int db2 = PC_5; int db3 = PC_6; int db4 = PC_7; int db5 = PD_6; int db6 = PD_7; int db7 = PF_4; int cs = PB_5; int rd = PD_1; int wr = PD_0; int intr = PE_4; int out = PD_3; int a = 0; int count = 1; int b; boolean flag = 0; void setup() { SysCtlClockSet(SYSCTL_SYSDIV_2_5|SYSCTL_USE_PLL|SYSCTL_OSC_MAIN|SYSCTL_XTAL_16MHZ); //SysCtlClockSet(SYSCTL_USE_PLL|SYSCTL_OSC_MAIN|SYSCTL_XTAL_16MHZ|SYSCTL_SYSDIV_2_5); pinMode(db0, INPUT); pinMode(db1, INPUT); pinMode(db2, INPUT); pinMode(db3, INPUT); pinMode(db4, INPUT); pinMode(db5, INPUT); pinMode(db6, INPUT); pinMode(db7, INPUT); pinMode(out, OUTPUT); pinMode(cs, OUTPUT); pinMode(rd, OUTPUT); pinMode(wr, OUTPUT); pinMode(out, OUTPUT); pinMode(intr, INPUT); pinMode(db0, INPUT); pinMode(db1, INPUT); pinMode(db2, INPUT); pinMode(db3, INPUT); pinMode(db4, INPUT); pinMode(db5, INPUT); pinMode(db6, INPUT); pinMode(db7, INPUT); Serial.begin(9600); //Code of initialzation... //Step C digitalWrite(cs, LOW); delay(100); //has to be type unsigned long digitalWrite(out,HIGH); b=1; } void loop() { flag = !flag; digitalWrite(out,flag); a= digitalRead(db0); count = 1; a = 0; a = a+ digitalRead(db0)*count; count = count*2; a = a+ digitalRead(db1)*count; count = count*2; a = a+ digitalRead(db2)*count; count = count*2; a = a+ digitalRead(db3)*count; count = count*2; a = a+ digitalRead(db4)*count; count = count*2; a = a+ digitalRead(db5)*count; count = count*2; a = a+ digitalRead(db6)*count; count = count*2; a = a+ digitalRead(db7)*count; count = count*2; Serial.println(a); //Serial.println(SysCtlClockGet()); }
  3. hi everyone, i'm sampling from single channel ADC and send the data over UART. now i need to two channel simultaneously and send the data. for one channel my code is below: ----------------------------------------------- ADC10CTL1 = INCH_5 + ADC10DIV_3 ; // Channel 5, ADC10CLK/4 ADC10CTL0 = SREF_0 + ADC10SHT_3 + ADC10ON + ADC10IE; //Vcc & Vss as reference ADC10AE0 |= BIT5; ADC10CTL0 |= ENC + ADC10SC; // Sampling and conversion start, single measure! while(1) { if(!((P1IN & BUTTON)==BUTTON)) { ADC10CTL0 |= ENC + ADC10SC; value1 = ADC10MEM>>2; // used only 8 bits of 10bits adc conversion... while ((UCA0STAT & UCBUSY)); // Wait if line TX/RX module is busy with data UCA0TXBUF = value1; } } } ------------------------------------------------- can you please help me to make following changes... i need to use p1.4 and p1.5 for ADC conversion (two channel), and the ADC referance voltage should be 2.5V or lower. thank you all...
  • Create New...