Go to Post The game starts, we learn, the game changes, we learn some more, the game changes again, we learn even more . . . - Bill Moore [more]
Home
Go Back   Chief Delphi > Technical > Programming > NI LabVIEW
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Reply
Thread Tools Rate Thread Display Modes
  #16   Spotlight this post!  
Unread 22-01-2014, 18:04
bharrison6 bharrison6 is offline
Registered User
FRC #3843
 
Join Date: Jan 2014
Location: Murray Ky
Posts: 37
bharrison6 is on a distinguished road
Re: New Programming Core needs help with simple motor control

Quote:
Originally Posted by Cecil View Post
I think I may see the problem. Instead of clicking "Run" from the Simple Motor Control.vi", Open up the "Robot Main.vi" and click "Run Continuously".

Also, try runing your code with Teleoperated selected on the Driver Station, not Test. The Test function will return values to the test screen, while Teleoperated should control it normally.

I have tried both run and run continuously for the simple motor control. As for the Robot Main.vi I have not ran the code within Labview. The reason is because I can not run the code within labview and open up the driver station at the same time. I therefore compiled the code deployed the code to the robot to run on start up and then open the driver station.
Reply With Quote
  #17   Spotlight this post!  
Unread 22-01-2014, 19:48
Greg McKaskle Greg McKaskle is offline
Registered User
FRC #2468 (Team NI & Appreciate)
 
Join Date: Apr 2008
Rookie Year: 2008
Location: Austin, TX
Posts: 4,748
Greg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond repute
Re: New Programming Core needs help with simple motor control

The Simple Motor VI looks fine for verifying things. It includes the Start Communications icon to connect to the DS. It has a loop in it, so no need to continuous run.

If your RSL is not blinking, is the small LED on the digital breakout board blinking? The LED helps distinguish between bad signal or power to the big light or an issue with the signal to the breakout board.

One of the things that hasn't been discussed is the ribbon cable. I've heard of bad cables and backwards cables over the last few years. Can you try another?

Greg McKaskle
Reply With Quote
  #18   Spotlight this post!  
Unread 22-01-2014, 20:48
bharrison6 bharrison6 is offline
Registered User
FRC #3843
 
Join Date: Jan 2014
Location: Murray Ky
Posts: 37
bharrison6 is on a distinguished road
Re: New Programming Core needs help with simple motor control

Quote:
Originally Posted by Greg McKaskle View Post
The Simple Motor VI looks fine for verifying things. It includes the Start Communications icon to connect to the DS. It has a loop in it, so no need to continuous run.

If your RSL is not blinking, is the small LED on the digital breakout board blinking? The LED helps distinguish between bad signal or power to the big light or an issue with the signal to the breakout board.

One of the things that hasn't been discussed is the ribbon cable. I've heard of bad cables and backwards cables over the last few years. Can you try another?

Greg McKaskle
The only leds on the breakout board that are lit up are the 5v the 6v, the bat led, and an led beside the 1 (see pic). They are all green and steady on in every configuration and under every circumstance for this rig. Also every part on this rig has been worked at one time or another and each piece has been swapped out with another piece that has worked at one time or another.

I was wondering though. Does it matter if the crio that I am using is the longer 16 bit version or the shorter 32 bit version? Also does it matter if I am using a crossover cable? I know what they are since I have wired both CAT 5 and CAT 6 but I don't know if the one I am using is crossover or not without checking the wires and looking up the colors for crossover. I would think as long as I can deploy code to the crio the network cable is fine. If I remember my networking class right most NICs can actually detect if it needs the crossover and compensate anyway.

Thanks again for yall's help.

P.S. If anyone thinks I should try this with a different programming language and has some java or c++ code I can try out I can see if I can get a copy of those compilers and try to get this running on a different programming language. I know both decent enough to work with it. I just want to see this thing turn a motor and then I can take the next step.

Reply With Quote
  #19   Spotlight this post!  
Unread 22-01-2014, 20:49
bharrison6 bharrison6 is offline
Registered User
FRC #3843
 
Join Date: Jan 2014
Location: Murray Ky
Posts: 37
bharrison6 is on a distinguished road
Re: New Programming Core needs help with simple motor control

Also above it looks like 1 and 2 are on, but its actually just 1 and a reflection off the plastic.
Reply With Quote
  #20   Spotlight this post!  
Unread 22-01-2014, 21:59
bharrison6 bharrison6 is offline
Registered User
FRC #3843
 
