Go to Post I guess we'll just have to resort back to our original plan of telepathy. - seg9585 [more]
Home
Go Back   Chief Delphi > Technical > Programming > Java
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Reply
 
Thread Tools Rate Thread Display Modes
  #1   Spotlight this post!  
Unread 20-01-2014, 23:15
sthreet's Avatar
sthreet sthreet is offline
Registered User
AKA: scott threet
FRC #4692
 
Join Date: Oct 2012
Rookie Year: 2012
Location: Toutle Lake
Posts: 84
sthreet is an unknown quantity at this point
[cRIO] Robot Drive... Output not updated often enough.

I got this error. According to another question on here this means that something caused the program to stop running.

No errors in code, no idea why it is happening.

The code I tested (Deleted all comments, hope it is readable.)

package edu.wpi.first.wpilibj.templates;


//import edu.wpi.first.wpilibj.Compressor;
//import edu.wpi.first.wpilibj.DigitalInput;
import edu.wpi.first.wpilibj.SimpleRobot;
import edu.wpi.first.wpilibj.RobotDrive;
import edu.wpi.first.wpilibj.Timer;
import edu.wpi.first.wpilibj.Joystick;
//import edu.wpi.first.wpilibj.Solenoid;
//import edu.wpi.first.wpilibj.Talon;
//import edu.wpi.first.wpilibj.Watchdog;

public class team4692robot extends SimpleRobot
{
RobotDrive drive = new RobotDrive(1, 2);
Joystick left = new Joystick(1);
Joystick right = new Joystick(2);

public void autonomous()
{
int autotimer=0;

while(true && isAutonomous() && isEnabled())
{
if(autotimer<100)
{
drive.tankDrive(.4, -.4);
}
else
{
drive.tankDrive(0, 0);
}

autotimer++;
Timer.delay(.005);
}
}

/**
* This function is called once each time the robot enters operator control.
*/
public void operatorControl()
{

while(true && isOperatorControl() && isEnabled())
{
double leftpow=left.getY(); double rightpow=right.getY();
double powermod=.25;
if(left.getTrigger())
{
powermod+=.25;
}
if(right.getTrigger())
{
powermod+=.5;
}
leftpow*=powermod; rightpow*=powermod;

drive.tankDrive(leftpow, rightpow);
Timer.delay(.005);

}
}

public void test()
{

}

}
__________________
Spoiler for gif:
Reply With Quote
  #2   Spotlight this post!  
Unread 20-01-2014, 23:51
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,561
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: [cRIO] Robot Drive... Output not updated often enough.

Use [ code] tags to make the code more readable.

Scroll up in the output window and see what is printed before the "Robot Drive... Output not updated often enough."

I don't see anything immediately wrong with the code. Is this the code you were running?
Reply With Quote
  #3   Spotlight this post!  
Unread 22-01-2014, 14:37
sthreet's Avatar
sthreet sthreet is offline
Registered User
AKA: scott threet
FRC #4692
 
Join Date: Oct 2012
Rookie Year: 2012
Location: Toutle Lake
Posts: 84
sthreet is an unknown quantity at this point
Re: [cRIO] Robot Drive... Output not updated often enough.

Sorry I didn't reply yesterday, internet was broken.

Spoiler for log after xyz default running messege:

[cRIO] task 0xca7f88 (worker.0) deleted: errno=0 (0) status=0 (0)

[cRIO] edu.wpi.first.wpilibj.networktables2.server.Server ConnectionAdapter@b entered connection state: GOT_CONNECTION_FROM_CLIENT

[cRIO] edu.wpi.first.wpilibj.networktables2.server.Server ConnectionAdapter@b entered connection state: CONNECTED_TO_CLIENT

[cRIO] Robot Drive... Output not updated often enough.

[cRIO] edu.wpi.first.wpilibj.networktables2.server.Server ConnectionAdapter@b entered connection state: CLIENT_DISCONNECTED

[cRIO] Close: edu.wpi.first.wpilibj.networktables2.server.Server ConnectionAdapter@b


Here is code: (deleted commented stuff.) (I'm fairly certain this is the same code that I posted, but I uncommented and recommented stuff so it may have changed. I was running this code. There is more complicated stuff commented out, but not to bad, just commented stuff out that wasn't actually connected to the digital sidecar/whatnot yet.)
Code:
package edu.wpi.first.wpilibj.templates;


import edu.wpi.first.wpilibj.SimpleRobot;
import edu.wpi.first.wpilibj.RobotDrive;
import edu.wpi.first.wpilibj.Timer;
import edu.wpi.first.wpilibj.Joystick;

public class team4692robot extends SimpleRobot 
{
    RobotDrive drive = new RobotDrive(1, 2);
    Joystick left = new Joystick(1);
    Joystick right = new Joystick(2);

    public void autonomous() 
    {
        int autotimer=0;
        
        while(true && isAutonomous() && isEnabled())
        {
            if(autotimer<100)
            {
                drive.tankDrive(.4, -.4);
            }
            else
            {
                drive.tankDrive(0, 0);
            }
            
            autotimer++;
            Timer.delay(.005);
        }
    }

    public void operatorControl() 
    {  
        while(true && isOperatorControl() && isEnabled())
        {
            double leftpow=left.getY(); double rightpow=right.getY();
            double powermod=.25;
            if(left.getTrigger())
            {
                powermod+=.25;
            }
            if(right.getTrigger())
            {
                powermod+=.5;
            }
            leftpow*=powermod; rightpow*=powermod;
            
            drive.tankDrive(leftpow, rightpow); 
            Timer.delay(.005);
        }
    }

    public void test() 
    {
    
    }
    
}
__________________
Spoiler for gif:
Reply With Quote
  #4   Spotlight this post!  
