FINALLY INPUTTING and OUTPUTTING Annotations!

Ok, before everyone thinks that this is a very bad solution, I have to tell that I`m no programmer and my knowledge of PostgreSQL, Ruby or any other language is very poor.
With useful help from Jamie Hodge, fbm and Nicholas Stokes (mainly)
I could manage to write a command for inputting and outputting from Final Cut Server Annotations.
So lets go to the fun part:
INPUTTING:
1- Create a Response called "Annotations IN" (or whatever you want):
a - Reponse Action: "Run an external script or command"
b - Run Script > *Commnad Path: /Library/Application Support/Final Cut Server/Final Cut Server.bundle/Contents/Resources/sbin/fcsvr_run
Command Parameters: psql px pxdb -c "COPY pxtcmdvalue FROM '/FCSRV/annotation-in.txt' USING DELIMITERS '|';"
2 - Create a poll Watcher with name: "Watch for Annotations IN"
a - Enable: true
b - Monitor Address: Chooses a Device (create a new one or use a tmp one) and path to where you`ll going to put a txt file with the annotations.
c - Response List: Choose the Response you created "Annotations IN" in my case.
d - Event Type Filter: Created, Modified
e - Poll Watcher > Listing Frequency: 2 (or any number of seconds you feel like it).
Listing multiple: 2
Wildcard include Filter: *.txt (or any custom extensions you want)
3 - Create a txt file and use this as a template:
{ASSET_ENTITYID}|1527|{TCIN}/(30000,1001)|{TCOUT}/(30000,1001)|{Annotation}|{USE RID}|{DATE}
Where:
{ASSET_ENTITYID} = Is the entityid of your asset. You can find what number it is by issuing:
/Library/Application\ Support/Final\ Cut\ Server/Final\ Cut\ Server.bundle/Contents/Resources/sbin/fcsvr_run psql px pxdb -c "SELECT pxmdvalue.entityid, pxmdvalue.value AS asset_name FROM pxmdvalue INNER JOIN pxentity ON pxentity.entityid = pxmdvalue.entityid WHERE pxmdvalue.fieldid='1543' AND pxentity.address LIKE '/asset/%';"
This will output ALL your assets, so if you know the name or want to parse the name you can use:
/Library/Application\ Support/Final\ Cut\ Server/Final\ Cut\ Server.bundle/Contents/Resources/sbin/fcsvr_run psql px pxdb -c "SELECT pxmdvalue.entityid, pxmdvalue.value AS asset_name FROM pxmdvalue INNER JOIN pxentity ON pxentity.entityid = pxmdvalue.entityid WHERE pxmdvalue.fieldid='1543' AND pxmdvalue.value='ASSETNAME' AND pxentity.address LIKE '/asset/%';"
Where in ASSETNAME you`ll have to put your Asset Name without extension.
{TCIN} and {TCOUT} is, of course, the TC`s points. In the form of: HH:MM:SS;FF
{Annotation} is the commentary.
{USERID} (in my case was 1)
{DATE}: This one is tricky. My example is 2009-03-15 19:31:15.839795-03
So is in the form YYYY-MM-DD HH:MM:SS.????? I really don`t know the rest. Could be milliseconds?
Of course one can write a script to translate everything from a txt file like:
ASSETNAME | TCIN | TCOUT | ANNOTATIONS | USER
But as I`ve said I`m no programmer
Ok.. now the time for the OUTPUT:
The command-line is:
/Library/Application\ Support/Final\ Cut\ Server/Final\ Cut\ Server.bundle/Contents/Resources/sbin/fcsvr_run psql px pxdb -c "SELECT pxmdvalue.value AS Asset_NAME, pxtcmdvalue.value, pxtcmdvalue.begintc, pxtcmdvalue.endtc FROM pxmdvalue INNER JOIN pxtcmdvalue ON pxmdvalue.entityid = pxtcmdvalue.entityid WHERE pxmdvalue.value='ASSETNAME';"
Where ASSETNAME is the Asset name without the extension.
Or issuing the following to OUTPUT ANNOTATIONS from ALL assets:
/Library/Application\ Support/Final\ Cut\ Server/Final\ Cut\ Server.bundle/Contents/Resources/sbin/fcsvr_run psql px pxdb -c "select * from pxtcmdvalue;"
Adding "> /PATHTO_WHERE_IN_WANT/ANNOTATIONSOUTPUT.TXT" at the end will put all output into a txt file.
It`s possible (in theory) to:
1- Create a boolean md field in FCSRV called "EXPORT Annotations" (don`t choose lookup)
2- add or create a md group called "Export Annotations" and add the above md field to it (don`t choose lookup)
3- Add "Export Annotations" md field to Asset Filter md group
4- Make a Response for Running external command. Command path: /Library/Application Support/Final Cut Server/Final Cut Server.bundle/Contents/Resources/sbin/fcsvr_run
Command Parameters: psql px pxdb -c 'SELECT pxmdvalue.value AS Asset_NAME, pxtcmdvalue.value, pxtcmdvalue.begintc, pxtcmdvalue.endtc FROM pxmdvalue INNER JOIN pxtcmdvalue ON pxmdvalue.entityid = pxtcmdvalue.entityid WHERE pxmdvalue.value=[FileName];' > ~/Desktop/ann-out.txt
(I`m having problem with this, it doesn`t work).
5- Make a Subscription that if Export Annotations modified = true, trigger if changed and trigger the Response above.
6- Add exporting annotations md group to Media md set.
In theory it`s possible to modify the FinalCutServerIntegrationSample get and input annotations instead of adding another "comment" field to md group list.
Few!
Ok so please help beautify this out!
This will be very useful for a lot of people.... We know that it`s only a matter of time to FCSVR have this function built-in... but this "time" could be years.
So let`s start ourselves!
Thank you very much!!
Regards!

AlphaBlue wrote:
jverd wrote:
What were you hoping for? Someone reading your mind for what exactly you need, and handing you a giftwrapped answer, without you doing any work or clearly communicating a specific problem? This site doesn't really work that way.Fair enough. I'm asking for insight into how to input from and output to a StarOffice Spreadsheet into/from a Java program. (Think java.io except with spreadsheet files instead of .txt files.) I already answered that question.
I need to accomplish this without the use of a community-created library.That's a bizarre requriement. Why?
>
Okay, [here you go|http://lmgtfy.com/?q=communication+between+StarOffice+Spreadsheets+and+Java].
If you don't have any knowledge or experience, on the matter, please refrain from directing me to a google search. I assure you, I have already performed such a task.How would I know that.
But okay, let's say I know that. Let's say you bothered to point out that you've already done that. Further, let's say I do have knowledge of the subject at hand. Maybe I'm an expert. Maybe I wrote Star Office and an open source library (which wheel for some reason you must reinvent). You are assuming that I also have psychic powers, so that I can read your mind and know exactly what you've read so far and exactly what parts of your very broad and vague question said reading did not answer.
In short, you have received answers commensurate with your questions.

Similar Messages

  • Sound Input and Output Disappeared

    I am considering a purchase of a used Macbook Pro (4,1) from early 2008 with Snow Leopard 10.6.8 installed. When I first tried the machine, the sound input and output were absent. After removing preference files, resetting NVRAM, etc., I finally got them to work. They worked for a few weeks, but recently they disappeared again. This time, my efforts to ressurrect them have been fruitless.
    Here is what I have done in an attempt to remedy the situation:
    •Delete com.apple.audio.DeviceSettings.plist and com.apple.audio.SystemSettings.plist
    •Jiggle a digital headphone jack in the headphone port
    •Verifiy Disk and Repair Permissions
    •Reset NVRAM
    •Reset SMC
    I have read online that some people have replaced the AppleHDA.kext file with the one from 10.6.7 - however, every effort I have made to find this file has resulted in failure. I am not able to locate MacOSXupdCombo 10.6.7.pkg anywhere on the web
    Any recommendations? I was able to fix this once before - why not now? Thanks for any and all constructive input...

    Did you recieve the install disk(s) when you purchase the machine? I would try doing a back up of your data then a fresh install of the OS. Insert the disk into the mac then click restart and hold the c key, ten follow the prompts.
    If you wish to take this route, I would try the 10.6.8 combo update first (it should be fine to run it again), then if you wish you may try the 10.6.7 update. Altough I would just do a OS X reinstall and then run software update till you bring it up to date. On disk 2 there should be the AHT (Apple Hardware Test) that you can run by booting the disk holding the D key to check for a hardware fault.
    You may also make a Genius bar appointment for a free evaluation, they have more extensive diagnosis tools and would then tell you what your otions would be. (hey it's free)
    Genius Bar appointment http://support.apple.com/kb/DL1361
    10.6.8 Combo update
    http://support.apple.com/kb/DL1399
    10.6.7 Combo Update:
    http://support.apple.com/kb/DL1361
    All the Best

  • 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

  • Analog Levels vs SPDIF Levels Input and Output in Logic Pro

    Hello,
    I ran a test last night for recording input and output levels from my Yamaha Motif XS8 through an Apogee Ensemble to compare Analog to SPDIF
    I connected two TRS cables from the L and R outputs on the Motif XS into the Analog Inputs on the Apogee and also have the SPDIF connection from the Motif to the Apogee.
    I put the master fader all the way up on the XS for the volume for analog.
    The ensemble in Maestro has a +4 and -10 reference notional level option for analog inputs. i had it at +4 but changed to -10 and the analog got louder (i figured it would get louder for +10, confusing).
    anyways, why is it that I can record louder levels for analog than the digital transfer?
    I tracked both options at the same time then recorded vocals over it. the digital sound is too low. what's up with that?
    and when I tried to bounce the recording to listen to it in ITunes, the volume levels were way lower than my cd playing through iTunes. Please enligthen me on these?
    I use to record in a Roland 2480, and had similar results with loudness, but got a little louder through mastering but still....pro cds are way louder and still clear.

    I think there is much confusion here!
    In summary, you wont be able to control the recording level of S/PDIF.
    The reason is that you don't want to!
    You need to think of the SPDIF connection as being more like a file transfer method. You are copying the digital data at an output to your harddrive in effect. If I send you an MP3 via email you'd never imagine that your email software is capable of changing the gain of the MP3 I send you. This might sound daft but its a useful analogy. If you need to increase the "volume" of that MP3 then you'd need to ask the sender. Its the same with your set-up.
    There could well be somewhere on your synth that adjusts the instruments level, other than the master (analogue) output control. For example, make sure the midi volume of the intrument being played is set to full - ie midi vol 128. Perhaps there is somesort of virtual mixer onboard to control all the muti-timbral parts so make sure your part has its virtual fader turned up.
    This is what (basically) is going on in the chain...
    Your synth creates sound in its "digital brain". This sound is sent to an "output stage" which will distribute the sound to various outputs. In the case of the S/PDIF it will just send the raw digital data untouched. For the analogue side the digital signal (same as the one sent to S/PDIF) will be converted to analogue and then sent to a amplifier to get it to an appropriate "line level". This final level could well be controlled by an anogue volume control which could be adding more gain (than you think) too.
    When things go to your sound card/ daw...
    The purpose of a analogue gain control is to set the i/p signal so that it suitably loud to beat any noise that exists in your input circuits - so that a good signal to noise ratio is achieved. Analogue signals need to work in the right loudness zone (so to speak) as the analogue electronics will be designed to handle signal levels of a particular range. the gain control is there to make sure the signal is in that range.
    Digital signals are far more predictable though and there is no advantage to your recordings if the incoming digital signal gets an increase of level at the input stage. All you are doing here is effectively adding a few zeros to the binary digital data!
    Lets face it the point of recording is to get a copy of the original sound, that is as similar to the original as possible. With S/PDIF you get a perfect copy of what's coming out of your synth - so job's a good un!
    If, when you come to mix in logic, you find the level of the digital recording is indeed too low for mixing/mastering purposes then just boost it in logic via a fader or via the gain plugin.
    Those referrence values of -10dBV and +4dBu refer to analogue voltage levels only. they have nothing to do with the digital domain. The -10/+4 switch will be only relevant to analogue inputs and outputs. Using an analogue VU meter you should find that a sine wave that peaks at 0dBVU (totally different to 0dBFS BTW) is the equivant of a digital sine wave peaking at -18dBFS.
    The analogue headroom (how loud you can go before things distort) depends on the analogue electronics and varies with different design. Analogue stuff, like mixers) often has headroom of 24dB or more. So that digital stuff can interface with analogue properly we allow for that analogue headroom to be around 18dB (usually enough in practise!)... hence -18dBFS(digital)=0dBVU(analogue).
    To make your digital and analogue input signals sound similar in level you will probably have to reduce the gain of the analogue input. If you set the incoming analogue signal to peak around -14dB (or less!) or so you will probably find things more equal. If you are working in 24 bit your analogue levels can be seemingly very low before sound quality is affected. Its quite safe to record at -20 or even -30dB as shown on logic's meters for eg.
    I hope all this waffle helps LOL!

  • I'm trying to record in Adobe Audition and it keeps saying my the sample rates for my input and output devices do not match.  How do I correct this?

    I'm trying to record in Audition and it keeps saying my sample rates for the input and output devices don't match.  How do I fix this?

    I finally have communication between the ISA One and Audition. I moved the optic cable to another SPDIF on the computer and from the SPDIF to ADAT on the ISA One and it finally agreed that the communication was at the same clock speed. The audio was not intelligible so I moved the optic cable back to the original configuration and I can record voice that is clean.          

  • How can I use a different driver for audio input and output?

    I did a search of course, and came up with something about an aggregate. I have no idea what this is, how to do it, or if it would even work for me.
    What I am trying to do is:
    1) Record into Logic Express using my Tascam US-122.
    2) Have playback come out of my computer sound system, not the Tascam.
    If I go over to the Audio setup window, I can only record when the driver is set to Tascam US-122. Likewise, I can only listen to sound when my Built-In Audio is selected. It gets rather annoying going between the two.
    So, would this aggregate thing solve my problem? If so, how do I do it? Thanks for any help!
    -allen

    Yes it should do what you want.
    Go to "Audio Midi Setup", and go to the Audio menu and click "Open Aggregate Device Editor". The interface is pretty simple but if you do get stuck, just use the help function in Audio Midi Setup, as it has a step by step guide.
    Then when you return to logic, go to the Preferences>Audio>Drivers section and select Aggregate Device as the new driver rather than either the built in sound or the tascam. Then the inputs and outputs will apply to BOTH devices.

  • SSIS: How to use one Variable as Input and Output Parameter in an Execute SQL Task

    Hello,
    i need your help,I'm working on this issue since yesterday and have no idea how to deal with it.
    As I already said in the tilte i want to start a stored procedure via a Execute SQL Task which has around 15 prameters. 10 of these should be used as input AND output value.
    As an example:
    i have three  Variable:
    var1    int        2
    var2    int     100
    var3    int     200
    the stroed procedure:
       sp_test
          @var1 int
          @var2 int output
          @var3 int output
       AS
       BEGIN
            SET @var2 = @var2 * @var1
            SET @var3 = @var3 + @var1
       END
    So in the Execute SQL Task i call the Stored Procedure as follwos:
        Exec sp_test  @var1 = ?, @var2 = ? output, @var3 = ? output
    (I use an OLE DB Connection)
    The parameter mapping is as follows:
    User::Var1        input                   numeric              0                 -1
    User::Var2        input/output         numeric              1                 -1
    User::Var3        input/output         numeric              2                 -1
    Now my problem. If i set  Var2 and Var3 as Input parameter the values are still the same after running the package. If i set them to a output value the are both Null because the procedure doesnt get any values.
    I already tried to list them a second time - like
        User::Var2        input                  numeric              1                 -1
        User::Var2        output                 numeric              1                 -1
    or i use a new variable
        User::Var2                  input                  numeric              1                 -1
        User::Var2Return        output                 numeric              1                 -1
    but i alwas get the error
    "Multiple-step OLE DB operation generated errors. Check each OLE DB status value, if available. No work was done."
    Has anybody an idea how I can solve this problem?
    Thanks a lot.
    Kind Regards,
    Alice

    Hi Alain,
    thx for your answer.
    I have around 15 procedures called one after the other to calculated and modify my values. Each procedure is responsible for an other but overlapping set of variables. So i thought it would be a good idea to call them one after the other with the needed variables via a execute sql task.
    So if i use a result set, how i get my stored procedure to return 10 values? I would have to use a Function instead of a procedure, wouldn't i?
    As if i have 15 procedures this would be a lot of work.
    But thanks a lot for the idea. I think an other idea would be to create one function which calls all stored procedures and returns all the calculated values as a result set, wouldn't it?.
    Kind Regards.
    Alice

  • How can I make Apple Earphones be the Input and Output for Audio

    I have some older headphones and they aren't compatible with a Mid 2010 (Intel Core i3) 21.5 Inch iMac
    Is there some way to make Apple Earphones be the Input and Output for Audio in the iMac
    This is a problem for me personally as when I am talking to someone on Skype the iMac picks up the In-built Microphone audio, and yes the headphones I'm using do work straight from the iMac as audio output
    Any help is appreciated

    you can connect the headset to something like this
    http://www.ebay.com/itm/NEW-MaelineA-3-5mm-Female-to-2-Male-Gold-Plated-Headphon e-Mic-Audio-Y-Splitter-/381100440348
    and then connect the mic to the input and the headset to the headset port

  • How to use a bluetooth cellphone for audio input and output

    Hello, I was wondering how to set-up my Mac Book so that I can use my bluetooth cellphone for audio in and audio out. Ideally, I would like to use my handset for talking on iChat and Skype. Has anyone had any luck doing this? When I bond my cellphone these optiosn do not appear. I know that this is easy to do on a Windows machine but I am not sure about how to do it on my Mac Book.
    Thanks!

    Yes it should do what you want.
    Go to "Audio Midi Setup", and go to the Audio menu and click "Open Aggregate Device Editor". The interface is pretty simple but if you do get stuck, just use the help function in Audio Midi Setup, as it has a step by step guide.
    Then when you return to logic, go to the Preferences>Audio>Drivers section and select Aggregate Device as the new driver rather than either the built in sound or the tascam. Then the inputs and outputs will apply to BOTH devices.

  • How do I create an xControl with multiple inputs and outputs?

    Hello,
    i am trying to write a new Xcontrol Element. In the data model I can create data types using the cluster to create compound types, eg an int and an int array. But how do I create an xcontrol which has multiple data inputs and outputs?
    Kind Regards

    Limping_Twerp wrote:
    Alright: I see: An xcontrol is either an input OR an output. How do I achieve an output? Secondly: So you are saying the only Elements that can have multiple inputs and outputs are VIs?
    Can you take a few steps back and explain what you are actually trying to do. SubVIs and Xcontrols have nothing in common and it is not clear why you even try to compare them side by side (e.g. in terms of the number of connectors).
    Your questions about input or output tell us that you seems to have some misconceptions about xcontrols. Xcontrols are like regular controls, except they have some built-in intelligence that you can program. Most front panel object can be either controls or indicators and the same is true for Xcontrol. You create an Xcontrol, and after placing it on the front panel you can decide if it should be a control (where the code reads the value) or an indicator (were the code writes values to it). When you define the xcontrol facade, you also need to program how the visuals change if it is changed from control to indicator or vice versa.
    As a first step, you should opend the example finder and look at some xcontrol examples.
    Again, what are you actually trying to do? 
    LabVIEW Champion . Do more with less code and in less time .

  • XSLT Generation from input and output XML

    Is it possible to generate an XSL mapping file in Java if we have input and output XML.
    If yes, then how to achieve this when user defined functions are used during mapping?

    Hi Prateek,
    check the following links for Business connectors and adapter:
    http://help.sap.com/saphelp_nw2004s/helpdata/en/92/3bc0401b778031e10000000a1550b0/frameset.htm
    http://help.sap.com/saphelp_nw2004s/helpdata/en/2c/4fb240ac052817e10000000a1550b0/frameset.htm
    http://help.sap.com/saphelp_nw2004s/helpdata/en/6a/3f93404f673028e10000000a1550b0/frameset.htm
    Hope these help you.
    Regards,
    Anuradha.B

  • How to temporally match/save Input and Output Channels's data?

    Hello, I have a voltage-input, voltage-output SISO system, and need to indentify its dynamic response (or transfer function) as a reference to a PID control. Without using the system identification toolbox, my goal is to generate/provide a sine sweep input (ranging 1Hz-5kHz for 10sec) to the system and to save the corresponding output response signal as well as the sweep input signal simultaneously.
    I got a sample program online and am trying to modify it as attached, but I really need your advices/comments concerning several problems I am facing with:
    1) With the below setting, the number of the acquired Input channel samples obtained is 5461, which is smaller than expected (i.e., 10000). What would I be missing in setting parameters?
    - H/W: NI-USB-6341 DAQ
    - AO: continuous samples with the waveform timing (1k sampling, 10000 samples => 10 sec, slower sampling just for testing purpose)
    - AI: continuous samples, samples to read: 30k, rate: 1k
    2) I am using flat sequence structure as a way to making the start point of saving AI and AO data same, but wonders if this is a right method or if there is other better approaches. (I had an idea of using an internal clock with "1-sample mode" for sync, but this may not work at the high speed sine sweep like 5kHz, right?)
    3) I just want to provide the sine sweep just once to the system and do not require the "reset" functionality implemented in the original sample program. I failed to remove this "reset" part as I did not fully understand the sample code. If I run the attahed, the generated AO signal is periodically provided to the system. Please give me any advice to modify the program as I want.
    Thanks for your help and valualble time.
    Attachments:
    siso.vi ‏230 KB

    Hi J. Kim,
    To begin, you say you want to synchronize your analog input and output so that they start at the exact same time, yes? To achieve tight synchronization, you need to use DAQmx VIs instead of the DAQ Assistant. There's a good overview of DAQmx VIs  here. There's also a document that deals specifically with synchronization in DAQmx here. Additionally, if you go to Help>>Find Examples in the LabVIEW example finder, you can see many other examples of acquiring data using DAQmx.
    As for your configuration, you have your analog input DAQ assistant wired far before your analog output DAQ assistant in your sequence strucutre, so the dataflow of the program will cause the analog input DAQ Assistant to execute before the output. They cannot be in different sequences if they are executing simoultaneously, and I would not use flat sequences here except to start the two tasks in DAQmx. Where did you find this example?
    Best,
    Dan N
    Applications Engineer
    National Instruments 

  • I have on;y one audio port can i use it for input and output at the same time?

    i have the new macbook pro 13 in and i want to connect aguitar as input and output on an amp but i have only one audio port

    You can't use the jack as an input and output simultaneously. The solution is to look for a USB or Firewire interface to get your guitar sound into the computer.

  • Table name input. and output i need  all rows and columns  using procedures

    hi,
    question: table name input. and output i need all rows and columns by using procedures.
    thanks,
    To All

    An example of using DBMS_SQL package to execute dynamic SQL (in this case to generate CSV data in a file)...
    As sys user:
    CREATE OR REPLACE DIRECTORY TEST_DIR AS '\tmp\myfiles'
    GRANT READ, WRITE ON DIRECTORY TEST_DIR TO myuser
    /As myuser:
    CREATE OR REPLACE PROCEDURE run_query(p_sql IN VARCHAR2
                                         ,p_dir IN VARCHAR2
                                         ,p_header_file IN VARCHAR2
                                         ,p_data_file IN VARCHAR2 := NULL) IS
      v_finaltxt  VARCHAR2(4000);
      v_v_val     VARCHAR2(4000);
      v_n_val     NUMBER;
      v_d_val     DATE;
      v_ret       NUMBER;
      c           NUMBER;
      d           NUMBER;
      col_cnt     INTEGER;
      f           BOOLEAN;
      rec_tab     DBMS_SQL.DESC_TAB;
      col_num     NUMBER;
      v_fh        UTL_FILE.FILE_TYPE;
      v_samefile  BOOLEAN := (NVL(p_data_file,p_header_file) = p_header_file);
    BEGIN
      c := DBMS_SQL.OPEN_CURSOR;
      DBMS_SQL.PARSE(c, p_sql, DBMS_SQL.NATIVE);
      d := DBMS_SQL.EXECUTE(c);
      DBMS_SQL.DESCRIBE_COLUMNS(c, col_cnt, rec_tab);
      FOR j in 1..col_cnt
      LOOP
        CASE rec_tab(j).col_type
          WHEN 1 THEN DBMS_SQL.DEFINE_COLUMN(c,j,v_v_val,2000);
          WHEN 2 THEN DBMS_SQL.DEFINE_COLUMN(c,j,v_n_val);
          WHEN 12 THEN DBMS_SQL.DEFINE_COLUMN(c,j,v_d_val);
        ELSE
          DBMS_SQL.DEFINE_COLUMN(c,j,v_v_val,2000);
        END CASE;
      END LOOP;
      -- This part outputs the HEADER
      v_fh := UTL_FILE.FOPEN(upper(p_dir),p_header_file,'w',32767);
      FOR j in 1..col_cnt
      LOOP
        v_finaltxt := ltrim(v_finaltxt||','||lower(rec_tab(j).col_name),',');
      END LOOP;
      --  DBMS_OUTPUT.PUT_LINE(v_finaltxt);
      UTL_FILE.PUT_LINE(v_fh, v_finaltxt);
      IF NOT v_samefile THEN
        UTL_FILE.FCLOSE(v_fh);
      END IF;
      -- This part outputs the DATA
      IF NOT v_samefile THEN
        v_fh := UTL_FILE.FOPEN(upper(p_dir),p_data_file,'w',32767);
      END IF;
      LOOP
        v_ret := DBMS_SQL.FETCH_ROWS(c);
        EXIT WHEN v_ret = 0;
        v_finaltxt := NULL;
        FOR j in 1..col_cnt
        LOOP
          CASE rec_tab(j).col_type
            WHEN 1 THEN DBMS_SQL.COLUMN_VALUE(c,j,v_v_val);
                        v_finaltxt := ltrim(v_finaltxt||',"'||v_v_val||'"',',');
            WHEN 2 THEN DBMS_SQL.COLUMN_VALUE(c,j,v_n_val);
                        v_finaltxt := ltrim(v_finaltxt||','||v_n_val,',');
            WHEN 12 THEN DBMS_SQL.COLUMN_VALUE(c,j,v_d_val);
                        v_finaltxt := ltrim(v_finaltxt||','||to_char(v_d_val,'DD/MM/YYYY HH24:MI:SS'),',');
          ELSE
            v_finaltxt := ltrim(v_finaltxt||',"'||v_v_val||'"',',');
          END CASE;
        END LOOP;
      --  DBMS_OUTPUT.PUT_LINE(v_finaltxt);
        UTL_FILE.PUT_LINE(v_fh, v_finaltxt);
      END LOOP;
      UTL_FILE.FCLOSE(v_fh);
      DBMS_SQL.CLOSE_CURSOR(c);
    END;This allows for the header row and the data to be written to seperate files if required.
    e.g.
    SQL> exec run_query('select * from emp','TEST_DIR','output.txt');
    PL/SQL procedure successfully completed.Output.txt file contains:
    empno,ename,job,mgr,hiredate,sal,comm,deptno
    7369,"SMITH","CLERK",7902,17/12/1980 00:00:00,800,,20
    7499,"ALLEN","SALESMAN",7698,20/02/1981 00:00:00,1600,300,30
    7521,"WARD","SALESMAN",7698,22/02/1981 00:00:00,1250,500,30
    7566,"JONES","MANAGER",7839,02/04/1981 00:00:00,2975,,20
    7654,"MARTIN","SALESMAN",7698,28/09/1981 00:00:00,1250,1400,30
    7698,"BLAKE","MANAGER",7839,01/05/1981 00:00:00,2850,,30
    7782,"CLARK","MANAGER",7839,09/06/1981 00:00:00,2450,,10
    7788,"SCOTT","ANALYST",7566,19/04/1987 00:00:00,3000,,20
    7839,"KING","PRESIDENT",,17/11/1981 00:00:00,5000,,10
    7844,"TURNER","SALESMAN",7698,08/09/1981 00:00:00,1500,0,30
    7876,"ADAMS","CLERK",7788,23/05/1987 00:00:00,1100,,20
    7900,"JAMES","CLERK",7698,03/12/1981 00:00:00,950,,30
    7902,"FORD","ANALYST",7566,03/12/1981 00:00:00,3000,,20
    7934,"MILLER","CLERK",7782,23/01/1982 00:00:00,1300,,10The procedure allows for the header and data to go to seperate files if required. Just specifying the "header" filename will put the header and data in the one file.
    Adapt to output different datatypes and styles are required.

  • Multiple inputs and outputs using DAQmx VIs

    Hello,
    I am fairly new with the LabView programming language.  I have a few training books that I have been reading, and I have been following online tutorials and reading the forums.  However, I have come to a problem where I don’t see a clear solution.  I am using LabView 2009 (9.0f3) and DAQmx VIs.
    I am using a NI 9172 chassis PLC, with two 9201 AI cards, 9217 AI RTD card, 9472 DO card, 9263 AO card, and two 9237 AI Bridge cards.
    I am reading eight analog inputs with the 9201 cards, two analog RTD inputs with the 9217 card, three digital outputs with the 9472 card, three analog outputs with the 9263, and eight analog inputs with the 9237 cards.
    I wrote a simple program to test one digital output task, two of the analog output tasks, and a single analog input task.  I put all of them in the same while loop, and it worked perfectly.  However, when I add analog input tasks to the same loop, I get an error 200022.    So I tested each sensor individually by changing the channel before each run.  I searched error 200022 and found that this is because I cannot start another analog input task until the previous one ends.  With this said, I don’t know how to acquire an analog voltage in the same task as an analog RTD voltage.  Both inputs take different constants in the start task DAQmx icon.
    Attached is my test program.  It is titled “Test All”. This is the program I used to test the various sensors.  I tested the input sensors one at a time, and it worked fine.  A few tasks are written just to test functionality, and will be added to later.  The data is only displayed on the screen.  I will add triggers and data write to disk functions later.  This program works now, but if I add more analog inputs, it will generate the 200022 error.
    Can someone show me how to correctly write the code for multiple inputs and outputs using DAQmx?  All training materials and tutorials I can find all show a single input or single output, not multiples of each.  Thanks for looking.
    -Randy
    Attachments:
    TestAll-NI.vi ‏32 KB

    Hi RandyC,
    The Knowledge Base article Using Different Types of DAQmx Global Channels in the Same Task goes into a little more depth of what Bryan is talking about, and it also includes some example code to help show what to do.
    Hope that helps,

Maybe you are looking for