Join Date: Jan 2014
Location: Murray Ky
Posts: 37
bharrison6 is on a distinguished road
Re: New Programming Core needs help with simple motor control

Also I am reformatting my CRIO for like the 10th time just to make sure something isn't wrong there and I noticed with this 32 bit 4 slot crio that there are no physical dip switches. Everytime I reformat the CRIO I see the dip switch positions and the console out dip switch is flipped. I have no idea what it does, but I do click on it on the FRC image tool and turn it off before formatting. It does somehow turn itself back on the next time I try formatting though.


Last edited by bharrison6 : 22-01-2014 at 22:02.
Reply With Quote
  #21   Spotlight this post!  
Unread 22-01-2014, 22:20
bharrison6 bharrison6 is offline
Registered User
FRC #3843
 
Join Date: Jan 2014
Location: Murray Ky
Posts: 37
bharrison6 is on a distinguished road
Re: New Programming Core needs help with simple motor control

Just reimaged it with another computer and deployed the project template code. The only change in the code was in the begin.vi where the open motor is set to victor instead of jaguar. No PWM signal, no RSL signal.


Last edited by bharrison6 : 22-01-2014 at 22:24.
Reply With Quote
  #22   Spotlight this post!  
Unread 22-01-2014, 22:39
bharrison6 bharrison6 is offline
Registered User
FRC #3843
 
Join Date: Jan 2014
Location: Murray Ky
Posts: 37
bharrison6 is on a distinguished road
Re: New Programming Core needs help with simple motor control

I just noticed after reading what other problems people are having that our driver station is reading 0 Volts. This might be of some significance as to what the problem is.
Reply With Quote
  #23   Spotlight this post!  
Unread 22-01-2014, 22:43
Joe Ross's Avatar Unsung FIRST Hero
Joe Ross Joe Ross is offline
Registered User
FRC #0330 (Beachbots)
Team Role: Engineer
 
Join Date: Jun 2001
Rookie Year: 1997
Location: Los Angeles, CA
Posts: 8,560
Joe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond reputeJoe Ross has a reputation beyond repute
Re: New Programming Core needs help with simple motor control

Quote:
Originally Posted by bharrison6 View Post
The only leds on the breakout board that are lit up are the 5v the 6v, the bat led, and an led beside the 1 (see pic). They are all green and steady on in every configuration and under every circumstance for this rig. Also every part on this rig has been worked at one time or another and each piece has been swapped out with another piece that has worked at one time or another.

I was wondering though. Does it matter if the crio that I am using is the longer 16 bit version or the shorter 32 bit version? Also does it matter if I am using a crossover cable? I know what they are since I have wired both CAT 5 and CAT 6 but I don't know if the one I am using is crossover or not without checking the wires and looking up the colors for crossover. I would think as long as I can deploy code to the crio the network cable is fine. If I remember my networking class right most NICs can actually detect if it needs the crossover and compensate anyway.

Given that all 3 power LEDs are brightly lit, 2 relays are lit, and the RSL is not, I would guess that there is a problem with the Digital Sidecar, DB-37 Cable, Digital Module, or the connection between the cRIO and the Digital Module.

None of the other things you mentioned would matter.

Quote:
Originally Posted by bharrison6 View Post
I just noticed after reading what other problems people are having that our driver station is reading 0 Volts. This might be of some significance as to what the problem is.
This means that one of the conditions in R70 isn't met, but does not affect driving motors.
Reply With Quote
  #24   Spotlight this post!  
Unread 22-01-2014, 23:22
Alan Anderson's Avatar
Alan Anderson Alan Anderson is offline
Software Architect
FRC #0045 (TechnoKats)
Team Role: Mentor
 
Join Date: Feb 2004
Rookie Year: 2004
Location: Kokomo, Indiana
Posts: 9,112
Alan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond repute
Re: New Programming Core needs help with simple motor control

Quote:
Originally Posted by bharrison6 View Post
I have tried both run and run continuously for the simple motor control. As for the Robot Main.vi I have not ran the code within Labview. The reason is because I can not run the code within labview and open up the driver station at the same time.
Teams run LabVIEW and the Driver Station simultaneously all the time. What's keeping you from doing it?

Quote:
I therefore compiled the code deployed the code to the robot to run on start up and then open the driver station.
If you're trying to run the Simple Motor Control example, you must run it interactively. You have to be able to change the front panel control while it is executing in order to change the value being sent to the motor.

If you're doing a Compile followed by a Run as Startup, then you're not running the example. You're running Robot Main, which calls all the other Team Code.
Reply With Quote
  #25   Spotlight this post!  
