Mahmoud Posted May 22, 2008 Report Share Posted May 22, 2008 Hi all ,, Im new to lab view , i'm currently using it for my graduation project (controlling gasoline engine using lab view) , my problem now is to utilize an encoder to perform specified tasks upon certian degrees , so i used loop that get the current degree from the encoder then perform the tasks upon specified conditions, the problem that the encoder frequency is higher than loop iteration frequency (i think that) for examlple i did an equality comparison with certain degree number then i found for low RPM it invoke the associated equality task but for heigher RPM it doesnt. so i thaught if the loop iteration frequency can be raised ? or can i make my tasks pulse driven ? i meant perform the tasks upon each pulse come from the encoder (instead of using loop) Thanks Quote Link to comment
Wire Warrior Posted May 22, 2008 Report Share Posted May 22, 2008 When you say make your code respond faster what sort of time scale are you talking about? The response time lag and frequency of response that you are needing change the answer (at least in my mind). Also, can you post your code? Easier to offer comments if we can see it. Quote Link to comment
Mahmoud Posted May 22, 2008 Author Report Share Posted May 22, 2008 hi i'm talking of about 20 RPS on each revolution 360 pulse means about 7200 pulse per second by searching i found a solution hope to be suitable in my situation QUOTE I would recommend using the encoder input as your sample clock for the AI. any information of how to do this ? Quote Link to comment
Tim_S Posted May 22, 2008 Report Share Posted May 22, 2008 QUOTE (Mahmoud @ May 21 2008, 08:21 AM) Im new to lab view , i'm currently using it for my graduation project (controlling gasoline engine using lab view) , my problem now is to utilize an encoder to perform specified tasks upon certian degrees , so i used loop that get the current degree from the encoder then perform the tasks upon specified conditions, the problem that the encoder frequency is higher than loop iteration frequency (i think that) for examlple i did an equality comparison with certain degree number then i found for low RPM it invoke the associated equality task but for heigher RPM it doesnt. What kind of task are you trying to perform? Based some assumptions of your rates (20 RPS and 360 ppr), you're not going to be able to respond to many things with Windows. There are alternative methods of DAQ if you're trying to make measurements with post-DAQ-analysis. Throw out your Windows routines and get something that is FPGA based (cRIO or the RIO boards work well) if you're trying to control engine components. QUOTE (Mahmoud @ May 21 2008, 04:04 PM) any information of how to do this ? Read the documentation for the board you are using; it's a matter of using the encoder as an external clock. Tim Quote Link to comment
Mahmoud Posted May 24, 2008 Author Report Share Posted May 24, 2008 QUOTE (Tim_S @ May 21 2008, 11:20 PM) What kind of task are you trying to perform? Based some assumptions of your rates (20 RPS and 360 ppr), you're not going to be able to respond to many things with Windows. There are alternative methods of DAQ if you're trying to make measurements with post-DAQ-analysis. Throw out your Windows routines and get something that is FPGA based (cRIO or the RIO boards work well) if you're trying to control engine components.Tim Tasks may be simplified to be invoking injector & ignition circuit via digital signals once per revolution upon specific degrees the card used is http://sine.ni.com/nips/cds/view/p/lang/en/nid/14122' target="_blank">ni 6250 Quote Link to comment
Tim_S Posted May 24, 2008 Report Share Posted May 24, 2008 QUOTE (Mahmoud @ May 22 2008, 07:36 PM) Tasks may be simplified to be invoking injector & ignition circuit via digital signals once per revolution upon specific degreesthe card used is http://sine.ni.com/nips/cds/view/p/lang/en/nid/14122' target="_blank">ni 6250 My company builds ATE and lab equipment that includes engine cold test (which includes engine control module simulation for ignition events and cylinder cutout). You want something FPGA based and not a M-Series card. It may be possible to do what you need with a series of counter/timers; unfortunately, the 6250 card likely doesn't contain enough counters to decode TDC position much less create the timing signals you'll need. Tim Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.