Multithreaded analog input and output and serial communication during the AIAO

I need to read in analog data on 4 channels (4000 scans/s on each channel for a total of 250ms) and while this is happening send out two signals: A trigger pulse (which I currently send on an analog channel, using channel DAC0OUT) and two ascii commands using the serial port. My problem is that the data acquisition VI I am using is a blocking VI, it runs to completion before allowing the two signals to be sent. I am using the VI titled, "AI Acquire Waveforms (scaled array).vi" I don't need to look at the acquired data until after the whole operation is complete. Any help anyone can offer would be much appreciated.

Hello Mark,
The AI Read VI will block other operations when waiting for data. I would suggest to reduce the number of scans to read (this is an input for the AI Read VI) to help with handling multiple operations simultaneously. By reducing the number of scans to read by the AI Read VI, it won't have to wait for the whole buffer to be read in before "unlocking" the CPU for other operations. You could place the AI Read in a loop and acquire smaller chunks of the data at a time. For instance, your buffer size is probably 1000. Instead of calling the AI Read VI once and waiting for all 1000 scans, you could place the AI Read in a for loop and acquire 200 scans at a time (have the for loop run 5 times).
Or you could set up the AI Read VI to read 0 scans the fir
st time and then just read whatever is in the backlog on subsequent calls. There is a backlog output to AI Read; you could use this with a shift register within a loop to read only the data that is already in the buffer. For both of these cases, I would place a wait in the loop (25-100 ms) to give the CPU time to do other things.
Another method is to use an occurrence. Place the Functions >> DAQ >> Misc >> Set DAQ Occurrence.vi on your block diagram and set the "DAQ Event" input to "Fire every n scans" (the actual string is a little different). Then put in a Wait on Occurrence function (Functions >> Advanced >> Synchronization >> Occurrence) When you use an occurrence, you are waiting for the driver to tell you when the data is acquired, rather than constantly querying the driver, so it is much faster.
One of these suggestions should help.
Let me know if you have any additional questions.
Regards,
Todd D.
NI Applications Engineer

Similar Messages

  • My iWork (pages and keynote) are not communicating with the iCloud. I haven't changed anything and all of the sudden there is no sync happening.  My iCloud account is fine as i can create documents on my iPad and they appear on iCloud.

    my iWork (pages and keynote) are not communicating with the iCloud. I haven't changed anything and all of the sudden there is no sync happening.  My iCloud account is fine as i can create documents on my iPad and they appear on iCloud. However, when i change documents on my mac (documents that are supposed to be in the iCloud), the changes do not sync with my other devices nor with iCloud.  Even when i create new documents on my mac and save them to iCloud, all seems okay and i can access them from my mac, however they do not show up in the iCloud and i can't access them with my other devices.
    Most recent version of mountain lion updated over a month ago.  New iPad in use for over a month.
    thanks

    The same thing is happening to me, Mail was fine about an hour ago and now is rejecting correct password.  Typical when today I'm waiting some important emails!

  • App-V PowerShell: Script to Query XenApp Servers for App-V Publishing Errors and Output an Excel Document with the Results

    Please Vote if you find this to be helpful!
    App-V PowerShell:  Script to Query XenApp Servers for App-V Publishing Errors and Output an Excel Document with the Results
    Just posted this to the wiki:
    http://social.technet.microsoft.com/wiki/contents/articles/25323.app-v-powershell-script-to-query-xenapp-servers-for-app-v-publishing-errors-and-output-an-excel-document-with-the-results.aspx

    Hi petro_jemes,
    Just a little claritification, you need to add the value to the variable "[string]$ou", and also change the language in the variable "$emailbody" in the function "Get-ADUserPasswordExpirationDate".
    I hope this helps.

  • Hi, i purchased and downloaded the lr6 desktop app (update), and used my serial number from the email from adobe but it said it was only eligible for lr5. thanks, rich

    hi, i purchased and downloaded the lr6 desktop app (updating from lr5, paid 80. for the update), and used my serial number from the email from adobe sentbut it said it was only eligible for lr5. thanks, rich

    If you purchased an upgrade from LR5 to LR6 then after you enter your LR6 serial number, you will need to enter your LR5 serial number, unless LR6 finds LR5 on the computer.  This also assumes that you've purchased the perpetual license of both LR5 and LR6, not a cloud license for LR5 which doesn't use a serial number for licensing.  If entering a LR6 then LR5 serial number into LR6's serial-number area isn't working, then is there something special about the LR5 that would make it ineligible for an upgrade?

  • HT5731 how can I cancel or delete a movie i downloaded to my iPhone?  The file is too large and it is hung up during the download process

    How can I cancel or delete a movie I tried to download to my iPhone?  The file is too large and iTunes is hung up during the process of downloading.  I've tried to swipe from right to left but that doesn't produce a delete button....

    Slide your finger across the videos' listing in your iPhone Videos App and tap the red "Delete" button that appears.

  • Table and views which are afftected during the SAP license post processing

    Hi,
    can anyone tell me those table and views which are afftected during the SAP license post processing process in SAP 4.7 installation on oracle.
    Regards,
    Abhishek

    hi
    there is no table active with the name MLICHECK
    the table is not active in the dictionary
    what to do now?
    i want to see the license data of the sap system now in the table view..............

  • I recently purchased "The Simpsons Movie" on iTunes, but it is not appearing on my cloud - or under recent purchases in iTunes. I was charged for the purchase and received a receipt. During the download i received an error message.

    I recently purchased "The Simpsons Movie" on iTunes, but it is not appearing on my cloud - or under recent purchases in iTunes. I was charged for the purchase and received a receipt. During the download i received an error message.

    Store > Check for available downloads
    Or report a problem...
    tt2

  • My iPod was updating to iOS 6 and i shut it off during the update because it was taking too long and now my screen in baby blue i've tried to drain the battery but when i plugged it in to charge the blue screen came back on.I dont know what to do

    My iPod was updating to iOS 6 and i shut it off during the update because it was taking too long and now my screen in baby blue i've tried to drain the battery but when i plugged it in to charge the blue screen came back on.I dont know what to do

    Try:
    - iOS: Not responding or does not turn on
    - If not successful and you can't fully turn the iPod fully off, let the battery fully drain. After charging for an least an hour try the above again.
    - If still not successful that indicates a hardware problem and an appointment at the Genius Bar of an Apple store is in order.

  • My iMac starts up and then shuts itself down during the boot up process. it shuys down half way through the Apple logo appearing. any ideas how to fix?

    My iMac starts up and then shuts itself down during the boot up process. it shuys down half way through the Apple logo appearing. any ideas how to fix?

    Hi daveormond,
    I'm sorry to hear you are having these issues with your iMac. If you continue to have issues with your Mac shutting down part way through the boot up process, you may find the troubleshooting steps outlined in the following articles helpful (given your description, it sounds like it could be either issue, or a combination of both):
    Mac OS X: Gray screen appears during startup - Apple Support
    OS X: When your computer spontaneously restarts or displays "Your computer restarted because of a problem." - Apple Support
    Regards,
    - Brenden

  • Error -200279 with simultaneous analog input (different devices) and digital output.

    Hi guys,
    I am a beginner in Labview and have been dealing with this problem for a couple of weeks now and just can't seem to get it completely right, I have a feeling there are a few small bugs in my code/hardware setup.
    I am running an scxi-1000 chassis with a 1600 module and 1302C along with a 1303 accesory for temperature measurements, this is connected to four thermoucouples. Unfortunately I have a limited number of modules available so I am also using a PCI-6221 DAQ card with an scb-68 breakout box used for a digital output and analog input voltage channel. Attached is my labview program. When I run the code at a 50 Hz sampling rate it runs with no errors but the data file comes out extremely wrong, this is also attached. When I run the code at 100 Hz I get error-200279 after a few loops. I used to have 2 daqmx timing VIs (one for each input), but the same error would eventually happen, I have also tried increasing the buffer size on said timing VI. I am also using an old computer (Pentium IV) could this effect the program?
    I have learned a lot going through forms for similar problems to mine but I just can't get it to for an extended period of time, I have posted my simplest code.
    Thanks in advance,
    Luca
    Attachments:
    tc_2.txt ‏1102 KB
    FinalCombined_2.vi ‏128 KB

    Ok this makes sense. I have made the suggested modifications but still getting the same error with sampling rates of 100 Hz or higher. Could you check that I have implemented the queue VIs properly (new file attached)? Also when running at 50 Hz in debug mode it does not look like the second while loop (with the dequeue element) comes into play until I hit the stop button, once I hit the stop button I get the following error:
    Error 1 occurred at Dequeue Element in FinalCombined_2.vi
    Possible reason(s):
    LabVIEW: An input parameter is invalid. For example if the input is a path, the path might contain a character not allowed by the OS such as ? or @.
    =========================
    NI-488: Command requires GPIB Controller to be Controller-In-Charge.
    This leads me to believe I have programmed the queue elements incorrectly.
    Thanks for your help, any suggestions are greatly appreciated.
    Luca
    Attachments:
    FinalCombined_2.vi ‏102 KB

  • Arduino due and Labview wirelss serial communication using Xbee

    Hello.
    I am controlling a mobile robot using the Arduino due and labview
    PWM value caculated on the labview is sent to Arduino due and then Due controls the robot.
    These communicate wirelessly by xbee.
    Now, I'd like to increase the communication speed between Arduino due and Labview.
    but, when i set the value of the "Wait(ms)" function to below 10ms  in Labview, communication has unstability.
    so please let me know how increase the communication speed.
    thank you.
    -experiment image-
    https://www.youtube.com/watch?v=oZdMCdHlDhM
    - Arduino source-
    #include <string.h>
    int PWM1 = 5;
    int DIR1 = 4; //direc
    int PWM2 = 6;
    int DIR2 = 7; //dir
    float readNumber = 0;
    float In1, In2, pwm, newtime, A;
    float newposition1 = 0;
    float newposition2 = 0;
    unsigned int Aold1 = 0;
    unsigned int Bnew1 = 0;
    unsigned int Aold2 = 0;
    unsigned int Bnew2 = 0;
    volatile long encoder1Pos = 0;
    volatile long encoder2Pos = 0;
    int encoder1PinA = 8;//Encoder A pin
    int encoder1PinB = 9;//Encoder B pin
    int encoder2PinA = 11;//Encoder A pin
    int encoder2PinB = 12;//Encoder B pin
    int Direction1, Direction2;
    float pwm1_limit=255;
    float pwm2_limit=255;
    float count_old = 0;
    float power1_old, power1_old2, power1_old3, power1_old4, power1_old5;
    void setup() {
    // put your setup code here, to run once:
    pinMode(DIR1, OUTPUT);
    pinMode(DIR2, OUTPUT);
    Serial.begin(115200);
    Serial.flush();
    Serial2.begin(115200);
    Serial2.flush();
    pinMode(encoder1PinA, INPUT);
    digitalWrite(encoder1PinA, HIGH); // turn on pullup resistor
    pinMode(encoder1PinB, INPUT);
    digitalWrite(encoder1PinB, HIGH); // turn on pullup resistor
    pinMode(encoder2PinA, INPUT);
    digitalWrite(encoder2PinA, HIGH); // turn on pullup resistor
    pinMode(encoder2PinB, INPUT);
    digitalWrite(encoder2PinB, HIGH); // turn on pullup resistor
    attachInterrupt(encoder1PinA, d1EncoderA, CHANGE);
    attachInterrupt(encoder1PinB, d1EncoderB, CHANGE);
    attachInterrupt(encoder2PinA, d2EncoderA, CHANGE);
    attachInterrupt(encoder2PinB, d2EncoderB, CHANGE);
    void loop() {
    if(Serial2.available()>0){
    String first = Serial2.readStringUntil('!');//랩뷰에서 받는 2개의 값을 분리하기 위한 소스("!"앞까지 끊고, "@"앞까지 끊음 ex)123!456@을 받으면 123과 456으로 나눔)
    String second = Serial2.readStringUntil('@');//http://stackoverflow.com/questions/29504679/splitting-a-comma-separated-string-through-serial-arduino
    float x = first.toFloat();//위에서 분리된 문자를 float형으로 바꿔줌
    float y = second.toFloat();
    newposition1 = -encoder1Pos; //Encoder signal
    newposition2 = encoder2Pos; //Encoder signal
    count_old = 0;
    float power1 = x;
    float power2 = y;
    if(power1 >= 0){
    Direction1 = LOW;
    else{
    Direction1 = HIGH;
    if(power2 >= 0){
    Direction2 = HIGH;
    else {
    Direction2 = LOW;
    power1 = abs(power1);
    power2 = abs(power2);
    if(power1 > pwm1_limit){
    power1 = pwm1_limit;
    if(power2 > pwm2_limit){
    power2 = pwm2_limit;
    digitalWrite(DIR1, Direction1); //HIGH = back, LOW = forward
    digitalWrite(DIR2, Direction2); //HIGH = back, LOW = forward
    analogWrite(PWM1, power1);//PWM Speed Control
    analogWrite(PWM2, power2);//PWM Speed Control
    String strValue = String(newposition1);//숫자를 문자형으로 변환
    String Q = "!";
    String strValue2 = String(newposition2);
    String stringThree = strValue + Q + strValue2;//문자 합치기
    Serial2.println(stringThree);//Send encoder pulse to Labview
    else {//when Serial communication stop
    float count = count_old+1;
    if(count > 10000){
    newposition1 = 0; //Encoder initialization
    newposition2 = 0; //Encoder initialization
    encoder1Pos = 0;
    encoder2Pos = 0;
    else{
    newposition1 = newposition1; //Encoder signal
    newposition2 = newposition2; //Encoder signal
    count_old = count;
    Serial.println(count);
    //Encoder Read//////////////////////////////////////////////////////////
    void d1EncoderA()
    Bnew1^Aold1 ? encoder1Pos++ : encoder1Pos--;
    Aold1 = digitalRead(encoder1PinA);
    void d1EncoderB()
    Bnew1 = digitalRead(encoder1PinB);
    Bnew1^Aold1 ? encoder1Pos++ : encoder1Pos--;
    void d2EncoderA()
    Bnew2^Aold2 ? encoder2Pos++:encoder2Pos--;
    Aold2=digitalRead(encoder2PinA);
    void d2EncoderB()
    Bnew2=digitalRead(encoder2PinB);
    Bnew2^Aold2 ? encoder2Pos++:encoder2Pos--;
    }

    piZviZ wrote:
    Only data rate working is 9600  between labview and launchpad(arm cortex m4).Where all data rates work between Arduino serial port monitor and launchpad(arm cortex m4).
    Since the only thing that changed is the Launchpad, then that must be the issue.  Are you sure this device can handle more than just the 9600 baud rate?  Are you sure you are even setting the baud rate on this device?

  • Synchronize input and output tasks to start at the same sample point [C++ NI_DAQmx Base]

    I'm trying to initiate the analog input and output streams to start reliably at the same sample. I've tried triggering the output from the start of the input using the following code [NI-DAQmx Base 2.1 under Mac OS X with an M-Series multifunction board]. It compiles and runs, but gives an error message at the call to "DAQmxBaseCfgDigEdgeStartTrig". Any suggestions about synchronized I/O on this platform?
    #include "NIDAQmxBase.h"
    #include
    #include
    #include
    #define DAQmxErrorCheck( functionCall ) { if ( DAQmxFailed( error=( functionCall ) ) ) { goto Error; } }
    int main( int argc, char *argv[] )
    // Task parameters
    int32 error = 0;
    TaskHandle inputTaskHandle = 0;
    TaskHandle outputTaskHandle = 0;
    char errorString[ 2048 ] = {'\0'};
    int32 i;
    time_t startTime;
    // input channel parameters
    char inputChannelList[] = "Dev1/ai0, Dev1/ai1";
    float64 inputVoltageRangeMinimum = -10.0;
    float64 inputVoltageRangeMaximum = 10.0;
    // output channel parameters
    char outputChannelList[] = "Dev1/ao0, Dev1/ao1";
    char outputTrigger[] = "Dev1/ai/StartTrigger";
    float64 outputVoltageRangeMinimum = -10.0;
    float64 outputVoltageRangeMaximum = 10.0;
    // Timing parameters
    char clockSource[] = "OnboardClock";
    uInt64 samplesPerChannel = 100000;
    float64 sampleRate = 10000.0;
    // Input data parameters
    static const uInt32 inputBufferSize = 100;
    int16 inputData[ inputBufferSize * 2 ];
    int32 pointsToRead = inputBufferSize;
    int32 pointsRead;
    float64 timeout = 10.0;
    int32 totalRead = 0;
    // Output data parameters
    static const uInt32 outputBufferSize = 1000;
    float64 outputData[ outputBufferSize * 2 ];
    int32 pointsToWrite = outputBufferSize;
    int32 pointsWritten;
    for( int i = 0; i < outputBufferSize; i++ )
    outputData[ 2 * i ] = 9.95 * sin( 2.0 * 3.14159 * i / outputBufferSize );
    outputData[ 2 * i + 1 ] = -9.95 * sin( 2.0 * 3.14159 * i / outputBufferSize );
    // ------------------- configure input task -----------------------
    DAQmxErrorCheck ( DAQmxBaseCreateTask( "", &inputTaskHandle ) );
    printf( "Created input task\n" );
    DAQmxErrorCheck ( DAQmxBaseCreateAIVoltageChan( inputTaskHandle, inputChannelList, "", DAQmx_Val_RSE, inputVoltageRangeMinimum, inputVoltageRangeMaximum, DAQmx_Val_Volts, NULL ) );
    printf( "Created AI Voltage Chan\n" );
    DAQmxErrorCheck ( DAQmxBaseCfgSampClkTiming( inputTaskHandle, clockSource, sampleRate, DAQmx_Val_Rising, DAQmx_Val_ContSamps, samplesPerChannel ) );
    printf( "Set sample rate\n" );
    // ------------------- configure output task -----------------------
    DAQmxErrorCheck ( DAQmxBaseCreateTask( "", &outputTaskHandle ) );
    printf( "Created output task\n" );
    DAQmxErrorCheck ( DAQmxBaseCreateAOVoltageChan( outputTaskHandle, outputChannelList, "", outputVoltageRangeMinimum, outputVoltageRangeMaximum, DAQmx_Val_Volts, NULL ) );
    printf( "Created AO Voltage Chan OK\n" );
    DAQmxErrorCheck ( DAQmxBaseCfgSampClkTiming( outputTaskHandle, clockSource, sampleRate, DAQmx_Val_Rising, DAQmx_Val_ContSamps, samplesPerChannel ) );
    printf( "Set sample rate\n" );
    // trigger output when input starts
    DAQmxErrorCheck ( DAQmxBaseCfgDigEdgeStartTrig( outputTaskHandle, outputTrigger, DAQmx_Val_Rising ) );
    printf( "Set output trigger\n" );
    // ------------------- configuration -----------------------
    // write output signal
    DAQmxErrorCheck ( DAQmxBaseWriteAnalogF64( outputTaskHandle, pointsToWrite, 0, timeout, DAQmx_Val_GroupByScanNumber, outputData, &pointsWritten, NULL ) );
    printf( "Write output signal\n" );
    // set up input buffer
    DAQmxErrorCheck ( DAQmxBaseCfgInputBuffer( inputTaskHandle, 200000 ) ); // use a 100,000 sample DMA buffer
    // initiate acquisition - must start output task first
    DAQmxErrorCheck ( DAQmxBaseStartTask( outputTaskHandle ) );
    DAQmxErrorCheck ( DAQmxBaseStartTask( inputTaskHandle ) );
    // The loop will quit after 10 seconds
    Dr John Clements
    Lead Programmer
    AxoGraph Scientific

    Hi Michael,
    First of all, thanks very much for taking the time to investigate this problem! Much appreciated.
    You asked for "an actual error code you got and any description that is given". The full output from the program that I posted earlier in this thread is appended to the end of this message. In summary, following the call to...
    DAQmxErrorCheck ( DAQmxBaseCfgDigEdgeStartTrig( outputTaskHandle, outputTrigger, DAQmx_Val_Rising ) );
    ... with ...
    char outputTrigger[] = "Dev1/ai/StartTrigger";
    ...the error message is ...
    DAQmxBase Error: Specified route cannot be satisfied, because the hardware does not support it.
    You asked "specifically which M series device you are using"? It is the PCIe 6251 (with BNC 2111 connector block). I'm testing and developing on an Intel Mac Pro (dual boot OS X and Windows XP).
    You asked for "the location you pulled the code from". Here it is...
    http://zone.ni.com/devzone/cda/epd/p/id/879
    ...specifically from the file "Multi-Function-Synch AI-AO_Fn.c".
    I adapted the NI-DAQmx calls to their NI-DAQmx Base equivalents.
    Finally, you asked "Is the trigger necessary, or do you just need to know that the measurements are running on the same clock?". I believe that some kind of sychronized trigger is necessary in my situation (correct me if I'm wrong). Timing is crucial. Say I initiate an analog output stream that delivers a voltage command step 5 ms from the onset. I need to record the response (analog input stream) so that its onset is accurately aligned (synchronized) at 5 ms. A typical recording situation would stimulate and record a short data 'sweep', then wait for the (biological) system to recover, then stimulate and record another short sweep, and repeat. I need all the recorded sweeps to align accurately so that they can be averaged and analyzed conveniently.
    I definitely do not want my customers to rely on an expensive external TTL pulse generator to initiate and synchronize each 'sweep'. That would effectively eliminate the cost advantage of an NI board, as well as adding unnecessary complexity in setup and use. It would be a show-stopper for me.
    It seems perverse, but would it be possible to use a digital output channel connected directly to a digital input chanel to trigger the input and output streams?
    Regards,
    John.
    Full output from test program. Compiled with gcc 4 under OS X...
    [Session started at 2007-05-23 14:17:01 +1000.]
    LoadRuntime: MainBundle
    CFBundle 0x303cc0 (executable, loaded)
    _CompatibleWithLabVIEWVersion: linkedAgainst: 08208002
    _CompatibleWithLabVIEWVersion: result= false, mgErr= 1, theActualVersion= 00000000
    _CompatibleWithLabVIEWVersion: linkedAgainst: deadbeef
    _CompatibleWithLabVIEWVersion: Reseting Linked Against
    _CompatibleWithLabVIEWVersion: linkedAgainst: 08208002
    _CompatibleWithLabVIEWVersion: result= true, mgErr= 0, theActualVersion= 00000000
    _CompatibleWithLabVIEWVersion: linkedAgainst: 08208002
    _CompatibleWithLabVIEWVersion: result= true, mgErr= 0, theActualVersion= 00000000
    com.ni.LabVIEW.dll.nidaqmxbaselv
    CFBundle 0x313760 (framework, loaded)
    {type = 15, string = file://localhost/Library/Frameworks/nidaqmxbaselv.framework/, base = (null)}
    Amethyst:Library:Frameworks:nidaqmxbaselv.framework
    2007-05-23 14:17:02.248 test-ni[4445] CFLog (21): Error loading /Library/Frameworks/LabVIEW 8.2 Runtime.framework/resource/nitaglv.framework/nitaglv: error code 4, error number 0 (no suitable image found. Did find:
    /Library/Frameworks/LabVIEW 8.2 Runtime.framework/resource/nitaglv.framework/nitaglv: mach-o, but wrong architecture)
    CFBundle 0x1751fdc0 (framework, not loaded)
    Created input task
    Created AI Voltage Chan
    Set sample rate
    Created output task
    Created AO Voltage Chan OK
    Set sample rate
    DAQmxBase Error: Specified route cannot be satisfied, because the hardware does not support it.
    test-ni has exited with status 0.
    Dr John Clements
    Lead Programmer
    AxoGraph Scientific

  • I w'd like to know if LabVIEW 6.0 Application Builder includes the daqdrv (for data acquisition) and serpdrv (for serial communication) support files by default.

    Building an application to communicate to a device by serial port

    Hi velou
    The LabVIEW 6i Application Builder no longer requires daqdrv. Regardless of your Application Builder and LabVIEW version, you must always install the appropriate driver files on the target machine. For example, if your application communicates with a DAQ board and a GPIB board, then you must install NI-DAQ and NI-488.2 on your target machine. If you are using the VISA VI's for serial communication, than you have to install NI-VISA . If you are using the "old" serial VI's, than you have to include serpdrv separately.
    Luca P.
    Regards,
    Luca

  • My macbook this without sound. I checked the settings, and has no input or output and sound. An icon appears blocking the sound. what to do??

    Please,can someone help me find the input devices and left the sound?

    Try resetting the SMC and pram
    MacBook and MacBook Pro 
    Laptops with a battery you can remove 
    Shut down the computer.
    Disconnect the MagSafe power adapter from the computer, if it's connected.
    Remove the battery.
    Press and hold the power button for 5 seconds.
    Release the power button.
    Reconnect the battery and MagSafe power adapter.
    Press the power button to turn on the computer.
    Newer Mac portables with a battery you don't remove
    Shut down the computer.
    Plug in the MagSafe power adapter to a power source, connecting it to the Mac if its not already connected.
    On the built-in keyboard, press the (left side) Shift-Control-Option keys and the power button at the same time.
    Release all the keys and the power button at the same time.
    Press the power button to turn on the computer.  
    Note: The LED on the MagSafe power adapter may change states or temporarily turn off when you reset the SMC.
    Resetting NVRAM / PRAM
    Shut down your Mac.
    Locate the following keys on the keyboard: Command (⌘), Option, P, and R. You will need to hold these keys down simultaneously in step 4.
    Turn on the computer.
    Press and hold the Command-Option-P-R keys before the gray screen appears.
    Hold the keys down until the computer restarts and you hear the startup sound for the second time.
    Release the keys.

  • PID Control - analog input, digital outputs

    Hello everyone,
    I am trying to use the PID toolkit to convert my existing feedback control system to one using PID or just PI whatever works best. Problem is that the tutorials out there discuss in detail about obtaining Analog inputs and using the PID output to control an analog output. Are there any tutorials that show how I can control my process variable which is an analog input by using the PID output to generate digital outputs?
    Basically, what I am doing is controlling the incline of my device with two digital outputs that control two solenoid valves. The angle is calculated from a calibration curve that plots distance sensor voltage with Angle. Any help would be immensely apprecitated. I want to try this out on my own before I post some vi's. Thanks!
    V
    I may not be perfect, but I'm all I got!

    That is exactly what I am doing currently. I have error bands specified around the target to make sure that it doesn't oscillate. But, under load conditions such as pulsed load conditions, the device goes out of bounds and the values trigger to correct for it. But, what I need is seemless or atleast seemless correction. Currently what I see is sudden adjustments to the incline. Please find attached what I am currently using. I am trying to get a more finer solution if at all possible.
    Note: Within 5% of the target = NO action
              Between 5% and 15% = Pulsed ACtion ( DO On for Pulse width time)
              Greater than 15% = continuous action until it reaches Pulse band
    I may not be perfect, but I'm all I got!
    Attachments:
    TDML_subElevationControl.vi ‏41 KB
    TDML_subPulsedValveFuntion.vi ‏16 KB

Maybe you are looking for

  • Selection screen as subscreen in module pool main screen

    hello i having problem with a module pool  and a selection screen subscreen , i have my main screen 100 in my module pool i create a sub screen area , then in my top include i define a seleccion screen as subscreen  150 i define some paramets and sel

  • MODIFY Table in OO Context

    Hi! I'm trying to modify an internal table which is a public attribute of a class. I'm always getting a sy-subrc 4. Here is my code to describe my problem: MODIFY TABLE go_instance->gt_table FROM <table>. The datatype of <table> is correct. When I as

  • I need Java for my gradebook

    I just bought a MacBook Pro yesterday.  When I tried to open my gradebook it tells me that I need Java.  When I tried to download Java the site won't let me access the download.  Is there a way to activate Java so I can open my gradebook?

  • Exclude input fields from report breaks

    See http://htmldb.oracle.com/pls/otn/f?p=24317:234 The radiogroup is based on the deptno. I specified break on "First and second columns". This results in the radiogroup also being suppressed on the repeated rows! Is there a way to suppress only the

  • IPhone 4 - it begins?!? Not really ...

    It took Verizon 5 years (!) to finally get the iPhone to their customers. When they rolled it out to their long-suffering customers, it was heralded as the greatest innovation ever. It's true, it is one of the best phones there is. But its been aroun