Unread 22-01-2014, 23:57
bharrison6 bharrison6 is offline
Registered User
FRC #3843
 
Join Date: Jan 2014
Location: Murray Ky
Posts: 37
bharrison6 is on a distinguished road
Re: New Programming Core needs help with simple motor control

Quote:
Originally Posted by Alan Anderson View Post
Teams run LabVIEW and the Driver Station simultaneously all the time. What's keeping you from doing it?



If you're trying to run the Simple Motor Control example, you must run it interactively. You have to be able to change the front panel control while it is executing in order to change the value being sent to the motor.

If you're doing a Compile followed by a Run as Startup, then you're not running the example. You're running Robot Main, which calls all the other Team Code.
originally, when running lab view, I got an error message about trying to connect to the CRIO when opening the driver station. I assumed they couldn't both connect at the same time. Since that time I have retried it with success. In fact the last few pics I posted of the driver station was when it was running with lab view open with the robot main open and running continuously. I have tried compiling and run as startup on the example code after changing the variable to a constant of .5 with no success but otherwise I am just running it and manipulating the variable on the front panel of lab view.
Reply With Quote
  #26   Spotlight this post!  
Unread 23-01-2014, 06:48
Greg McKaskle Greg McKaskle is offline
Registered User
FRC #2468 (Team NI & Appreciate)
 
Join Date: Apr 2008
Rookie Year: 2008
Location: Austin, TX
Posts: 4,748
Greg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond repute
Re: New Programming Core needs help with simple motor control

The battery voltage is measured using the first slot and the analog module. Until that is installed, the DS will not know the voltage.

The bigger cRIO and smaller cRIO are not that different. The processor in both is a 32 bit Freescale processor. The performance is slightly different due to cache size, the RAM was increased, and physical elements like the power connector, second enet port, and dip switches were removed.

The imaging tool can read the dip switches just to help diagnose broken ones -- happens more often than you'd think. For the 4-slot, it can also set them. The one begin set determines whether the serial port is used to output console print statements or used to communicate with another serial device, like a sensor.

As Alan said, simply pushing run on the VI will be the faster way to run your VI. Be sure that the VI contains the safety info. If you run a lower level VI, it will indeed run, but without established communications with the driver station, the outputs will be disabled and that safety feature can cause confusion.

There should be no issue running DS and any other development environment or tool. If you get an error, please post it so I can better understand what is going on.

To make further progress on getting your motors to run, I'm with Joe. Focus on getting the RSL LED to light up or blink. I'd start with the cable, but it could be the digital breakout board. If that doesn't fix it, work backwards and try another digital module. Also, remove the module in the cRIO and inspect that the backplane pins aren't bent and don't have debris shorting them. Also make sure that the module is fully inserted and the side clips engage. The imaging tool shows that it is recognized, so I doubt that there is an issue with engagement or pins.

Greg McKaskle
Reply With Quote
  #27   Spotlight this post!  
Unread 23-01-2014, 23:45
bharrison6 bharrison6 is offline
Registered User
FRC #3843
 
Join Date: Jan 2014
Location: Murray Ky
Posts: 37
bharrison6 is on a distinguished road
Re: New Programming Core needs help with simple motor control

Just wanted to let everyone know that the problem was the digital sidecar. Here is what happened. I had no RSL light for the test robot that we had set up. After verifying that the code was right I started swapping parts out. When I swapped out the digital sidecar I also swapped the power for it. The power cable was not properly installed so the sidecar did not get enough voltage. The test rig that I brought home to work on had the digital sidecar that I took off the test robot. That sidecar is bad and did not work. When I got back to school and worked on the test robot I simply adjusted the power cable in the breaker panel and the sidecar started working. I also replaced the side car on the test rig and it too started working. Very unlikely circumstances lead to a very troubling problem. Thanks to everyone who helped figure it out.
Reply With Quote
  #28   Spotlight this post!  
Unread 24-01-2014, 07:10
Greg McKaskle Greg McKaskle is offline
Registered User
FRC #2468 (Team NI & Appreciate)
 
Join Date: Apr 2008
Rookie Year: 2008
Location: Austin, TX
Posts: 4,748
Greg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond reputeGreg McKaskle has a reputation beyond repute
Re: New Programming Core needs help with simple motor control

Congrats, and thanks for the update.

Greg McKaskle
Reply With Quote
Reply


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -5. The time now is 04:28.

The Chief Delphi Forums are sponsored by Innovation First International, Inc.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi