LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Control from Host.Vi

Solved!
Go to solution

I don't see host VI in your example, so can't say where is error.
But you should to correct FPGA.vi:

1) only "Motor Control Loop" has "stop" button, another loops works forever. Why?
2) I'm sure you can merge all or almost all loops in one. This not only save FPGA resources, but make code simplier.
3) while loop in another while loop - bad idea. Your task has simplier solution.
4) PWM Generation(Position) and PWM Generation(Velocity,Acc. & Deceleration) has access to one resources. This danger for your hardware.
5) Data Acquisition Loop. You are torturer. You configure hardware, start acquisition, acquire data and stop acquisition EVERY iteration. And you trying to do it very fast (as fast as possible) because loop hasn't delay. WHY? In loop should be only acquisition.
6) In  Motor Control Loop you do the same.
7) Duty Cycle Loop doesn't work (try to understand why)
😎 FPGA LED of course not blinking (try to understand why).

This is not full list to correct. But try to correct and check capacity for work.

Message 31 of 38
(1,536 Views)

You are 100% right,i know there are lotta corrections ,i will work on that later when my host is also ready.With this fpga,i can make my motor run,thus i am retaining for now.

 

The fpga reference in host.vi is throwing error,thus comm btw them not happening.how to solve this??usually i compile the code and this issue doesn't show up but todaay even after compiling it does not.Pls help me with this

0 Kudos
Message 32 of 38
(1,534 Views)

I repeat again and again: I CAN'T find your errors without code. Your sample without host.vi

0 Kudos
Message 33 of 38
(1,521 Views)

Pls find attached the code.

Actually,i see that the Host is comm. with the FPGA,no idea what went wrong just i am proceeding further.

 

Here i use HBM 20N,100N sensors(Ni 9237),when i read those values i see that some random value being displayed whereas the datashest has other values.Could you let me know on this.

0 Kudos
Message 34 of 38
(1,505 Views)

 I do not understand you again,.
Error 61701 still actual, or that problem disappear?
Try turning off the dynamic mode in the settings open the FPGA.

Measurement error may be due to various reasons.
How often working cycle of the FPGA?
the sensor is connected correctly?
bridge or half-bridge?
But most likely you do not read the data correctly. I have already said that the start and stop must be out of loop.
You read data THEN start reading and immediately stop it. Of course you'll get random data.

0 Kudos
Message 35 of 38
(1,494 Views)

The previous error that i mentioned yesterday is resolved.

 

Presently wanna read the output of sensors for the range mentioned  in the datasheet.sensor is connected properly,its half bridge.

0 Kudos
Message 36 of 38
(1,490 Views)

Hello Artem,

Duty cycle loop,pwm generation loop does not work,i tried my best to understand and fix it but i could not.Pls could you help me.

 

0 Kudos
Message 37 of 38
(1,447 Views)

show your code

0 Kudos
Message 38 of 38
(1,432 Views)