Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Null pointer excepting when Estimating build #282

Open
rcarlsen opened this issue Aug 12, 2012 · 3 comments
Open

Null pointer excepting when Estimating build #282

rcarlsen opened this issue Aug 12, 2012 · 3 comments

Comments

@rcarlsen
Copy link

When using an older machines.xml (ie. not one of the new "The Replicator" machine definitions but one such as "Cupcake Basic") a NullPointer exception is thrown.

Console:
INFO: Estimating...
Exception in thread "Estimation Thread" java.lang.NullPointerException
at replicatorg.app.gcode.GCodeParser.buildGCodes(GCodeParser.java:654)
at replicatorg.app.gcode.GCodeParser.parse(GCodeParser.java:243)
at replicatorg.machine.Machine.estimate(Machine.java:497)
at replicatorg.app.ui.MainWindow$EstimationThread.run(MainWindow.java:2586)

It seems that something in the tool head parsing is failing:
if (driver.getMachine().getTool(tool).getMotorStepperAxis().name() == "B") {

Here is the tool entity which seems to fail:

<tool name="Mk5/6/6+" type="extruder" material="abs" floodcoolant="false" mistcoolant="false" fan="true" valve="false" collet="false" heater="true"  heatedplatform="true" motor_steps="3200" stepper_axis="a"/>

Modifying this entry to be more similar to the entity in "The Replicator" machine definition avoids the crash:

<tool name="Mk6+" model="Mk6" diameter="0.4" stepper_axis="a" index="0" type="extruder" motor="true" material="abs" fan="true" heater="true" heatedplatform="true" motor_steps="3200"/>
@stevenrose
Copy link

This is the error i see currently, can you tell me what to change in the machine definitions to get it running?

@rcarlsen
Copy link
Author

rcarlsen commented Jan 1, 2013

I modified the <tool ... /> entity to contain attributes similar to the MakerBot-provided Replicator machine definition. I don't have my configuration in front of me at the moment. Not sure what happened to my above comment—I had originally provided the examples. (Edit: fixed the above comment to display the code examples)

@bwbeach
Copy link

bwbeach commented Mar 16, 2014

I'm having the same problem. It looks like the code expects the extruder to be a stepper motor, and expects the stepper_axis to be set. I don't understand the system well enough, though, to know how to set it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants