Question about DAQ PFI lines

Hi , I would like to use 6363 OEM PFI lines to countiously count the number of rising edges of a digital signal. My signal is connected to PFI2 line . I would also like to output a pulse to provide external clock for this signal
Here are the input output pins configuration. Could you please let me know which lines can I use for counter in and which lines for outputing a pulse. Can I also use PFI 2 for counter inpout?
thanks 
CTR 0 SRC PFI 8
CTR 0 GATE PFI 9
CTR 0 AUX PFI 10
CTR 0 OUT PFI 12
CTR 0 A PFI 8
CTR 0 Z PFI 9
CTR 0 B PFI 10
CTR 1 SRC PFI 3
CTR 1 GATE PFI 4
CTR 1 AUX PFI 11
CTR 1 OUT PFI 13
CTR 1 A PFI 3
CTR 1 Z PFI 4
CTR 1 B PFI 11
CTR 2 SRC PFI 0
CTR 2 GATE PFI 1
CTR 2 AUX PFI 2
CTR 2 OUT PFI 14
CTR 2 A PFI 0
CTR 2 Z PFI 1
CTR 2 B PFI 2
CTR 3 SRC PFI 5
CTR 3 GATE PFI 6
CTR 3 AUX PFI 7
CTR 3 OUT PFI 15
CTR 3 A PFI 5
CTR 3 Z PFI 6
CTR 3 B PFI 7
FREQ OUT PFI 14

Hi,
the following information should answer your question:
X Series devices have up to 16 PFI lines.  Each PFI can be individually configured as the following:
Static Digital Input
Static Digital Output
Timing Input Signal for AI, AO, DI, DO, or counter/timer functions
Timing Output Signal from AI, AO, DI, DO, or counter/timer functions
Each PFI can be individually configured as a static digital input or a static digital output. When a terminal is used as a static digital input or output, it is called P1.x or P2.x. On the I/O connector, each terminal is labeled PFI x/P1.x or PFI x/P2.x. The voltage input and output levels and the current drive levels of the PFI signals are listed in the specifications of your device.
Also, PFI can be configured to detect digital changes. The values on the PFI lines cannot be read in a hardware-timed task, but they can be used to fire the change detection event. For example, if you wanted to do change detection on eight timed DIO lines but wanted to ensure that the value of
the lines was updated every second independent of the eight lines changing you could set a PFI line up for change detection and connect a 1 Hz signal to it.
You can enable a programmable debouncing filter on each PFI, RTSI, PXI_STAR, or PXIe-DSTAR<A, B> signal. When the filters are enabled, your device samples the input on each rising edge of a filter clock. X Series devices use an onboard oscillator to generate the filter clock.
Regards,
Michael

Similar Messages

  • A simple question about DAQ data sampling

    Hi all:
    Now I meet a very basic question about DAQ sampling.  I am using NI PCI-6040E DAQ card, SCXI-1001 chasis, SCXI-1102, SCXI1300 terminal block, and SCXI1160 relay module.
    I am not sure , is it possible if I want to test a voltage (1 volt) on a resistor. Now I am connecting the Ch0+ to resistor+ (24 volt), and connecting Ch0- to resistor-(23 volt). So the voltage between resistor+ and resistor- should be 1volt.  Actually, It is working at the first, but after I want to test 9 channels based on this connection. The Measurement & Automation can't read data from the DAQ card. (when I test it by multimeter, I can get the voltage data on the Ch0+ and Ch0- of SCXI1300 terminal block).
    That's strange, does anybody know what' s wrong about it?/
    Thanks a lot

    Hi hanwei,
    According to the specifications of the PCI 6040E (page 3), the input signal and common mode voltage should never exceed 11V from ground.  I believe this is the reason you are able to measure the potential of a battery but not the 24V signal (even though the differential value is only 1V). 
    Best Regards
    Hani R.
    Applications Engineer
    National Instruments

  • Question about DAQ 6363 OEM

    Hi,
    I would like to know which port and lines are asssigned to PFI lines of the 6363 OEM
    I have downloaded the 6363 OEM manual but in the manual and pinout but I can't find the port and line number
    For example what is PFI1 port and line number? Is it P1.0. I can't find it in MAX either.
    Solved!
    Go to Solution.

    PFI0:7 are Port 1.0:7
    PFI8:15 are Port 2.0:7
    Jeff

  • Question about adding a line/phone to a new plan

    Hey everyone I have a concern I wanted to be clear about before I upgrade my plan. I am up for a device upgrade and plan on upgrading my smartphone and my current single line plan to one of of the new share everything family plans and a new smartphone. I can get the phone I want at a different store other then verizon for a better price so Im going to do that. After that is all said and done I plan on buying and adding another new smartphone/line to my share everything account through verizon(store or online). I just want to be sure that 1.) Adding another line after the fact isnt going to be a problem fee wise or the terms of my account wise since I just upgraded my account at a different vendor and 2.) Will that new line be still eligible for a upgrade discount through verizon just like a new plan would be even though Im not adding it at the same exact time I upgrade my main phone and plan?
    Also I was wondering that if..say a few months from now I want to add another new phone/line to my share everything account. Will that also be like a new plan and eligible for a upgrade discount through verizon? My 2.) question will probably answer this but I want to be absolutely sure first before I do anything. Thanks alot guys. Appreciate any input.

    scottm79 wrote:
    Hey everyone I have a concern I wanted to be clear about before I upgrade my plan. I am up for a device upgrade and plan on upgrading my smartphone and my current single line plan to one of of the new share everything family plans and a new smartphone. I can get the phone I want at a different store other then verizon for a better price so Im going to do that. After that is all said and done I plan on buying and adding another new smartphone/line to my share everything account through verizon(store or online). I just want to be sure that 1.) Adding another line after the fact isnt going to be a problem fee wise or the terms of my account wise since I just upgraded my account at a different vendor and 2.) Will that new line be still eligible for a upgrade discount through verizon just like a new plan would be even though Im not adding it at the same exact time I upgrade my main phone and plan?
    Also I was wondering that if..say a few months from now I want to add another new phone/line to my share everything account. Will that also be like a new plan and eligible for a upgrade discount through verizon? My 2.) question will probably answer this but I want to be absolutely sure first before I do anything. Thanks alot guys. Appreciate any input.
      Every time you add a line, it is eligible for a subsidized phone. It does not matter when you do it. As far as question #1, your account is just what the terms of usage is, not the length of the contract(s). Those are determined by the individual lines. You can also change the account limits at any time (eg. increase shared data limit), but when you do, it is usually pro-rated for the remainder of your current billing month, plus 1 month in advance. It does not change any of the lengths of the lines contracts.
      Does this help?

  • Just curious question about Text/Vector Lines

    I was just curious.... I saw this image , and I'm a beginer to Illustrator. Does anyone know How to get the "lined shadow"
    behind the font and is it possible to get a circle stroke like the one here, but where the first circle starts small and the last one
    ends in a bigger size?  Thanks!

    Try this:
    http://design.tutsplus.com/tutorials/how-to-create-a-line-art-based-symmetrical-portrait-i n-adobe-illustrator--vector-65…
    Look out for artworks by crisvector
    or for the keyword guillochee or engraving
    like this:
    How to Create a Mountain in the Engraving Style Using the WidthScribe plugin and Adobe Illustrator - Astute Graphics

  • How to output sample and convert clocks to PFI lines of E-Series DAQ (DAQPad-60​15)

    Hi,
    Can someone tell me how to output sample and convert clocks to PFI lines of E-Series DAQ (DAQPad-6015)?
    Thank you very much.
    Jack

    John --
    Windows is not an option for me. I like your idea of using a counter output -- it may be helpful as I am getting ramped up, but my application will eventually require both timer outputs.
    I have a legacy C application written for Macintosh, and I am in the process of moving it onto OS X. So my options are to use DAQmx Base, or write an in-kernel driver. I actually have already done the latter for 6024/6025 E-series boards (for another company); for this client I was hoping to use the DAQmx Base to allow an easy transition to M-series boards, without the cost of writing and supporting a low-level driver.
    The specific task I am doing is relatively straightforward. I record 2 channels of AI for a short period (usually about 250 ms.) and during this time I drive 2 external digital signals. Right now, I use the 2 timer outputs, which allows precise synchronization with the output and AI sampling.
    I appreciate your comments, and thanks in advance for any additional suggestions you can lob my way.
    --spg
    Scott Gillespie
    Applied Brain, Inc.
    scott gillespie
    applied brain, inc.

  • About DAQ task and writing to a line

    Hi all,
      I swtich from Labview to Labwindows and switch from traditional DAQ to DAQmx. I have two questions about using the DAQmx. Based on the example from NI, I write a function for a single sample output to a single digitial line
    void WriteLine(int zero_or_one, char line_name[])
    int error=0;
    TaskHandle taskID=0;
    char errBuff[256];
    DAQmxErrChk(DAQmxCreateTask("", &taskID));
    DAQmxErrChk(DAQmxCreateDOChan(taskID, line_name, "", DAQmx_Val_ChanPerLine ));
    DAQmxErrChk(DAQmxStartTask(taskID));
    DAQmxErrChk(DAQmxWriteDigitalLines(taskID, 1, 1, 10.0, DAQmx_Val_GroupByChannel, &zero_or_one, NULL, NULL));
    Error:
    if (DAQmxFailed(error)) DAQmxGetExtendedErrorInfo(errBuff, 2048);
    if (taskID!=0)
    DAQmxStopTask(taskID);
    DAQmxClearTask(taskID);
     I am calling this function to a single digital channel. For example, WriteLine(0, "Dev1/port0/line0");. I wonder if above code really writing to a single line or a port (8 lines). I have 4 cables connecting 4 digital lines of one port to 4 external device (so to control the on/off of the device). I use the above code to control one line but don't know why seems sometimes there are something output to other three lines.
    The second question is: now every time I write to a line, I call above code, so it will create the task each time even I just write one bit to one line. In my code, write to the lines pretty often, so how much it cost to create task every time before I write to a channel? Should I create one task for each channel upon the initialization of the program and clear them when the code closed? I just wonder how labview do that? In labview, will it create the task on each writing?

    RobertoBozzolo wrote:
    Creating and destroying a task is a relatively time consuming activity, so if you need to write to the digital lines very frequently it is advisable that you create the task at program start and destroy it at the end, leaving only the start/stop inside the write function.
    As of my knowledge, LabVIEW can be structured in a similar way if you use low level functions, while it creates and destroys the task if you use a DAQ assistant (there is a note on this in the help).
    With reference to your last question, you could have a single task for analog generation and simply set the appropriate rate with calling DAQmxCfgSampClkTiming before starting the task.
    Thanks RobertoBozzolo. I am still in confusion regarding the analog output in DAQmx. I have an array of samples (totally 512 samples), I need to send to a specifc analog channel (A0) such that each sample will be sent at the interval 1millisecond. From your link, I use DAQmxCfgSampClkTiming
    int error=0;
    TaskHandle taskid;
    double samples[512];
    // initialize samples here
    DAQmxCreateTask("mytask", &taskid);
    DAQmxCreateAOVoltageChan(taskid, "Dev2/ao0","",-10,10,DAQmx_Val_Volts,NULL);
    DAQmxCfgSampClkTiming(taskid, NULL, 1000, DAQmx_Val_Rising, DAQmx_Val_FiniteSamps, 512); // sample rate is 1000, so 1sample/ms, 512 samples in total
    DAQmxWriteAnalogF64(taskid, 512,0, 10, DAQmx_Val_GroupByChannel, samples, NULL, NULL);
    // I don't start the task automatically
    // some other time-consuming code here
    // after other code running, I start it manually
    DAQmxStartTask(taskid);
    DAQmxWaitUntilTaskDone(taskid, 10.0);
    DAQmxStopTask(taskid);
     I wonder if this code looks right? There are 512 samples to send, so I set the numSampsPerChan in DAQmxWriteAnalogF64 to 512, is that correct? 
    The same channel will be used for other output also. So after the above task done, if I want to send one sample instead of 512 to the same channel, does the following code work?
    double one_sample_value = 0.2;
    DAQmxStartTask(taskid);
    DAQmxWriteAnalogScalarF64(taskid, 1, 10.0, one_sample_value,NULL);
    DAQmxStopTask(taskid);
     What I am asking is do I have to reset the timing since it was set for outputing multiple sample at some rate before but now I only have to send one sample immediately, so does the time or update rate matter?
    I am porting a big system which written in Labview 8 to CVI but there are so many code needed to be changed, I don't even know how to tell if the DAQ do the same thing or not. So I separate it as above code for testing.

  • Single line plan, how to switch and question about what rep told me.

    I just got a contract (9/3) and have the "more everything plan" - I called Verizon Cust. Care (9/4) to inquire about the single line plan, I was told by Matthew that the single line plan price is in addition to the 40.00 line surcharge, so it would be $100.00 per month. Is this information accurate, or is it only $60.00 per month (as the website states for the ) plus taxes and fees?

    The single line plan is only $60/month. There is no $40 line surcharge. You must be on the Singe Line Plan, though, not the More Everything Plan.

  • Question about reading a string or integer at the command line.

    Now I know java doesn't have something like scanf/readln buillt into it, but I was wondering what's the easiest, and what's the most robust way to add this functionality? (This may require two separate answers, sorry).
    The reason I ask is because I've been learning java via self study for the SCJA, and last night was the first time I ever attempted to do this and it was just hellish. I was trying to make a simple guessing game at the command line, I didn't realize there wasn't a command read keyboard input.
    After fighting with the code for an hour trying to figure it out, I finally got it to read the line via a buffered reader and InputStreamReader(System.in), and ran a try block that threw an exception. Then I just used parseInt to get the integer value for the guess.
    Another question: To take command line input, do you have to throw an exception? And is there an easier way to make this work? It seems awfully complicated to take user input without a jframe and calling swing.
    Edited by: JGannon on Nov 1, 2007 2:09 PM

    1. Does scanner still work in JDK1.6?Try it and see. (Hint: the 1.6 documentation for the class says "Since: 1.5")
    If you get behaviour that doesn't fit with what you expect it to do, post your code and a description of our expectations.
    2. Are scanner and console essentially the same thing?No.
    Scanner is a class that provides methods to break up its input into pieces and return them as strings and primitive values. The input can be a variety of things: File InputStream, String etc (see the Scanner constructor documentation). The emphasis is on the scanning methods, not the input source.
    Console, on the other hand, is for working with ... the console. What the "console" is (and whether it is anything) depends on the JVM. It doesn't provide a lot of functionality (although the "masked" password input can't be obtained easily any other way). In terms of your task it will provide a reader associated with the console from which you can create a BufferedReader and proceed as you are at the moment. The emphasis with this class is the particular input source (and output destination), not the scanning.
    http://java.sun.com/javase/6/docs/api/java/util/Scanner.html
    http://java.sun.com/javase/6/docs/api/java/io/Console.html

  • Some Questions about NI-6602

    Hello!!
    I have some question about NI-6602.
    1.What is the difference between Port and Line ?
    What's the difference of Line nad Portin these functionIG_In_Line,DIG_Out_Prt,DIG_Line_Config,DIG_In_Prt,DIG_Out_Prt,DIG_Prt_Config
    2.If I would like to apply gate to my counter application, is it possible that we give the gate signal via software?
    Or I need to connect signal from hardware? If hardware is needed, is it possible to apply another counter's output as my counter's gate input?
    3.Can we apply gate to this fuction ND_PULSE_TRAIN_GNR?
    4.Can we detect the counter's source is High or Low ?Is there any fuction to read out the source status?

    Hello,
    Thank you for contacting National Instruments.
    "1.What is the difference between Port and Line?"
    A Port is a collection of lines. Usually 8 lines to a port.
    "What's the difference of Line nad Portin these function DIG_In_Line, DIG_Out_Prt, DIG_Line_Config, DIG_In_Prt, DIG_Out_Prt, DIG_Prt_Config"
    These functions either perform an output or input, or configure your digital ports and lines. Please see the Traditional NI-DAQ Function Reference Help found under Start >> All Programs >> National Instruments >> NI-DAQ >> Traditional NI-DAQ Function Reference Help for more information on these functions.
    "2.If I would like to apply gate to my counter application, is it possible that we give the gate signal via software? Or I need to connect signal from hardware? If hardware is needed, is it possible to apply another counter's output as my counter's gate input?"
    You can apply a gate signal from software. For example you can use the 6602's Timebase to gate your counter during pulse measurement applications. You can also route a counter's output to the gate of another counter internally. Look up Select_Signal in the Function Reference Help for more details.
    "3.Can we apply gate to this function ND_PULSE_TRAIN_GNR?"
    I am not sure what you are asking here. ND_PULSE_TRAIN_GNR is a parameter used in the GPCTR_Set_Application function to set up a counter for pulse generation. Please see the page titled "application = ND_PULSE_TRAIN_GNR: GPCTR_Set_Application" in the Function Reference Help more more information about this parameter.
    "4.Can we detect the counter's source is High or Low ?Is there any fuction to read out the source status?"
    There is no function to read the state of the source pin. You will need to route the source pin to a PFI line and perform a digital read on that line.
    I hope this answers your questions. Please feel free to reply if you have any further questions.

  • How Do I Configure the PFI Lines as input in PXI 6713 module

    Hi,
    I have PXI 6713 module in my PXI 1044 chassis. I have configured PXI 6713 module to geneate certain analogue signals to my board.
    Board inturn process this analogue signal and responds back the status signals through a status register on the board. In my application,the status bits in status register of  the board are mapped to the PFI 0:3 bits on PXI 6713 module ( pins 11,10 , 42 and 43).
    My query is how do i configue the PFI lines as input in PXI 6713 module to read these status bits ??
    May be below explanation could give you little bit more information w.r.to my query.
    When i use NI USB - 6008    module to read the same bits , since this device has 12 digital I/O lines, i could able to read the status bits in to the last 4 digital lines by configuring the those digital lines as input.
    In PXI 6713  module i have only 8 digital lines. These 8 digital lines i have used to send the digital signals to the board. I am left with no digital I/O lines. Hence i couldn't use these digital lines. I am left with only one option to use. Theya re PFI lines. Moreover the status bits in the pin out of board are mapped such that the bits can be read through the PFI lines.
    I am wondering do we have any example code to use  inorder to read these status bits on the board using the PFI lines.
    Please let me know if you need additional information to help me out.
    Thanks.
    Solved!
    Go to Solution.

    Hello There,
    When using the PFI pin as an input, you can individually configure each PFI for edge or level detection and for polarity selection.  This PFI information can be referenced in the DAQ Analog Output Series Manual on page 6-1 (http://www.ni.com/pdf/manuals/370735e.pdf).  Unfortunately, the PXI-6713 PFI lines are only capable of timing input and output signal for AI, AO, or counter/timer functions.  The option of creating static DI from the PFI lines is not available for the PXI-6713. However, some cards have this capability.  Newer National Instruments products with PFI lines have the option of setting PFI lines as:
    Static Digital Input 
    Static Digital Output
    Timing Input Signal for AI, AO, DI, DO, or counter/timer functions 
    Timing Output Signal from AI, AO, DI, DO, or counter/timer functions
    (http://digital.ni.com/public.nsf/allkb/14F20D79C649F8CD86256FBE005C2BC4)
    When set as static DIO, the PFI lines are assigned to a different port (eg. PFI0-7 is Port1).  More details about this can be referenced at:
    http://digital.ni.com/public.nsf/allkb/DA2D3CD0B8E8EE2A8625752F007596E1
    http://digital.ni.com/public.nsf/allkb/862567530005F09E8625677800577C27
    Regards,
    Roman Sandoval | National Instruments | RF Systems Engineer

  • Driving DO lines with external clock wired to PFI lines

    Hi all,
    I have few issues understanding how to use hardware timing resources in M series USB6229, with particular focus on DO. I have read last couple of day all google offered on the subject but I am still straggling with some basic tasks. To cut the story short, the 1e6 dollar question:  can I set up 7 independent DO lines where (different tasks or virtual channels) where lines use same hardware timing source (eg, freqout or CO0 set to ~10kHz sampling time routed to PFI0).
    Note: the reason I need 7 independent lines and not a port output (which would be obvious solution) is because I need to have (vastly) different number of samples and for each line.
    Follow up question regarding timing: As I understood, any of PFI ports could be used and a input to the external clock which could be used to drive DO line(s) samples. I have tried to generate one DO, eg. P0\line4 by using CO0 to generate 10kHz sample rate.  The signal on the line4 is pulse with frequency of few Hz which I routed to PF6 (with actual wire) in hope to use this signal as a clock for line5. I tried this but I am receiving errors about "resources in use"
    Possible reason(s):
    Specified route cannot be satisfied, because it requires resources that are currently in use by another route.
    Property: SampClk.Src
    Property: SampClk.ActiveEdge
    Source Device: USB-6229
    Source Terminal: PFI6
    Required Resources in Use by
    Task Name: _unnamedTask<7B>
    Source Device: USB-6229
    Source Terminal: PFI4
    Destination Device: USB-6229
    Destination Terminal: do/SampleClock
    Task Name: _unnamedTask<79>
     Apparently, many of internal clocks are routed internally to different PFI lines which mean the lines are occupied resource, and I do not know how to solve this.
    I wanted to ask you does this principle sound as something that should work and if you know about some examples that would be excellent.   
    Any help would be greatly appreciated.
    Cheers, Nenad

    > To cut the story short, the 1e6 dollar question:  can I set up 7 independent DO lines where (different tasks or virtual channels) where lines use same hardware timing source (eg, freqout or CO0 set to ~10kHz sampling time routed to PFI0).
    No, you can't. The USB-6229 has a single digital output FIFO which can only be used by one task at a time.
    > Note: the reason I need 7 independent lines and not a port output (which would be obvious solution) is because I need to have (vastly) different number of samples and for each line.
    It should be possible to generate all seven signals with a single task by generating a waveform that includes all seven signals. If the signals repeat at different rates or you need to start/stop them independently, you will have to disable regeneration and continuously generate new waveform segments on the fly. Continuous Write Digital Port - External Clock - Non Regeneration should be a good starting point for the DAQmx programming, but actually generating the data is likely to be the challenging part.
    Brad
    Brad Keryan
    NI R&D

  • Configuring a PFI Line in Traditional NIDAQ

    Hi - I'm using traditional NIDAQ (v 7.0) with a PCI-6711 card; I'm trying
    to connect an external clock signal to the analog output timebase signal
    (i.e. to the UISOURCE signal, as it's called in the DAQ manual). I'm
    having trouble with the following:
    I'm using the PFI-7 line to bring in the external clock signal,
    and in the manual (p. 4-13) it specifically says that the PFI line used
    for this purpose should be configured in the level-detection mode.
    What I would like to find out is how to do this configuration (specifically).
    I looked at the documentation for the Select_Signal() command, but that
    didn't look right, and I can't find anymore info on how to configure
    PFI lines (in general) in the level-detxn mode (nor for the edge-detxn
    mode, for that matter).
    Any advice/comments are appreciated. Regards,
    ARB

    Thank you for contacting National Instruments.  I believe that Select_Signal is the command that you are looking for.   You will want it to look something like this:
    Select_Signal(devicenumber,ND_OUT_UPDATE_CLOCK_TIMEBASE,ND_PFI_0,ND_LOW_TO_HIGH OR ND_HIGH_TO_LOW)
    where devicenumber is the actual device number and the ND_LOW_TO_HIGH OR ND_HIGH_TO_LOW parameter will be one or the other.  You can read more about this by looking at the Select_Signal in the Traditional NI-DAQ help.  The Signal Name Equivalenices Table tells you that the UISource is called by the name ND_OUT_UPDATE_CLOCK_TIMEBASE.  Then, you can read into the parameters for this by clicking on the link that says:
    "Parameter Discussion for E Series, I Series, 671X, 673X, NI 5411, and DSA Devices"
    Then, click on the ND_OUT_UPDATE_CLOCK_TIMEBASE link in the table.  This will give you the possible parameter values for the source and sourcespec parameters.
    Hope this is helpful!
    Jeff P.
    National Instruments Applications Engineer
    Jeffrey P.
    LabVIEW Product Management
    National Instruments

  • Re: Question about the Satellite P300-18Z

    Hello everyone,
    I have a couple of questions about the Satellite P300-18Z.
    What "video out" does this laptop have? (DVI, s-video or d-sub)
    Can I link the laptop up to a LCD-TV and watch movies on a resolution of 1080p? (full-HD)
    What is the warranty on this laptop?

    Hello
    According the notebook specification Satellite P300-18Z has follow interfaces:
    DVI - No DVI port available
    HDMI - HDMI-out (HDMI out port available)
    Headphone Jack - External Headphone Jack (Stereo) available
    .link - iLink (Firewire) port available
    Line in Jack - No Line in Jack port available
    Line out Jack - No Line Out Jack available
    Microphone Jack - External Micrphone Jack
    TV-out - port available (S-Video port)
    VGA - VGA (External monitor port RGB port)
    Also you can connect it to your LCD TV using HDMI cable.
    Warranty is country specific and clarifies this with your local dealer but I know that all Toshiba products have 1 year standard warranty and also 1 year international warranty. you can of course expand it.

  • A question about the impact of SQL*PLUS SERVEROUTPUT option on v$sql

    Hello everybody,
    SQL> SELECT * FROM v$version;
    BANNER
    Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - 64bit Production
    PL/SQL Release 11.2.0.1.0 - Production
    CORE    11.2.0.1.0  Production
    TNS for Linux: Version 11.2.0.1.0 - Production
    NLSRTL Version 11.2.0.1.0 - Production
    SQL>
    OS : Fedora Core 17 (X86_64) Kernel 3.6.6-1.fc17.x86_64I would like to ask a question about the SQL*Plus SET SERVEROUTPUT ON/OFF option and its impact on queries on views such as v$sql and v$session. Here is the problem
    Actually I define three variables in SQL*Plus in order to store sid, serial# and prev_sql_id columns from v$session in order to be able to use them later, several times in different other queries, while I'm still working in the current session.
    So, here is how I proceed
    SET SERVEROUTPUT ON;  -- I often activate this option as the first line of almost all of my SQL-PL/SQL script files
    SET SQLBLANKLINES ON;
    VARIABLE mysid NUMBER
    VARIABLE myserial# NUMBER;
    VARIABLE saved_sql_id VARCHAR2(13);
    -- So first I store sid and serial# for the current session
    BEGIN
        SELECT sid, serial# INTO :mysid, :myserial#
        FROM v$session
        WHERE audsid = SYS_CONTEXT('UserEnv', 'SessionId');
    END;
    PL/SQL procedure successfully completed.
    -- Just check to see the result
    SQL> SELECT :mysid, :myserial# FROM DUAL;
        :MYSID :MYSERIAL#
           129   1067
    SQL> Now, let's say that I want to run the following query as the last SQL statement run within my current session
    SELECT * FROM employees WHERE salary >= 2800 AND ROWNUM <= 10;According to Oracle® Database Reference 11g Release 2 (11.2) description for v$session
    http://docs.oracle.com/cd/E11882_01/server.112/e25513/dynviews_3016.htm#REFRN30223]
    the column prev_sql_id includes the sql_id of the last sql statement executed for the given sid and serial# which in the case of my example, it will be the above mentioned SELECT query on the employees table. As a result, right after the SELECT statement on the employees table I run the following
    BEGIN
        SELECT prev_sql_id INTO :saved_sql_id
        FROM v$session
        WHERE sid = :mysid AND serial# = :myserial#;
    END;
    PL/SQL procedure successfully completed.
    SQL> SELECT :saved_sql_id FROM DUAL;
    :SAVED_SQL_ID
    9babjv8yq8ru3
    SQL> Having the value of sql_id, I'm supposed to find all information about cursor(s) for my SELECT statement and also its sql_text value in v$sql. Yet here is what I get when I query v$sql upon the stored sql_id
    SELECT child_number, sql_id, sql_text
    FROM v$sql
    WHERE sql_id = :saved_sql_id;
    CHILD_NUMBER   SQL_ID          SQL_TEXT
    0              9babjv8yq8ru3    BEGIN DBMS_OUTPUT.GET_LINES(:LINES, :NUMLINES); END;Therefore instead of
    SELECT * FROM employees WHERE salary >= 2800 AND ROWNUM <= 10;for the value of sql_text I get the following value
    BEGIN DBMS_OUTPUT.GET_LINES(:LINES, :NUMLINES);Which is not of course what I was expecting to find in v$sql for the given sql_id.
    After a bit googling I found the following thread on the OTN forum where it had been suggested (well I think maybe not exactly for the same problem) to turn off SERVEROUTPUT.
    Problem with dbms_xplan.display_cursor
    This was precisely what I did
    SET SERVEROUTPUT OFFafter that I repeated the whole procedure and this time everything worked pretty well as expected. I checked SQL*Plus documentation for SERVEROUTPUT
    and also v$session page, yet I didn't find anything indicating that SERVEROUTPUT should be switched off whenever views such as v$sql, v$session
    are queired. I don't really understand the link in terms of impact that one can have on the other or better to say rather, why there is an impact
    Could anyone kindly make some clarification?
    thanks in advance,
    Regards,
    Dariyoosh

    >
    and also v$session page, yet I didn't find anything indicating that SERVEROUTPUT should be switched off whenever views such as v$sql, v$session
    are queired. I don't really understand the link in terms of impact that one can have on the other or better to say rather, why there is an impact
    Hi Dariyoosh,
    SET SERVEROUTPUT ON has the effect of executing dbms_output.get_lines after each and every statement. Not only related to system view.
    Here below what Tom Kyte is explaining in this page:
    Now, sqlplus sees this functionality and says "hey, would not it be nice for me to dump this buffer to screen for the user?". So, they added the SQLPlus command "set serveroutput on" which does two things
    1) it tells SQLPLUS you would like it <b>to execute dbms_output.get_lines after each and every statement</b>. You would like it to do this network rounding after each call. You would like this extra overhead to take place (think of an install script with hundreds/thousands of statements to be executed -- perhaps, just perhaps you don't want this extra call after every call)
    2) SQLPLUS automatically calls the dbms_output API "enable" to turn on the buffering that happens in the package.Regards.
    Al

Maybe you are looking for