text stringlengths 3 1.18M |
|---|
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
/**
* Write a description of class Enemigo here.
*
* @author (your name)
* @version (a version number or a date)
*/
public class SoldadoEspada extends Enemigo
{
//private GreenfootImage image;
int delay=0;
pr... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
/**
* Write a description of class Menu here.
*
* @author (your name)
* @version (a version number or a date)
*/
public class Play extends Boton
{
/**
* Act - do whatever the Menu wants to do. This method is call... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
/**
* Write a description of class Medalla here.
*
* @author (your name)
* @version (a version number or a date)
*/
public class Medalla extends Bono
{
private GreenfootImage [] medalla;
private int delay =0;
... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
import java.awt.Color;
import java.util.List;
/**
* An actor class that can display a scoreboard, using Greenfoot's
* UserInfo class.
*
* You typically use this by including some code into the world for when your game ends:
*
* <... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
/**
* Write a description of class Bono here.
*
* @author (your name)
* @version (a version number or a date)
*/
public class Arma extends Objeto
{
/**
* Act - do whatever the Bono wants to do. This method is cal... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
/**
* Write a description of class a here.
*
* @author (your name)
* @version (a version number or a date)
*/
public class Letrero extends Actor
{
/**
* Act - do whatever the letrero wants to do. This method is c... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
/**
* Write a description of class Sangre here.
*
* @author (your name)
* @version (a version number or a date)
*/
public class Sangre extends Actor
{
/**
* Act - do whatever the Sangre wants to do. This method i... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
/**
* Write a description of class Boton here.
*
* @author (your name)
* @version (a version number or a date)
*/
public class Boton extends Actor
{
/**
* Act - do whatever the Boton wants to do. This method is c... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
import java.util.*;
/**
* Write a description of class MetalWorld here.
*
* @author (your name)
* @version (a version number or a date)
*/
public class FlagWarWorld extends World
{
//The Hero is the legs, while the Bo... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
/**
* Write a description of class Mina here.
*
* @author (your name)
* @version (a version number or a date)
*/
public class Mina extends Objeto
{
/**
* Act - do whatever the Mina wants to do. This method is cal... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
/**
* Write a description of class Allen here.
*
* @author (your name)
* @version (a version number or a date)
*/
public class Allen extends Enemigo
{
/**
* Act - do whatever the Flecha wants to do. This method i... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
/**
* Write a description of class player here.
*
* @author (your name)
* @version (a version number or a date)
*/
public class Hero extends Player
{
//Movement variables
private double vSpeed = 0;
private ... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
//All the body does is go through an animation with info sent in from the Hero. Core code is in the Hero (legs).
//However, the animation is slightly different from the legs because there are more animation sequences possible.... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
/**
* Write a description of class Help here.
*
* @author (your name)
* @version (a version number or a date)
*/
public class Help extends Boton
{
/**
* Act - do whatever the Help wants to do. This method is call... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
/**
* Write a description of class space here.
*
* @author (your name)
* @version (a version number or a date)
*/
public class space extends Boton
{
/**
* Act - do whatever the space wants to do. This method is c... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
/**
* Write a description of class Explosion here.
*
* @author (your name)
* @version (a version number or a date)
*/
public class Explosion extends Actor
{
/**
* Act - do whatever the Explosion wants to do. This... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
/**
* Write a description of class Apple here.
*
* @author (your name)
* @version (a version number or a date)
*/
public class Apple extends Bono
{
/**
* Act - do whatever the Apple wants to do. This method is ca... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
/**
* Write a description of class PlayerShot here.
*
* @author (your name)
* @version (a version number or a date)
*/
public class PlayerShot extends Player
{
private int speed = 10; //Manipulate this number to change... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
/**
* Write a description of class C here.
*
* @author (your name)
* @version (a version number or a date)
*/
public class C extends Arma
{
/**
* Act - do whatever the C wants to do. This method is called wheneve... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
/**
* Write a description of class Soldado here.
*
* @author (your name)
* @version (a version number or a date)
*/
public class Soldado extends Enemigo
{
private GreenfootImage [] soldierRight = new GreenfootIma... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
/**
* Write a description of class Flecha here.
*
* @author (your name)
* @version (a version number or a date)
*/
public class Flecha extends Objeto
{
/**
* Act - do whatever the Flecha wants to do. This method ... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
/**
* Write a description of class Menu here.
*
* @author (your name)
* @version (a version number or a date)
*/
public class Name
extends Boton
{
/**
* Act - do whatever the Menu wants to do. This method is ca... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
/**
* Write a description of class misil here.
*
* @author (your name)
* @version (a version number or a date)
*/
public class misil extends Actor
{
/**
* Act - do whatever the misil wants to do. This method is... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
/**
* Write a description of class Objeto here.
*
* @author (your name)
* @version (a version number or a date)
*/
public class Objeto extends Actor
{
/**
* Act - do whatever the Objeto wants to do. This method i... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
/**
* Write a description of class Moneda here.
*
* @author (your name)
* @version (a version number or a date)
*/
public class Moneda extends Bono
{
/**
* Act - do whatever the Moneda wants to do. This method is... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
/**
* Write a description of class Player here.
*
* @author (your name)
* @version (a version number or a date)
*/
public class Player extends Actor
{
/**
* Act - do whatever the Player wants to do. This method i... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
/**
* Write a description of class Plataforma here.
*
* @author (your name)
* @version (a version number or a date)
*/
public class Plataforma extends Actor
{
/**
* Act - do whatever the Plataforma wants to do. T... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
/**
* Write a description of class Vida here.
*
* @author (your name)
* @version (a version number or a date)
*/
public class Vida extends Player
{
/**
* Act - do whatever the Vida wants to do. This method is cal... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
/**
* Write a description of class SoldadoBasooka here.
*
* @author (your name)
* @version (a version number or a date)
*/
public class SoldadoBasooka extends Enemigo
{
private GreenfootImage image;
int delay=0;
... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
/**
* Write a description of class Creditos here.
*
* @author (your name)
* @version (a version number or a date)
*/
public class Creditos extends Boton
{
/**
* Act - do whatever the Creditos wants to do. This me... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
/**
* Write a description of class G here.
*
* @author (your name)
* @version (a version number or a date)
*/
public class G extends Arma
{
/**
* Act - do whatever the G wants to do. This method is called wheneve... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
/**
* Write a description of class Score here.
*
* @author (your name)
* @version (a version number or a date)
*/
public class Score extends Boton
{
/**
* Act - do whatever the Score wants to do. This method is c... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
/**
* Representa la clase Win,
* la cual se usa para crear
* el Mensaje que has ganado.
*
* @author Carlos Bretherton.
* @version 01 de Mayo del 2012.
*/
public class Win extends Mensajes
{
/**
* Constructor d... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
import java.util.Random;
/**
* Representa la clase Pinvuino,
* la cual se usa para crea el
* objeto pinguino.
*
* @author Carlos Bretherton.
* @version 01 de Mayo del 2012.
*/
public class Pinguino extends Personajes
{
... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
import java.util.Random;
/**
* Representa la clase JackFrost,
* la cual se usa para crear
* los objetos JackFrost.
*
* @author Carlos Bretherton.
* @version 01 de Mayo del 2012.
*/
public class JackFrost extends Enemies
... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
/**
* Representa la clase Play,
* la cual se usa para crear
* el boton de Play Game.
*
* @author Carlos Bretherton.
* @version 01 de Mayo del 2012.
*/
public class Play extends Boton
{
/**
* Constructor de los... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
/**
* Representa la clase NLifes, la cual
* se usa para crear el letrero del
* número de vidas restantes.
*
* @author Carlos Bretherton.
* @version 01 de Mayo del 2012.
*/
public class NLifes extends Number
{
/**
... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
/**
* Representa la clase NTime, la cual
* se usa para crear el letrero del
* tiempo transcurrido en el juego.
*
* @author Carlos Bretherton.
* @version 01 de Mayo del 2012.
*/
public class NTime extends Number
{
/... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
/**
* Representa la clase NPoints, la cual
* se usa para crear el letrero del
* número de puntos adquiridos en el
* juego.
*
* @author Carlos Bretherton.
* @version 01 de Mayo del 2012.
*/
public class NPoints extends ... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
/**
* Representa la clase Lose,
* la cual se usa para crear
* el Mensaje de You Lose.
*
* @author Carlos Bretherton.
* @version 01 de Mayo del 2012.
*/
public class Lose extends Mensajes
{
/**
* Constructor de... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
import java.util.*;
/**
* Representa la clase Cubo,
* la cual se usa para crear
* los cubos ya sean movibles
* o fijos.
*
* @author Carlos Bretherton.
* @version 01 de Mayo del 2012.
*/
public class Cubo extends Person... |
import greenfoot.*;
/**
* Representa la clase Boton,
* la cual se usa para crear
* los botones de jugar, creditos
* y ayuda.
*
* @author Carlos Bretherton.
* @version 01 de Mayo del 2012
*/
public class Boton extends Mensajes
{
private GreenfootSound opcion;
protected GreenfootSound clic... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
import java.util.*;
/**
* Representa la clase Life,
* la cual se usa para crear
* el objeto vida.
*
* @author Carlos Bretherton.
* @version 01 de Mayo del 2012.
*/
public class Life extends Personajes
{
private Dat... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
import java.util.Random;
/**
* Representa la clase SnowBall,
* la cual se usa para crear
* los objetos SnowBall.
*
* @author Carlos Bretherton.
* @version 01 de Mayo del 2012.
*/
public class SnowBall extends Enemies
{
... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
/**
* Representa la clase Help,
* la cual se usa para crear
* el boton de Ayuda.
*
* @author Carlos Bretherton.
* @version 01 de Mayo del 2012
*/
public class Help extends Boton
{
/**
* Constructor de los obj... |
import greenfoot.*;
/**
* Representa la clase Mensajes, la cual
* se usa para crear los botones y
* letreros del juego.
*
* @author Carlos Bretherton.
* @version 01 de Mayo del 2012
*/
public class Mensajes extends Actor
{
private static final int ENTER = 0;
private static final int NIVEL... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
/**
* Representa la clase Nivel,
* la cual se usa para crear
* el Mensaje de Nivel.
*
* @author Carlos Bretherton.
* @version 01 de Mayo del 2012
*/
public class Nivel extends Mensajes
{
/**
* Constructor de ... |
import greenfoot.*;
/**
* Representa la clase Number, la cual
* se usa para crear los letreros de
* los números de las vidas, del tiempo
* y de los puntos.
*
* @author Carlos Bretherton.
* @version 01 de Mayo del 2012
*/
public abstract class Number extends Mensajes
{
protected GreenfootIma... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
import java.util.*;
/**
* Representa la clase Time,
* la cual se usa para crear
* el Mensaje de Time del juego.
*
* @author Carlos Bretherton.
* @version 01 de Mayo del 2012
*/
public class Time extends Mensajes
{
... |
import greenfoot.*;
import java.util.*;
/**
* Esta clase representa el mundo JackWorld
* desde la cual se crean todos los objetos
* del juego.
*
* @author Carlos Bretherton.
* @version 01 de Mayo del 2012
*/
public class JackWorld extends World
{
private static final int CUBOFIJO = 1;
pri... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
import java.util.Random;
/**
* Representa la clase SnowBox,
* la cual se usa para crear
* los objetos SnowBox.
*
* @author Carlos Bretherton.
* @version 01 de Mayo del 2012.
*/
public class SnowBox extends Enemies
{
... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
/**
* Representa la clase Enter,
* la cual se usa para crear
* un objeto esperando una
* respuesta para continuar.
*
* @author Carlos Bretherton.
* @version 01 de Mayo del 2012.
*/
public class Enter extends Mensajes
... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
import java.util.*;
/**
* Representa la clase Enemies,
* la cual se usa para crear los
* objetos de tipo enemigos.
*
* @author Carlos Bretherton.
* @version 01 de Mayo del 2012.
*/
public class Enemies extends Personajes... |
import greenfoot.*;
import java.util.Random;
/**
* Representa la clase Personajes,
* la cual se usa para crear
* los personajes del juego.
*
* @author Carlos Bretherton.
* @version 01 de Mayo del 2012.
*/
public class Personajes extends Actor
{
protected static final int CUBOFIJO = 1;
pr... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
/**
* Representa la clase Credits,
* la cual se usa para crear
* el boton de Creditos.
*
* @author Carlos Bretherton.
* @version 01 de Mayo del 2012
*/
public class Credits extends Boton
{
/**
* Constructor d... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
/**
* Representa la clase Lifes,
* la cual se usa para crear
* el Mensaje de Lifes.
*
* @author Carlos Bretherton.
* @version 01 de Mayo del 2012
*/
public class Lifes extends Mensajes
{
/**
* Constructor de ... |
import greenfoot.*; // (World, Actor, GreenfootImage, Greenfoot and MouseInfo)
/**
* Representa la clase Points,
* la cual se usa para crear
* el Mensaje de Points.
*
* @author Carlos Bretherton.
* @version 01 de Mayo del 2012
*/
public class Points extends Mensajes
{
/**
* Constructor ... |
package pl.polidea.sectionedlist;
import android.app.Activity;
import android.content.Context;
import android.os.Bundle;
import android.view.LayoutInflater;
import android.view.Menu;
import android.view.MenuInflater;
import android.view.MenuItem;
import android.view.View;
import android.view.ViewGroup;
import android.... |
/**
* Provides simple implementation of section list.
*/
package pl.polidea.sectionedlist; |
package pl.polidea.sectionedlist;
/**
* Item definition including the section.
*/
public class SectionListItem {
public Object item;
public String section;
public SectionListItem(final Object item, final String section) {
super();
this.item = item;
this.section = section;
}
... |
package pl.polidea.sectionedlist;
import android.content.Context;
import android.util.AttributeSet;
import android.view.View;
import android.view.ViewParent;
import android.widget.AbsListView;
import android.widget.AbsListView.OnScrollListener;
import android.widget.FrameLayout;
import android.widget.ListAdapter;
impo... |
package pl.polidea.sectionedlist;
import java.util.HashMap;
import java.util.LinkedHashMap;
import java.util.Map;
import java.util.Map.Entry;
import android.database.DataSetObserver;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.AdapterView;
import ... |
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package edu.wpi.first.wpilibj.defaultCode;
/**
*
* @author beto
*/
public class WheelSet {
public WheelVector FrontLeft = new WheelVector();
public WheelVector FrontRight = new WheelVector();
... |
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package edu.wpi.first.wpilibj.defaultCode;
/**
*
* @author beto
*
* Maintains a circular buffer and calculates the moving average
* of the last "n" entries, and where "n" is user specified
*
*
*/
public class A... |
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package edu.wpi.first.wpilibj.defaultCode;
import edu.wpi.first.wpilibj.Joystick;
import edu.wpi.first.wpilibj.Solenoid;
import edu.wpi.first.wpilibj.Victor;
/**
*
* @author Mark
*/
public class Lifter {
priv... |
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package edu.wpi.first.wpilibj.defaultCode;
import com.sun.squawk.util.MathUtils;
import edu.wpi.first.wpilibj.DriverStationLCD;
import edu.wpi.first.wpilibj.Joystick;
import java.util.Timer;
/**
*
* @author Mark
*/... |
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package edu.wpi.first.wpilibj.defaultCode;
import edu.wpi.first.wpilibj.DigitalInput;
import java.util.TimerTask;
/**
*
* @author Mark
*/
public class BeamSensor
{
int counter = 0;
int anothercounter = 0;
... |
package edu.wpi.first.wpilibj.defaultCode;
import edu.wpi.first.wpilibj.Joystick;
import edu.wpi.first.wpilibj.PIDController;
class PIDDebugUtil
{
public static void enterPIDDebug(PIDController controller, Joystick joystick, String name)
{
int selectionMade = -1;
double currValue = 0;
Sy... |
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package edu.wpi.first.wpilibj.defaultCode;
/**
*
* @author Mark
*/
public interface IThroughBeamCallback
{
boolean isTriggered(); //returns true if there is a break in the beam, false otherwise
boolean isKi... |
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package edu.wpi.first.wpilibj.defaultCode;
import edu.wpi.first.wpilibj.DriverStation;
import edu.wpi.first.wpilibj.DriverStationLCD;
import edu.wpi.first.wpilibj.Jaguar;
import edu.wpi.first.wpilibj.Joystick;
import e... |
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package edu.wpi.first.wpilibj.defaultCode;
import edu.wpi.first.wpilibj.Jaguar;
import edu.wpi.first.wpilibj.Joystick;
import edu.wpi.first.wpilibj.Watchdog;
/**
*
* @author Mark
*/
class TuneWheel
{
public sta... |
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package edu.wpi.first.wpilibj.defaultCode;
import edu.wpi.first.wpilibj.AnalogChannel;
import edu.wpi.first.wpilibj.PIDSource;
/**
*
* @author Mark
*/
public class REncoder implements PIDSource
{
AnalogChannel ... |
package edu.wpi.first.wpilibj.defaultCode;
import edu.wpi.first.wpilibj.Joystick;
import edu.wpi.first.wpilibj.DigitalInput;
import edu.wpi.first.wpilibj.DriverStationLCD;
import edu.wpi.first.wpilibj.Solenoid;
/**
*
* @author mark.oberle
*/
public class Kicker
{
private static Kicker instance = null;
pri... |
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package edu.wpi.first.wpilibj.defaultCode;
/**
*
* @author beto
*/
public class ResultantVector {
public double Speed; // magnitud of linear speed
public double Angle; // direction (angle) of linear t... |
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package edu.wpi.first.wpilibj.defaultCode;
import edu.wpi.first.wpilibj.Joystick;
/**
*
* @author Mark
*/
public class TargetTuner
{
public static int TARGET = 180;
public static void tuneTarget(Joystick j... |
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package edu.wpi.first.wpilibj.defaultCode;
/**
*
* @author beto
*/
public class WheelVector {
public double Speed; // speed of a single wheel
public double Angle; // direction (steering angle) for a si... |
/*----------------------------------------------------------------------------*/
/* Copyright (c) FIRST 2008. All Rights Reserved. */
/* Open Source Software - may be modified and shared by FRC teams. The code */
/* must be accompanied by the FIRST BSD license file in the root directory... |
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package edu.wpi.first.wpilibj.defaultCode;
import java.util.TimerTask;
import edu.wpi.first.wpilibj.Watchdog;
import com.sun.squawk.util.MathUtils;
import edu.wpi.first.wpilibj.DriverStation;
import edu.wpi.first.wpilib... |
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package edu.wpi.first.wpilibj.defaultCode;
/**
*
* @author robotics
*/
public interface IGingersnapCB {
void stopDrive();
void resumeDrive();
}
|
package edu.wpi.first.wpilibj.defaultCode;
import edu.wpi.first.wpilibj.Jaguar;
import edu.wpi.first.wpilibj.Joystick;
import edu.wpi.first.wpilibj.PIDController;
import edu.wpi.first.wpilibj.Victor;
import java.util.TimerTask;
/* Tasks
* Move to a given height (neutral, one, two three)
* Retract to neutral state
... |
package edu.wpi.first.wpilibj.defaultCode;
import edu.wpi.first.wpilibj.Joystick;
import java.util.TimerTask;
/*
* Tasks
* Manual close
* Auto close
* Release
*/
/**
*
* @author buttercream
*/
public class Grabber extends TimerTask
{
Joystick controller;
public Grabber(Joystick controller)
{
... |
/**
* Tasks
* Move to exact height (neutral, top, bottom)
* Self calibrate
*/
package edu.wpi.first.wpilibj.defaultCode;
import edu.wpi.first.wpilibj.*;
import java.util.TimerTask;
/**
*
* @author Steve
*/
public class Lifter extends TimerTask {
Joystick joyStick;
// 0 volts is on -- 5 volts is o... |
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package edu.wpi.first.wpilibj.defaultCode;
import edu.wpi.first.wpilibj.DigitalInput;
import edu.wpi.first.wpilibj.Encoder;
import edu.wpi.first.wpilibj.PIDSource;
import edu.wpi.first.wpilibj.SmartDashboard;
/**
*
... |
package edu.wpi.first.wpilibj.defaultCode;
import com.sun.squawk.util.MathUtils;
import edu.wpi.first.wpilibj.DriverStationLCD;
import edu.wpi.first.wpilibj.Joystick;
import edu.wpi.first.wpilibj.Watchdog;
/**
*
* @author Mark
*/
public class Utils
{
/**
* Gets the sign of a value
* @param value ... |
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package edu.wpi.first.wpilibj.defaultCode;
import edu.wpi.first.wpilibj.DigitalInput;
import edu.wpi.first.wpilibj.Encoder;
import edu.wpi.first.wpilibj.PIDSource;
import edu.wpi.first.wpilibj.SmartDashboard;
/**
*
... |
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package edu.wpi.first.wpilibj.defaultCode;
import edu.wpi.first.wpilibj.DriverStation;
import edu.wpi.first.wpilibj.DriverStationLCD;
import edu.wpi.first.wpilibj.Jaguar;
import edu.wpi.first.wpilibj.Joystick;
import e... |
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package edu.wpi.first.wpilibj.defaultCode;
import edu.wpi.first.wpilibj.AnalogChannel;
import edu.wpi.first.wpilibj.PIDSource;
/**
*
* @author robotics
*/
public class MagneticEnc implements PIDSource {
Analog... |
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package edu.wpi.first.wpilibj.defaultCode;
import edu.wpi.first.wpilibj.AnalogChannel;
/**
*
* @author SteveS
*/
public class AnalogLimitSwitch {
private AnalogChannel channel;
private boolean prevSwitchSt... |
package edu.wpi.first.wpilibj.defaultCode;
import java.util.TimerTask;
/**
*
* @author Wesley
*/
public class DriveEncoderMonitor extends TimerTask
{
DriveMtrEncoder encoder;
double[] buf;
int tail;
public static int BUF_SIZE = 50;
private static int NUM_AVG_ENTRIES = 5;
DriveEncoderMonit... |
package edu.wpi.first.wpilibj.defaultCode;
/**
*
* @author buttercream
*/
public class Constants
{
public static int DRIVE_MTR_TOOTH_COUNT = 42; //update
public static float WHEEL_CIRC = 12; //in inches, update
public static int DRIVE_MTR_SAMPLE_RATE = 20; //how often to sample the
... |
/*
* Tasks:
* Method that passes in desired angle
* Add PID loop to make wrist go to specific angle
*/
package edu.wpi.first.wpilibj.defaultCode;
import edu.wpi.first.wpilibj.Compressor;
import edu.wpi.first.wpilibj.DigitalOutput;
import edu.wpi.first.wpilibj.Jaguar;
import edu.wpi.first.wpilibj.Joystick;
import ... |
package edu.wpi.first.wpilibj.defaultCode;
import edu.wpi.first.wpilibj.Compressor;
import edu.wpi.first.wpilibj.DriverStation;
import edu.wpi.first.wpilibj.Joystick;
import java.util.Date;
import java.util.Timer;
import java.util.TimerTask;
/**
*
* @author Wesley
*/
public class Controller extends TimerTask imple... |
package edu.wpi.first.wpilibj.defaultCode;
import edu.wpi.first.wpilibj.AnalogChannel;
import edu.wpi.first.wpilibj.DigitalInput;
import edu.wpi.first.wpilibj.Joystick;
import edu.wpi.first.wpilibj.Solenoid;
import java.util.TimerTask;
/**
*
* @author buttercream
*/
public class MinibotDeploy extends TimerTask
{
... |
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package edu.wpi.first.wpilibj.defaultCode;
/**
*
* @author Wesley
*/
public class WheelState
{
public int FL_SIGN = 1;
public int FR_SIGN = 1;
public int RL_SIGN = 1;
public int RR_SIGN = 1;
}
|
/*----------------------------------------------------------------------------*/
/* Copyright (c) FIRST 2008. All Rights Reserved. */
/* Open Source Software - may be modified and shared by FRC teams. The code */
/* must be accompanied by the FIRST BSD license file in the root directory... |
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package edu.wpi.first.wpilibj.defaultCode;
/**
*
* @author robotics
*/
public class DriveMtrEncoder
{
int count = 0;
int currSign = 1;
int prevCount = 0;
int currCount = 0;
/**
* @return
... |
package edu.wpi.first.wpilibj.defaultCode;
import edu.wpi.first.wpilibj.AnalogChannel;
import edu.wpi.first.wpilibj.PIDSource;
/**
*
* @author buttercream
*/
public class AngularEncoder implements PIDSource
{
private AnalogChannel raw;
private int numTicks;
private double angleOffset = 0.0;
public... |
package edu.wpi.first.wpilibj.defaultCode;
import hotbots.HotPID;
import edu.wpi.first.wpilibj.*;
import java.util.TimerTask;
/**
*
* @author Wesley
*/
public class DriveTrain extends TimerTask
{
private DriveQuadEncoder flDriveMtrEnc;
private DriveQuadEncoder frDriveMtrEnc;
private Drive... |
/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/
package edu.wpi.first.wpilibj.defaultCode;
import edu.wpi.first.wpilibj.Counter;
import edu.wpi.first.wpilibj.CounterBase.EncodingType;
import edu.wpi.first.wpilibj.DigitalInput;
import edu.wpi.first.wpilibj.PIDSource;... |
package pl.polidea.asl;
import java.io.BufferedInputStream;
import java.io.File;
import java.io.FileNotFoundException;
import java.io.FileOutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.OutputStream;
import java.lang.reflect.Method;
import java.net.InetSocketAddress;
import java.ne... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.