Keyboard Interrupt and NI-DAQ
Hi! I have this problem when using an AT-MIO-16E-10:
I made a program in Borland C++ 3.1 that does the following:
-reads in pretriggered mode from an A/D channel (with DAQ_Start);
-when the conversion is done a message is sent to my aplication (Config_DAQ_Event_Message);
- when the message is received by the callback function I do computations with the voltage that was acquired with the DAQ_Start in previous step and the result is sent to a D/A channel (I control a process, and the computations is a numeric PID algorithm).
- all this steps are executed for all datas that DAQ_Start sends to the buffer data. Pretriggered mode is enable and at the end of the main program I have an infinite loop that looks like this:
while(not ESC);
-so the A/D conversions,computations and the D/A conversions are done infinity until ESC is pressed.
The problem is that to notice my application when ESC is pressed I took the keyboard interrupt vector that treats the ESC message. Also in my program I have to change the reference of the process I control; the reference is change also by my keyboard interrupt procedure (if I press '1.0' the reference of the process is a voltage of 1.0V)
Now I get this error when executing the program:
-the A/D conversions are not done correctly (in tests I had values in my buffer even greater 4096, voltages greater then 10V, also a zero is inserted at the even adresses of the buffer - buffer[0], buffer[2], buffer[4]etc. are zero )
-if I don't install the interrupt in the main program and the code of the new keyboard interrupt (declared : void far interrupt my09(void); ) is still in the program (but never used,I don't take the vector interrupt) the result is the same as above.
-when I don't use the keyboard interrupt in my application I I don't put the code of the my keyboard interrupt procedure(the reference is equal with 1.0V in the main program, and I don't change it in any way) the program runs fine and no problem occurs.
Can you please tell what is the solution of this problem? Why can't I have the code of an interrupt procedure in my program?
All the functions that I use in my program are tested and correct implemented. In all other programs that I made, my keyboard interrupt procedure runs without errors and the results are correct. Also this application runs fine if a don't put the code of the keyboard interrupt procedure in it.
Hi again!
Actually I used the "while(1)" loop without using the keyboard interrupt in my application and it worked fine. What I'm confuse about is that even if I don't use the interrupt procedure in the main function and the code of the interrupt is still in my source code, but never used, just code that is never called, because I don't install it, the program gives me the same results as I've explained in the first post, with zeros inserted in the buffer, and voltages greater then 10V.
The timing is not the problem, I can say that for sure, because I've made a tricky one: I installed the keyboard interrupt in another program, that is a TSR. This TSR is activated by the keyboard and it sends all the data I need (in my case: the reference, the ESC fla
g and the CR flag, that memorize if these are pressed) to my NI-DAQ application (I've implemented some code of inter-process comunication). In this case the results are completely the expected one. And this is just because I don't have an interrupt procedure in the same program with NI-DAQ functions.
Neither the interrupt procedure is not the problem, because it's the same in the TSR, and it works fine.
Yet, another program I've done used the timer interrupt, and basically it does the same thing. At every two int 0x08 calls (a sample interval of 110ms) I do this (in the my0x08 procedure):
- AI_VRead...
- do the numeric PI algorithm to the data.
- AO_VWrite...
The result was still the same.
I'm using Borland C++ 3.1 for DOS. Now I'm asking if the problem is not from the compiler. Maybe the segment model I use (although I've tried all of them)or how the compiler is generating the code declared with the prototype:
void far interrupt my_0x09(void);
Similar Messages
-
what if you click restore and the progress bar is interrupted and says that your ipod is busy? Then what?
Reset the iPod - Press Menu and Select simultaneously for about 10 secs or till the Apple Logo comes ON.
Disconnect the iPod, and all other USB devices
connect the iPod to another USB Port, and not to a USB hub. (Never connect the iPod to the USB port on the Keyboard.)
Run Disk Utility -> First Aid->Erase (to correct any filesystem corruption.
Then run iTunes and Restore. -
I want to use an interrupt service routine with a PCI6025E using the DAQ-STC.
On which pin can I input my signal (perhaps on Gate0) and which registers
must be configured. I'm not interested about how to create an ISR, just the
register value to generate an IRQ on the PCI-Bus.The DAQ-STC Technical Reference Manual (downloadable) may help you. A quick flick through my copy suggests the section you want is 8.4.1.3 Pass-Through Interrupt and it looks like input pins IRQ_IN<0..1> are what you need, assuming your card supports this functionality.
Jamie Fraser -
I managed to download to my desktop entered key etc but when I try and install the wizard says it was interrupted and not fully installed no changes made to the system try again later - did this loads of times - same response - anybody any ideas what Im doing wrong?
Hi
Sorry I was away for a while – how do I run check disc on windows 8. The laptop is new and is an Aspire V17, I believe it has a high spec and therefore should have no issues??
Phil
(Phil Dickinson) -
my keyboard on macbook pro (laptop) is acting weird. One key is not responding at all. Have verified using Keyboard viewer and some other keys are printing the unresponsive character at random. "z" is the unresponsive character.
Is it a damaged keyboard ?
The laptop is just 2 months old, will Apple replace it with a new one if its indeed a damaged keyboard or just repair, I use it for official purposes so being without a laptop is not much of an option.No one here works for Apple, so we don't know what Apple might or might not do. If it's a genuine defect, they will of course repair it under warranty. It is not their responsibility if it effects your ability to work or not, so that's on you.
If, however, they determine that the key is problematic as a result of your misuse of the laptop, then everything is on you. And trust me, if they find a glob of dried up beer or coffee there, they will charge you.
Your only choice is to take it in for repair. -
I shut off my computer and the next day replaced the batteries in my keyboard after getting the low battery message. After replacing them and turning the keyboard on and off the green LED was blinking which meant it was in discovery mode. The problem is I can't login to my computer because I need to type in a password. But I can't use the keyboard so I can't use my mouse to find the device because I can't login. The aluminum ball trick did not work and I did recheck the battery life and they are in the right way. How do I fix this?
Try resetting the iPod > iPod touch: Turning off and on (restarting) and resetting
-
How do I upgrade the iOs on my ipad1 to version5? I've tried through itunes many times, but I get a message that says that the download was interrupted and i should try again later. Can i download the iOS file to my PC and transfer it to the ipad? How should I do that?
Thank you!
Disabling firewall and AV did the trick!
Kudos.
Alex -
How do you unlock a disabled ipad mini? I have my notes in Notability and I don't want to lose them. I know my passcode but I left my keyboard on and it disabled it.
Unfortunately... Once the Device is asking to be Restored with iTunes... it is too late to save anything...
See Here > http://support.apple.com/kb/HT1808
However... Once you have Recovered your Device...
Re-Sync your Content or Restore from the most recent Backup...
Restore from Backup > http://support.apple.com/kb/ht1766
Jessica Sanchez wrote:
I am installing itunes to a laptop and have not sync device to this lap. ...
Using a computer, other than the one you have regularily been Syncing and Backing up to, was the begining of your issue. -
I am having trouble transferring files from an old MacBook (2007) to a MacBook Air over a wireless network. The connection was interrupted and the time was over 24 hours. Is there a better way to do this? I'm using Migration assistant. The lack of an ethernet port on MacBook air does not help.
William ..
Alternative data transfer methods suggested here > OS X: How to migrate data from another Mac using Mavericks -
My wireless keyboard disconnects and reconnects within seconds but all text that was typed during the time offline is missing. i have to go back and retype missing parts. What can I do to troubleshoot this. The computer is only about six month old. This problem is new in the last couple weeks. Thanks for suggestions.
Beat me to it, Donald. But there is a possible alternative. If the batteries have been replaced since new, were they replaced with the same batteries or another make. There are examples around which do not fit perfectly and leave a certain amount of movement inside the battery housing. That could lead to instability such as the OP describes.
-
Some of my applications have been saying I need the latest version of Adoebe Flash Player. When I try to download it I get the following error message: 'Frame Load interrupted' and the installation stops. Any suggestions?
You can only use apps downloaded from the App store, not via a browser. There is no Flash for any iOS device including the iPod.
-
My OS X Mountain Lion download was interrupted and now I can't get it to download at all.
My OS X 7 Mountain Lion download was interrupted and now I have a Mountain Lion shadow on my doc saying "paused" but I can't seem to restart the download
If the download does not resume, then Quit the App Store app and delete the partial download in your Applications folder. Then you will have to start the download all over again from the "Purchases" section of the App store.
-
I often travel abroad and my host has changed Internet provider. Then my service was interrupted and I can't update iTunes. Any tips to stop the error messages?
Wow! At least on Apple TV, problem solved. Apple: what's not to love? Please give me credit if you use it in marketing campaigns... ;-)
-
Before I go into a lengthy explanation of the problem: Can anyone help with Double Command issues. This a specific keyboard question and they do not seem to know.
Thanks much.
EmileChoose Force Quit from the Apple menu and close Mail from there.
(103661) -
I am trying to download the update IOS 5 version for mi ipad 2 and at the end when it finishes downloading it shows an error "connection has been interrupted and that the task could not be completed", my internet service is fine, what can it be?
The 2nd generation can not be upgraded beyond 4.2.1.
Maybe you are looking for
-
With holding tax error FZ379-"Error in WHT certificate numbering"-Thailand
Hi, We are receiving an error "FZ379 - Error in WHT certificate numbering" while posting an outgoing payment for a vendor in Thailnd. Here is the business process we follwed: 1. Posted Down payment request on vendor. 2. Paid down payment through F110
-
i know this probably sound like a stupid question but i am really a newbie to mac. Do you think i would notice a massive speed increase by upgrading from my 500mhz imac g3 summer 2001 to a powermac g4 1.42 DP. Also would leopard run well on the power
-
I've set pdf files to open with my default application (without asking). Nerveless, FF keeps asking whether to save or open the file. (The same happens with any file type, and also in safe mode and a new profile). Any idea? Thanks.
-
Certain Javascript Not Working in All Browsers
Certain javascript elements on websites won't function at all, and it's not apparent why. For example, when I'm http://www.reddit.com/ and I try to upvote or downvote a submission, nothing will happen, and little text in the bottom left corner of my
-
I spent a day with the trial version of In Design in hopes of creating a decent eBook and thus far I'm finding it a none working peice of software in windows 7. It is not doing what it should do. Being connected to the cloud while using it has not pr