Skip to content

Instantly share code, notes, and snippets.

View NotOctogonapus's full-sized avatar

NotOctogonapus

View GitHub Profile
@NotOctogonapus
NotOctogonapus / DefaultDhSolver.groovy
Created August 19, 2019 17:18
HephaestusWorkCell_copy copy of HephaestusWorkCell
import java.util.ArrayList;
import com.neuronrobotics.sdk.addons.kinematics.DHChain;
import com.neuronrobotics.sdk.addons.kinematics.DHLink;
import com.neuronrobotics.sdk.addons.kinematics.DhInverseSolver;
import com.neuronrobotics.sdk.addons.kinematics.math.TransformNR;
import com.neuronrobotics.sdk.common.Log;
import Jama.Matrix;
return new DhInverseSolver() {
return new Cube( 40,// X dimention
60,// Y dimention
80// Z dimention
).toCSG()// this converts from the geometry to an object we can work with
@NotOctogonapus
NotOctogonapus / DefaultDhSolver.groovy
Last active June 10, 2019 14:59
HephaestusWorkCell_copy copy of HephaestusWorkCell
import java.util.ArrayList;
import com.neuronrobotics.sdk.addons.kinematics.DHChain;
import com.neuronrobotics.sdk.addons.kinematics.DHLink;
import com.neuronrobotics.sdk.addons.kinematics.DhInverseSolver;
import com.neuronrobotics.sdk.addons.kinematics.math.TransformNR;
import com.neuronrobotics.sdk.common.Log;
import Jama.Matrix;
return new DhInverseSolver() {
@NotOctogonapus
NotOctogonapus / test_cad_engine.kts
Last active June 10, 2019 21:06 — forked from Octogonapus/test_cad_engine.kts
testing using the CadEngine from a kotlin script
/*
* This file is part of BowlerBuilder.
*
* BowlerBuilder is free software: you can redistribute it and/or modify
* it under the terms of the GNU Lesser General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* BowlerBuilder is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
import javafx.scene.transform.Affine;
import javafx.application.Platform;
def field = ScriptingEngine.gitScriptRun(
"https://github.com/WPIRoboticsEngineering/RBELabCustomParts.git", // git location of the library
"2002/2002 Field/2002 Field STL.STL" , // file to load
null
)
.rotx(-90)
.toXMin()
@NotOctogonapus
NotOctogonapus / DefaultDhSolver.groovy
Last active December 21, 2018 05:23
HephaestusWorkCell_copy copy of HephaestusWorkCell
import java.util.ArrayList;
import com.neuronrobotics.sdk.addons.kinematics.DHChain;
import com.neuronrobotics.sdk.addons.kinematics.DHLink;
import com.neuronrobotics.sdk.addons.kinematics.DhInverseSolver;
import com.neuronrobotics.sdk.addons.kinematics.math.TransformNR;
import com.neuronrobotics.sdk.common.Log;
import Jama.Matrix;
return new DhInverseSolver() {
@NotOctogonapus
NotOctogonapus / MoveLimb.groovy
Created December 13, 2018 21:14 — forked from madhephaestus/.gitignore
Move a limb attached to a MobileBase
import org.apache.commons.io.IOUtils;
import com.neuronrobotics.bowlerstudio.physics.*;
import com.neuronrobotics.bowlerstudio.threed.*;
def base = ScriptingEngine.gitScriptRun(
"https://gist.github.com/NotOctogonapus/c3fc39308a506d4cb1cd7297193c41e7",
"InputArmBase_copy.xml",
null
)
//base.appendages[0].setDesiredTaskSpaceTransform()
import com.neuronrobotics.sdk.addons.kinematics.DHParameterKinematics;
import com.neuronrobotics.sdk.addons.kinematics.math.RotationNR
import com.neuronrobotics.sdk.addons.kinematics.math.TransformNR;
import com.neuronrobotics.sdk.util.ThreadUtil;
import com.neuronrobotics.bowlerstudio.creature.CreatureLab;
import org.apache.commons.io.IOUtils;
//Create the kinematics model from the xml file describing the D-H compliant parameters.
String xmlContent = ScriptingEngine.codeFromGistID("2b0cff20ccee085c9c36","TrobotLinks.xml")[0];
@NotOctogonapus
NotOctogonapus / 3d window testing
Created December 12, 2018 14:26
3d window testing
def out = new Cube(5).toCSG()
out.name = "out cube"
return out
@NotOctogonapus
NotOctogonapus / test 5
Created December 10, 2018 17:42
test 5 d
test 5