Unread 22-01-2014, 16:44
BradAMiller BradAMiller is offline
Registered User
AKA: Brad
#0190 ( Gompei and the Herd)
Team Role: Mentor
 
Join Date: Mar 2004
Location: Worcester, MA
Posts: 588
BradAMiller has a brilliant futureBradAMiller has a brilliant futureBradAMiller has a brilliant futureBradAMiller has a brilliant futureBradAMiller has a brilliant futureBradAMiller has a brilliant futureBradAMiller has a brilliant futureBradAMiller has a brilliant futureBradAMiller has a brilliant futureBradAMiller has a brilliant futureBradAMiller has a brilliant future
Re: [cRIO] Robot Drive... Output not updated often enough.

I don't see anything wrong with the code that would cause that message to be printed. RobotDrive requires the motors to be update every 0.1 seconds (expirationTime) before the robot safety code will stop them.

Make sure that the correct project is loaded in the robot.
__________________
Brad Miller
Robotics Resource Center
Worcester Polytechnic Institute
Reply With Quote
  #5   Spotlight this post!  
Unread 22-01-2014, 18:46
RufflesRidge RufflesRidge is offline
Registered User
no team
 
Join Date: Jan 2012
Location: USA
Posts: 989
RufflesRidge has a brilliant futureRufflesRidge has a brilliant futureRufflesRidge has a brilliant futureRufflesRidge has a brilliant futureRufflesRidge has a brilliant futureRufflesRidge has a brilliant futureRufflesRidge has a brilliant futureRufflesRidge has a brilliant futureRufflesRidge has a brilliant futureRufflesRidge has a brilliant futureRufflesRidge has a brilliant future
Re: [cRIO] Robot Drive... Output not updated often enough.

How many times are you seeing the message appear in the Diagnostics window? If it is constant/appearing many times it's something to worry about. If you see it happen only once or twice when the robot is transitioning between states I wouldn't worry about it.
Reply With Quote
  #6   Spotlight this post!  
Unread 23-01-2014, 16:19
sthreet's Avatar
sthreet sthreet is offline
Registered User
AKA: scott threet
FRC #4692
 
Join Date: Oct 2012
Rookie Year: 2012
Location: Toutle Lake
Posts: 84
sthreet is an unknown quantity at this point
Re: [cRIO] Robot Drive... Output not updated often enough.

Quote:
Originally Posted by RufflesRidge View Post
How many times are you seeing the message appear in the Diagnostics window? If it is constant/appearing many times it's something to worry about. If you see it happen only once or twice when the robot is transitioning between states I wouldn't worry about it.
Just once, but I don't know when, I can't see the window while driving it. (Don't know how to drive in developer.)

Quote:
Originally Posted by BradAMiller View Post
I don't see anything wrong with the that would cause that message to be printed. RobotDrive requires the motors to be update every 0.1 seconds (expirationTime) before the robot safety code will stop them.

Make sure that the correct project is loaded in the robot.
I am right click->running, pretty sure I am clicking on the right one.
__________________
Spoiler for gif:
Reply With Quote
  #7   Spotlight this post!  
Unread 23-01-2014, 16:25
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,561
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: [cRIO] Robot Drive... Output not updated often enough.

Quote:
Originally Posted by sthreet View Post
Just once, but I don't know when, I can't see the window while driving it. (Don't know how to drive in developer.)
Just run the driver station software.
Reply With Quote
  #8   Spotlight this post!  
Unread 23-01-2014, 19:14
nyaculak nyaculak is offline
Registered User
FRC #0053 (Area 53)
Team Role: Programmer
 
Join Date: Oct 2011
Rookie Year: 2011
Location: Maryland
Posts: 28
nyaculak will become famous soon enough
Re: [cRIO] Robot Drive... Output not updated often enough.

This is a problem created by the wpilib's safety system(s)...Actually, you should just kill them. Call this function in the robotInit().
Code:
private void killSafety() {
    drive.setSafetyEnabled(false);
    Watchdog.getInstance().kill();
}
__________________
2013 MUC DC 3rd Place, FRC DC Regional, FRC Chesapeake Regional
2012 FRC DC Regional, FRC Chesapeake Regional
ERHS Robotics Club
- FRC Team 53 "Area 53"
www.erhsroboticsclub.org
Reply With Quote
  #9   Spotlight this post!  
Unread 23-01-2014, 21:19
sthreet's Avatar
sthreet sthreet is offline
Registered User
AKA: scott threet
FRC #4692
 
Join Date: Oct 2012
Rookie Year: 2012
Location: Toutle Lake
Posts: 84
sthreet is an unknown quantity at this point
Question Re: [cRIO] Robot Drive... Output not updated often enough.

Quote:
Originally Posted by nyaculak View Post
This is a problem created by the wpilib's safety system(s)...Actually, you should just kill them. Call this function in the robotInit().
Code:
private void killSafety() {
    drive.setSafetyEnabled(false);
    Watchdog.getInstance().kill();
}
So I added this to my code:
Code:
    public void robotInit()
    {
        drive.setSafetyEnabled(false);
        Watchdog.getInstance().kill();
    }
Changed nothing, except the timeout messege didn't display

EDIT: We appear to be having ping problems. Robot Radio and Crio are fine. other stuff is bad. (forgot what exactly was bad, but their were two things.)

EDIT: Found this error:
Warning <Code> 44002 occurred at Ping Results: link-bad, DS radio(.4)-bad, robot radio(.1)-bad, cRIO(.2)-bad, FMS-bad Driver Station
We are attempting to switch out digital sidecars to see if that is the problem.
__________________
Spoiler for gif:

Last edited by sthreet : 23-01-2014 at 22:45.
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 11:31.

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