How to identify which switch in the Panel called the function?

Here I have some 192 switches and 192 leds corresponding to each switch,

If a switch is on(say 10th) consequence (10th) led should light up.

I want to use the same function for all pairs of led switch.

all I could do was to check the switch in a loop and then set the individual leads, but I find it very little effective way to do it.

int switchOnOff (int, int int event control panel CVICALLBACK,
void * callbackData, int eventData1, int eventData2) is the function.

None of these arguments I can use it to extract what (the unique id for this turnout) switch called the function so that I can pass corresponding led glow?

It occurred to me now that the table is not necessary at all: you can simply assign to each switch the corresponding ID led the callbackData, so that the code is even simpler than my previous:

// At panel load:
SetCtrlAttribute (panelHandle, PANEL_SWITCH1, ATTR_CALLBACK_DATA, (void *)PANEL_LED1);
...
SetCtrlAttribute (panelHandle, PANEL_SWITCH192, ATTR_CALLBACK_DATA, (void *)PANEL_LED192);

// In the control callback
GetCtrlVal (panel, control, &sts);
SetCtrlVal (panel, (int)callbackData, sts);

To answer your last question, "Management Board" means immediately after the call to LoadPanel.

Tags: NI Software

Similar Questions

  • Common cause of failure of the Mirage server in clustered environment and how customers will be switched to the other server in a cluster

    Hello

    Can someone share me information about common cause of failure of the Mirage server in clustered environment.

    And how customers will be switched to the other server in a cluster to continue their operations from the server failed.

    Kind regards

    C Bathesha

    In general, Mirage servers are not lacking. It is very rare (and not, for example, to problems of storage or endpoitns, which are more common).

    May raise problems of overload, memory or hardware malfunction too little.

    After that you make server standard troubleshooting (the etc system event log), you must file a Service request by VMware.

  • How to identify columns that have the same data in a SQL query or function?

    Deal all,

    How to identify columns that have the same data in a SQL query or function? I have the sample data as below

    DEPT_IDEMP_IDCome on
    !CITYSTATECOUNTRY111 June 1983DELHIHUMAN RESOURCESIndia1218 January 1987DELHIHUMAN RESOURCESIndia1328 November 1985DELHIHUMAN RESOURCESIndia144 June 1985DELHIHUMAN RESOURCESIndia255 June 1983MUMBAIHDIndia266 June 1983MUMBAIHDIndia277 June 1983MUMBAIHDIndia288 Jun. 1983MUMBAIHDIndia399. June 1983GURGAONDLIndia31010 June 1983GURGAONDLIndia

    Now, I want to Indify columns that have the same data for the same Department ID.

    Is it possible in sql unique or do I have to write the function for this? Pls Help how to write?

    Thanks in advance.

    You can try this?

    WITH T1)

    DEPT_ID, EMP_ID, DATE OF BIRTH, CITY, STATE, COUNTRY

    ), ()

    SELECT 1, 1, TO_DATE('1.) June 1983', 'JJ. LUN. (YYYY'), 'DELHI', 'HR', 'INDIA' OF THE DUAL UNION ALL

    SELECT 1, 2, TO_DATE('18.) January 1987', 'JJ. LUN. (YYYY'), 'DELHI', 'HR', 'INDIA' OF THE DUAL UNION ALL

    SELECT 1, 3, TO_DATE('28.) November 1985', 'JJ. LUN. (YYYY'), 'DELHI', 'HR', 'INDIA' OF THE DUAL UNION ALL

    SELECT 1, 4, TO_DATE('4.) June 1985', 'JJ. LUN. (YYYY'), 'DELHI', 'HR', 'INDIA' OF THE DUAL UNION ALL

    SELECT 2.5, TO_DATE('5.) June 1983', 'JJ. LUN. (YYYY'), 'BOMBAY', 'HD', 'INDIA' OF THE DUAL UNION ALL

    SELECT 2.6, TO_DATE('6.) June 1983', 'JJ. LUN. (YYYY'), 'BOMBAY', 'HD', 'INDIA' OF THE DUAL UNION ALL

    SELECT 2.7, TO_DATE('7.) June 1983', 'JJ. LUN. (YYYY'), 'BOMBAY', 'HD', 'INDIA' OF THE DUAL UNION ALL

    SELECT 2.8, TO_DATE('8.) June 1983', 'JJ. LUN. (YYYY'), 'BOMBAY', 'HD', 'INDIA' OF THE DUAL UNION ALL

    SELECT 3, 9, TO_DATE('9.) June 1983', 'JJ. LUN. (YYYY'), 'GURGAON', 'DL', 'INDIA' OF THE DUAL UNION ALL

    SELECT 3.10, TO_DATE('10.) June 1983', 'JJ. LUN. (YYYY'), 'GURGAON', 'DL', 'INDIA' OF THE DOUBLE)

    SELECT DEPT_ID,

    RTRIM (XMLAGG (XMLELEMENT(A,VALS||',')). Extract ('//Text ()'), ',') COLUMNS_WITH_DUPLICATE

    DE)

    SELECT * FROM)

    SELECT DEPT_ID,

    EMP_ID,

    Date of birth

    CITY,

    STATE,

    COUNTRY

    DE)

    SELECT DEPT_ID,

    EMP_ID,

    Date of birth

    CITY,

    STATE,

    COUNTRIES,

    COUNT (*) OVER(PARTITION BY DEPT_ID ORDER BY EMP_ID DESC,DOB DESC,CITY DESC,STATE DESC, COUNTRY DESC) RN

    DE)

    SELECT DEPT_ID,

    CASE WHEN(CEID>1) AND THEN 'YES' ELSE 'NO' END AS EMP_ID.

    CASE WHEN(CDOB>1) THEN 'YES' ELSE 'NO' END AS DATE OF BIRTH,

    CASE WHEN(CCITY>1) AND THEN 'YES' ELSE 'NO' END AS CITY.

    CASE WHEN(CSTATE>1) AND THEN 'YES' ELSE 'NO' END AS STATE.

    CASE WHEN(CCOUNTRY>1) THEN 'YES' ELSE 'NO' END AS A COUNTRY

    DE)

    SELECT DISTINCT

    DEPT_ID,

    CEID,

    CDOB,

    CITY,

    CSTATE,

    CCOUNTRY

    DE)

    SELECT DEPT_ID,

    COUNT (*) TO THE CEID (DEPT_ID PARTITION, EMP_ID),.

    COUNT (*) ON CDOB (DEPT_ID SCORE, DATE OF BIRTH),

    COUNT (*) ON THE CITY (DEPT_ID PARTITION, CITY),

    COUNT (*) ON CSTATE (DEPT_ID PARTITION, STATE).

    COUNT (*) ON CCOUNTRY (DEPT_ID, COUNTRY PARTITION)

    FROM T1)))

    WHERE RN = 1)

    UNPIVOT (CLO FOR (VALS) IN (EMP_ID, DATE OF BIRTH, CITY, STATE, COUNTRY)))

    WHERE COLS = "YES".

    DEPT_ID GROUP;

    OUTPUT:

    DEPT_ID COLUMNS_WITH_DUPLICATE
    --------- ------------------------

    1 CITY, COUNTRY, STATE
    2 CITY, COUNTRY, STATE
    3 CITY, COUNTRY, STATE

    Post edited by: Parth272025

  • How can I escape commas inside the function listQualify?

    I have

    am a newbie in coldfusion. I need help. My database has records of names of companies as: abc, Inc. For now I'm using this query:

    SELECT DISTINCT COMPANY FROM ComapanyTable WHERE (Company IN (#ListQualify(form.cCompanyList2, "'", ",")#))

    This problem is that it separates CBA, Inc..

    SELECT DISTINCT Company FROM CompanyTableWHERE (Company IN ('abc',' Inc.','xyz','Inc.'))

    I need to get the list, as it is, i.e. as: "abc, Inc.", "xyz, Inc." so that I can later insert these values into a new table.

    Insert the code:

    <cfquery name="insertPair" datasource="#DSN#" dbtype="ODBC"> INSERT INTO tblChildCompanyToParent (Parent_Account_ID, Child_Account_ID) SELECT DISTINCT <cfqueryparam value = "#form.pCompanyList#" CFSQLType = "CF_SQL_VARCHAR">, Company FROM CompanyTable WHERE Company IN (<cfqueryparam value="#ValueList(insertSelect.Company,';' )#" CFSQLType = "CF_SQL_VARCHAR" list="true" separator=";">) </cfquery>

    Code of the selection list

    <select multiple name="cCompanyList2" id="cCompanyList2" class="selectCCompany" data-attribute="selCCompany" size="10"> <cfloop query="childCompanyList"> <option value="#childCompanyList.Child_Account_ID#">#childCompanyList.Company#</option> </cfloop> </select>

    Y at - it anyway to solve this problem.

    Thank you for your help.

    I managed to fix it.

    I posted the solution to StackOverflow

    SQL - how can I escape commas inside the function listQualify? -Stack overflow

    Thank you once again!

  • How to identify which instance is associated with what earphone

    Hi all
    I have created a DB instance. Suppose that named 'B '. but there is already another this DB instance. Named 'A '.
    Then, I created a listener instance DB 'B '.

    Now, my what, is that HOW can I identify which instance is associated with what listener.

    (2) if I create listener can also created service. If I stopped that service and then I can fire the query or Login again, WHAT will be the expected result.
    I tried to ask people of my answer. but not convinced.
    Please help me for this.
    Thanks in advance

    See the listener.ora file. It is usually $ORACLE_HOME/network/admin/listener.ora

    You can see what listener is associated with a file.

    Details will generally be like this

    >
    LSNR1 =
    (DESCRIPTION_LIST =
    (DESCRIPTION =
    (ADDRESS_LIST =
    (ADDRESS = (PROTOCOL = TCP) (HOST = instance1)(PORT = 1666))
    )
    )
    )

    LSNR2 =
    (DESCRIPTION_LIST =
    (DESCRIPTION =
    (ADDRESS_LIST =
    (ADDRESS = (PROTOCOL = TCP) (HOST = instance2)(PORT = 2666))
    )
    )
    )

    >

    >
    If I create listener can also created service. If I stopped that service and then I can fire the query or Login again, WHAT will be the expected result.
    I tried to ask people of my answer. but not convinced.
    >

    A listener is used when a client wants to connect to the database server. If you connect directly to the server without using the name of the instance, then you can connect even if you stop the service.

    Check it,

    C:\Windows\system32>lsnrctl stop
    
    LSNRCTL for 32-bit Windows: Version 10.2.0.3.0 - Production on 03-MAY-2011 23:06
    :22
    
    Copyright (c) 1991, 2006, Oracle.  All rights reserved.
    
    Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC1)))
    The command completed successfully
    
    C:\Windows\system32>sqlplus ganesh
    
    SQL*Plus: Release 10.2.0.3.0 - Production on Tue May 3 23:06:36 2011
    
    Copyright (c) 1982, 2006, Oracle.  All Rights Reserved.
    
    Enter password:
    
    Connected to:
    Oracle Database 10g Enterprise Edition Release 10.2.0.3.0 - Production
    With the Partitioning, OLAP and Data Mining options
    
    SQL> select * from dual;
    
    D
    -
    X
    
    SQL>
    

    But if you try to connect from a client, or use the name of the instance, while connectineg
    you get the error like that,

    SQL> conn ganesh@ganesh
    Enter password: ******
    ERROR:
    ORA-12541: TNS:no listener
    
    Warning: You are no longer connected to ORACLE.
    SQL> 
    

    If you see, I used the name of the @ganesh instance.

    G.

  • Please help me identify which port is the port of USB 3.0 HP Compaq 15 - s001TU (G8D87PA)

    Hello Experts,

    Today, I got my 15-s001TU (G8D87PA) computer laptop HP Compaq. First of all thanks to HP & manufacturer to create this wonderful product. It seems absolutely stunning after opening the box. I opted for free Dos version, which equals no BONES.

    In any case I use it for 7 hours with latest version of Ubuntu 14.04 - 1 LTS and experinced is great. But I can't able to identify which USB port is a USB 3.0 among all available USB ports. In this model, there are three USB ports available - two located right off DVD player and one located next to left hand next to the LAN port and all are in black color.

    Now the litarature provided with this laptop is very in the Appendix, so anyone who can let me know which one is USB 3.0, it will be very useful.

    Thanks for the help.

    ArijitB14 wrote:

    Hello Experts,

    Today, I got my 15-s001TU (G8D87PA) computer laptop HP Compaq. First of all thanks to HP & manufacturer to create this wonderful product. It seems absolutely stunning after opening the box. I opted for free Dos version, which equals no BONES.

    In any case I use it for 7 hours with latest version of Ubuntu 14.04 - 1 LTS and experinced is great. But I can't able to identify which USB port is a USB 3.0 among all available USB ports. In this model, there are three USB ports available - two located right off DVD player and one located next to left hand next to the LAN port and all are in black color.

    Now the litarature provided with this laptop is very in the Appendix, so anyone who can let me know which one is USB 3.0, it will be very useful.

    Thanks for the help.

    Page 6 and 7 through 15 HP Notebook PC Compaq 15 Notebook PC Maintenance and Service of Guide

    The single USB port on the left side is the 3.0 a

    Kind regards

  • How to know which update causes the system crash

    Can you tell us how to check the update is the culprit?

    Hi Steve,.

    Inorder to know which update is the cause of the crash of the system, you can install the updates one by one. Firstly uninstall the updates that have been recently installed.

    Uninstall the update:

    1. click on start and type "update installed" in the searc box. Click on view installed updates

    2. right click on the update you want to uninstall. Once the uninstall is complete, reboot the computer.

    3. install the updates one by one.

    You would get to know what update is at the origin of the disorder. You can hide this particular update.

  • How to find which user have the Channel Manager

    Hello

    How to find which user are responsible for R12 Channel Manager.

    And how to invite the partner already in the list of my partners.

    Please answer me as soon as possible

    Thank you
    Vivek

    How to find which user are responsible for R12 Channel Manager.

    You can run 'The responsibility one users' simultaneous program or run the script in (how to find Out who the responsibility has been granted to A specific user? [ID] 304687.1).

    Please answer me as soon as possible

    For the responses of the ASAP, please log an SR.

    Thank you
    Hussein

  • How to identify which disk rawdevice is named as VOL1 in ASM OS level

    Hi friends,

    creation of the disk using the ASMLIB
    I want to know which drive is named as VOL1, VOL2, VOL3 etc. LINUX operating system.

    I know using v$ asm_disk we can query name, path, status, tag, etc...

    I want to know what raw device disk is named or configured as VOL1 (LINUX) operating system

    Thanks in advance.

    Rajesh.

    Published by: rajeysh on June 3, 2010 15:49

    And for this, you can use oracleasm querydisk. Using that you can identify which device marked for asm or not. for example you can see below the example.

    [oracle@localhost init.d]$ sqlplus "/as sysdba"
    
    SQL*Plus: Release 10.2.0.4.0 - Production on Thu Jun 3 11:52:12 2010
    
    Copyright (c) 1982, 2007, Oracle.  All Rights Reserved.
    
    Connected to:
    Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - 64bit Production
    With the Partitioning, OLAP, Data Mining and Real Application Testing options
    
    SQL> select path from v$asm_disk;
    
    PATH
    --------------------------------------------------------------------------------
    /dev/oracleasm/disks/VOL2
    /dev/oracleasm/disks/VOL1
    
    SQL> exit;
    
    [oracle@localhost init.d]$ su
    Password:
    [root@localhost init.d]# /sbin/fdisk -l
    
    Disk /dev/sda: 80.0 GB, 80000000000 bytes
    255 heads, 63 sectors/track, 9726 cylinders
    Units = cylinders of 16065 * 512 = 8225280 bytes
    
       Device Boot      Start         End      Blocks   Id  System
    /dev/sda1   *           1        1305    10482381   83  Linux
    /dev/sda2            1306        9401    65031120   83  Linux
    /dev/sda3            9402        9662     2096482+  82  Linux swap / Solaris
    /dev/sda4            9663        9726      514080    5  Extended
    /dev/sda5            9663        9726      514048+  83  Linux
    
    Disk /dev/sdb: 80.0 GB, 80026361856 bytes
    255 heads, 63 sectors/track, 9729 cylinders
    Units = cylinders of 16065 * 512 = 8225280 bytes
    
       Device Boot      Start         End      Blocks   Id  System
    /dev/sdb1               1        4859    39029886   83  Linux
    /dev/sdb2            4860        9729    39118275   83  Linux
    [root@localhost init.d]# ./oracleasm querydisk /dev/sdb1
    Device "/dev/sdb1" is marked an ASM disk with the label "VOL1"
    [root@localhost init.d]# ./oracleasm querydisk /dev/sdb2
    Device "/dev/sdb2" is marked an ASM disk with the label "VOL2"
    [root@localhost init.d]# ./oracleasm querydisk /dev/sda1
    Device "/dev/sda1" is not marked as an ASM disk
    [root@localhost init.d]# 
    

    Also in windows:

    C:\Documents and Settings\comp>asmtool -list
    NTFS                             \Device\Harddisk0\Partition1           140655M
    ORCLDISKDATA1                    \Device\Harddisk0\Partition2             4102M
    ORCLDISKDATA2                    \Device\Harddisk0\Partition3             4102M
    NTFS                             \Device\Harddisk0\Partition4           152617M
    
    C:\Documents and Settings\comp>
    

    It's answering your question. :-)

  • How to identify objects granted to the public

    Table/view are available to identify all objects in the database that have been granted to public? Thank you

    Hello

    If you don't have privileges to see dba_tab_privs, all_tab_privs is just fine.

  • Re: How to change its use of the function keys?

    The function keys on my laptop P870 are keys to double action. You must press the FN key at the same time as the key function F1, F2. In particular, I use the F2 key a lot but have to use 2 hands (unless you have extremely long fingers) to operate the function keys driving me crazy.

    Any suggestions?

    If you use open Office assist Win8 > system settings > keyboard and function keys mode change.
    Change of cell function special mode reboot and test how it works.

  • Adobe Captivate 7 - How to create a custom without the function table of contents table of contents?

    Hello

    I want to create a table of contents in my E-Learning-project because the automatically generated TOC of Adobe Captivate 7 includes all the features I need to check for example chapters which are the groups in the film strip.


    I use master slides in my project.
    The table of contents, I need must be designed and programmed as follows:

    1 intro / title slides

    9 chapters

    The progress of the work - 3 status - all chapters should be moved by symbols in the table of contents

    Symbol 1: chapter has not yet begun (just an empty box)

    Side 2: chapter is work in progress (a square with a green triangle inside)
    Side 3: chapter is finished that means that all of the slides in this chapter are read (the square is filled with a green square)

    All the chapters and Points to the table of contents must be clickable (links) maybe with a mouse over effect (change in colour of mouse) and should start to the first slide of this chapter.

    The chapter which is open must be written in bold with one blue color, others who are not open to be written in the normal font with a black color

    I think it's a little complex, but solutionable.

    I think I need to create three symbols of the buttons form, advanced actions that tend to fade and fade out named symbols.

    Is there someone who can describe the process of creation? Where should I place all the functions, actions and so on? On the slide master?

    Thank you for the answers!

    The only thing I can say about it is that I build it in Flash, so it could be dynamic and reusable.

    If you take the time to build a PC inside it only works for one project. Certainly you would have a base to work from, but for a another edition project wouldn't be fun.

    If you need HTML5, I think it would be much more difficult to build a dynamic table of contents.

  • How to write to .subckt with the function I - V

    Hi all

    Now, I am trying to build a Spice model for a type of diode high voltage for 13 Multisim. Because I do not have the LED electronic settings, and I only have the function of the I - V, I tried to write a file .subckt for him.

    Assuming that the anode is A1 and the cathode is A2, the current flowing through the diode can be expressed only by the function:

    I=((0.581*(V(A1)-V(A2))*(V(A1)-V(A2))/3/3-18.4*(V(A1)-V(A2))/3+144.66)/1000)*U((V(A1)-V(A2))-53)

    With her, I wrote a .subckt:

    . SUBCKT LED A1 A2
    B1 A2 A1 I=((0.581*(V(A1)-V(A2))*(V(A1)-V(A2))/3/3-18.4*(V(A1)-V(A2))/3+144.66)/1000)*U((V(A1)-V(A2))-53)
    . ENDS LED

    This model works well under the IV parser in Multisim 13, but when I connect 2 or 3 of them in series and make a simple circuit simulation, I always get the error report and not always not correct the error.

    Any body can help me to check if my .subckt is correct or not? Thank you.

    It seems that the convergence error is caused by a discontinuity the diode to connection 53V.  Run DC scan using the test circuit.

    To prevent the discontinuity, use the express following with the fi works instead. You can give it a small current when V (A1, A2) is less to 0V.

    B1 A1 A2 I=if(((V(A1)-V(A2))-51)>0,((0.581*(V(A1)-V(A2))*(V(A1)-V(A2))/3/3-18.4*(V(A1)-V(A2))/3+144.66)/1000),-230u)

    The attached circuit have a resistance using convergence.

    You can simplify your expression for readability:

    -(V, (A1), (A2) V) = V (A1, A2)

    -If you can do the expression in this form, it will simply be the calculation ax ^ 2 + bx + c

  • 5520 photosmart all-in-one: how to identify which cartridge needs replacing on 5520

    My computer showed me the message that the printer ink is running low.  I open the printer to replace the cartridge, but I don't see what cartridge, color or black, that has to be changed.  On my previous printer, low cartridge has been identified by a flashing light.

    How will I know which cartridge to replace?

    Hello

    Since the home printer screen, tap ink icon (symbol of gout).

    Kind regards.

  • How to identify a pirate on the computer?

    Original title: How can I find out what files/info (shared without permission) have been hacked by someone I know) on my computer...

    Hello. Is it possible to see a report of which files have been shared from my computer (my share permissions have been changed and I know at least one other computer that now has many of my files and folders on their system. I'd like to know how, what in particular, and who went to my information. Date and time would be fantastic and if this was done by remote access manually on my computer that would also be very useful. Ive looked a few things but his computer talking and not much. Am happy to take screenshots and download, if you could please tell me how to get to the screen that you should see. My gmail has also been copied and shared - if you could help with that too, that would be fabulous! Thanks in advance! )

    Here it is in plain English:

    Windows, by default, not "look at" what is happening on your computer in any real depth.  It records errors, warnings, and events.  He may have recorded a person changing sharing on your computer, but it would show only who was logged in when the change was made.  If you were connected, it would show that you HAVE made the changes.

    The TV shows like CSI or NCIS or law and order as showing people sitting in front of a laptop, a few keystrokes on the keyboard and then announcing "the file was acceded to 23:35 by Russian agents...". "but events like this are all made up.  Looks good on TV, not how it works in reality.

    Now yes, it IS possible to have your computer to connect as many details but you should have to bring to market the first.  You do not have... so he did not.

Maybe you are looking for

  • How can songs of flags of 9.3 iTunes iOS as explicit when they are not, I turn off?

    So, I'm in the car, my child is screaming his eyes, I'm putting on music to soothe, but all his favorite album songs are coming as explicit?  This never happened before, the album still played without problems. The only change I see is that I have up

  • Help create a USB bootable for mini HP.

  • I have a d28sr CQ58 with missing driver PCI

    I have a CQ58-d28sr recently purchased in Kazkahstan, crashed my old PC and trying to enter and exit the PCs is very difficult. My Windows 7 64-bit support and I am unable to find drivers The hardware details Any help at all to go would help as the l

  • Purchase of a new SSD

    Hi guys,. I hope you can help me with my question.I want to improve the SSD unit who came inside Lenovo Ideapad U510 mi. But when searching, I found a wide variety of these units of different brands and prices. My question is if any unit 2.5 SSD "wil

  • HP 8500 A909g scanner does not work

    Recently my HP 8500 A909g scanner does not work.  I did not change my system.  I use Windows 7.  When I click on scan in the HP Solution Center, I get the message that the HP imaging device is not found.  Several solutions are listed I tried each of