|
|
|
![]() |
|
|||||||
|
||||||||
![]() |
| Thread Tools | Rate Thread | Display Modes |
|
#1
|
||||
|
||||
|
Labview on PC using udp C++ on cRIO need udp server solution
My team has labview getting correct distances on the DS. We just can't get them to the driver station. Desperately needing help.
|
|
#2
|
|||
|
|||
|
Re: Labview on PC using udp C++ on cRIO need udp server solution
Do you mean you are having trouble sending data from the cRIO to the Dashboard? If so, you'd flatten your data to a string and send it via Set User Data High.vi.
|
|
#3
|
||||
|
||||
|
Re: Labview on PC using udp C++ on cRIO need udp server solution
No I need to receive the data on the robot. I do not have a viable solution at the moment. How would I schedule a udp server that runs threaded on the robot. I am out of my depth on that. Networktables I can not get to work.
|
|
#4
|
|||
|
|||
|
Re: Labview on PC using udp C++ on cRIO need udp server solution
There are other threads on this with more deails, but generally, I'd suggest using UDP. An example of this is in the dashboard already, where the Kinect info is read from the DS. Change the read to a write, and change the port and the LV side should be done. I don't know that I can point you to a UDP example for C++, but I suspect you can google and find some.
Greg McKaskle |
|
#5
|
||||
|
||||
|
Re: Labview on PC using udp C++ on cRIO need udp server solution
I have found some. I just wanted to know how to fork off a process so that it was running in background after starting robot.
|
|
#6
|
|||
|
|||
|
Re: Labview on PC using udp C++ on cRIO need udp server solution
I think WPILib includes a task class that will wrap the posix thread APIs. That should make it pretty easy to do.
Greg McKaskle |
|
#7
|
||||
|
||||
|
Re: Labview on PC using udp C++ on cRIO need udp server solution
Thanks I will try that. Write now we are messing with your networkable you made in LV. Will the robot c++ code work with that combo? Are they combatable is basically what I am asking. Will find out in the next 30 minutes.
Next year all Lab view this is not fun trying to glue all these dissimilar things together. |
|
#8
|
|||
|
|||
|
Re: Labview on PC using udp C++ on cRIO need udp server solution
Hopefully the LV and C++ network tables are compatable. I've tried Java and LV in simple cases and I put it into beta to see what worked. Please let me know.
Greg McKaskle |
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|