Pwdr / Pwdr-Model-0.1

A powder substrate rapid prototyping machine
131 stars 68 forks source link

Problems getting the software running #22

Closed atticdweller closed 9 years ago

atticdweller commented 11 years ago

Hi Matt,

I'm in New York and working on building a Pwdr. I have all of the cut acrylic parts and hardware and electronics. I'm having trouble with your software. Whenever I go to connect to the arduino it crashes and gives me this error:

Exception in thread "Animation Thread" java.lang.ArrayIndexOutOfBoundsException: 1 at Pwdr_GUI_V0_3.startSerial(Pwdr_GUI_V0_3.java:501) at Pwdr_GUI_V0_3.mouseClicked(Pwdr_GUI_V0_3.java:1039) at processing.core.PApplet.handleMouseEvent(Unknown Source) at processing.core.PApplet.dequeueMouseEvents(Unknown Source) at processing.core.PApplet.handleDraw(Unknown Source) at processing.core.PApplet.run(Unknown Source) at java.lang.Thread.run(Thread.java:662)

Firmware version 2 is on the Arduino Mega.

I get a similar error when I try to slice any 3D model.

What version of Processing are you using?

Pwdr commented 11 years ago

The used version of Processing is 1.5.1. Can you connect to the Arduino using the Arduino software?

On Thursday, May 2, 2013 at 02:56 , atticdweller wrote:

Hi Matt, I'm in New York and working on building a Pwdr. I have all of the cut acrylic parts and hardware and electronics. I'm having trouble with your software. Whenever I go to connect to the arduino it crashes and gives me this error: Exception in thread "Animation Thread" java.lang.ArrayIndexOutOfBoundsException: 1 at Pwdr_GUI_V0_3.startSerial(Pwdr_GUI_V0_3.java:501) at Pwdr_GUI_V0_3.mouseClicked(Pwdr_GUI_V0_3.java:1039) at processing.core.PApplet.handleMouseEvent(Unknown Source) at processing.core.PApplet.dequeueMouseEvents(Unknown Source) at processing.core.PApplet.handleDraw(Unknown Source) at processing.core.PApplet.run(Unknown Source) at java.lang.Thread.run(Thread.java:662)
Firmware version 2 is on the Arduino Mega.
I get a similar error when I try to slice any 3D model.
What version of Processing are you using?

— Reply to this email directly or view it on GitHub (https://github.com/Pwdr/Pwdr-Model-0.1/issues/22).

atticdweller commented 11 years ago

I am using Processing 1.5.1. I am able to connect to the Arduino through processing and am now able to connect the Arduino to your software and manually control the axes of the printer. I am getting an error now when I load a model and then try to convert. When I press the convert button I get the error :

file://localhost/C:\Users\Mobi\Documents\Pwdr\teapot.stl Loading STL... File Loaded, Slicing: X: -6.304 - 6.304 Y: -3.931 - 3.931 Z: -2.4 - 3.472
Number of slices: 149 6 Exception in thread "Animation Thread" java.lang.ArrayIndexOutOfBoundsException: 2400 at Pwdr_GUI_V0_3.convertModel(Pwdr_GUI_V0_3.java:961) at Pwdr_GUI_V0_3.draw(Pwdr_GUI_V0_3.java:142) at processing.core.PApplet.handleDraw(Unknown Source) at processing.core.PApplet.run(Unknown Source) at java.lang.Thread.run(Thread.java:662)

It highlights the line in error as Line 74 in your convertModel class which reads: print_data[index] = byte(unbinary(LowerStr2));

Any idea whats going on?

Pwdr commented 11 years ago

No, this is a known bug. Some stl files don't work, but I don't know the reason.

On Saturday, May 4, 2013, atticdweller wrote:

I am using Processing 1.5.1. I am able to connect to the Arduino through processing and am now able to connect the Arduino to your software and manually control the axes of the printer. I am getting an error now when I load a model and then try to convert. When I press the convert button I get the error :

file://localhost/C:\Users\Mobi\Documents\Pwdr\teapot.stl Loading STL... File Loaded, Slicing: X: -6.304 - 6.304 Y: -3.931 - 3.931 Z: -2.4 - 3.472

Number of slices: 149 6 Exception in thread "Animation Thread" java.lang.ArrayIndexOutOfBoundsException: 2400 at Pwdr_GUI_V0_3.convertModel(Pwdr_GUI_V0_3.java:961) at Pwdr_GUI_V0_3.draw(Pwdr_GUI_V0_3.java:142) at processing.core.PApplet.handleDraw(Unknown Source) at processing.core.PApplet.run(Unknown Source) at java.lang.Thread.run(Thread.java:662)

It highlights the line in error as Line 74 in your convertModel class which reads: print_data[index] = byte(unbinary(LowerStr2));

Any idea whats going on?

— Reply to this email directly or view it on GitHubhttps://github.com/Pwdr/Pwdr-Model-0.1/issues/22#issuecomment-17423455 .

atticdweller commented 11 years ago

This is a file that you suggested to use on thingiverse. The Utah Teapot. I contacted you through thingiverse about it and you suggested that specific model as a model that works well. I'll upload a video in the next few days to show you what we are up to. Thanks for your help.

atticdweller commented 11 years ago

I found the source of the problem with that. Now I can get it to slice the Utah Teapot. The problem was your array print_data. On Line 28 of convertModel the layer size was only half the size needed to actually slice and get all the data. The line had to be changed to : byte[] print_data = new byte[layer_size*2];

I'm now working on putting the rest of the electronics together. I see in your two electronics drawings you have one with an SD card reader and one without it. In the file : Pwdr Protoshield + Stepper Drivers_schem.pdf you have no SD card and it seems that this is the correct wiring since if I connect the steppers to the indicated pins it will move them.

In the file : Pwdr-Circuit-0.1.pdf You have an SD card reader, which isn't in your parts list. The firmware also gives out serial commands that say that it can't initialize the SD card. What pins should I be connecting the SD card to?

Boreaz commented 11 years ago

I connect SD card using the method in this link http://arduino.cc/forum/index.php/topic,8314.0.html So, my scheme now looks like this printheadscheme

atticdweller commented 11 years ago

Thanks Boreaz!

I got my SD shield yesterday and tried out what you suggested. I got the examples working for the SD shield using the pins 50,51,52,53. When I use Pwdr Firmware V2_0 I still get the error "Initialization SD failed". I kind of expected this error because in the firmware those pins are used for the control the X motor.

Is there some other version of the firmware that your using?

Boreaz commented 11 years ago

Yes, I made ​​a few changes in the firmware for working with this scheme, try this version https://github.com/Boreaz/MyPrintfiles


От: atticdweller notifications@github.com Кому: Pwdr/Pwdr-Model-0.1 Pwdr-Model-0.1@noreply.github.com Копия: Michael boreaz73@yahoo.com Отправлено: вторник, 14 мая 2013 21:19 Тема: Re: [Pwdr-Model-0.1] Problems getting the software running (#22)

Thanks Boreaz! I got my SD shield yesterday and tried out what you suggested. I got the examples working for the SD shield using the pins 50,51,52,53. When I use Pwdr Firmware V2_0 I still get the error "Initialization SD failed". I kind of expected this error because in the firmware those pins are used for the control the X motor. Is there some other version of the firmware that your using? — Reply to this email directly or view it on GitHub.

Pwdr commented 11 years ago

You can just adjust the pins of the motors to the correct values for your board.

@Boreaz could you do a pull request?

On Wednesday, May 15, 2013 at 06:03 , Michael wrote:

Yes, I made ​​a few changes in the firmware for working with this scheme, try this version https://github.com/Boreaz/MyPrintfiles


От: atticdweller <notifications@github.com (mailto:notifications@github.com)> Кому: Pwdr/Pwdr-Model-0.1 <Pwdr-Model-0.1@noreply.github.com (mailto:Pwdr-Model-0.1@noreply.github.com)>
Копия: Michael <boreaz73@yahoo.com (mailto:boreaz73@yahoo.com)>
Отправлено: вторник, 14 мая 2013 21:19 Тема: Re: [Pwdr-Model-0.1] Problems getting the software running (#22)

Thanks Boreaz! I got my SD shield yesterday and tried out what you suggested. I got the examples working for the SD shield using the pins 50,51,52,53. When I use Pwdr Firmware V2_0 I still get the error "Initialization SD failed". I kind of expected this error because in the firmware those pins are used for the control the X motor.
Is there some other version of the firmware that your using?
— Reply to this email directly or view it on GitHub.

— Reply to this email directly or view it on GitHub (https://github.com/Pwdr/Pwdr-Model-0.1/issues/22#issuecomment-17919235).

atticdweller commented 11 years ago

Thanks for the help Boreaz. I'm up and running now. Now I have to finish putting together all the laser cut parts.

ckd28 commented 9 years ago

@atticdweller We are running into the same problem with the line print_data[index] = byte(unbinary(UpperStr2)); do you have any idea? we need to fix this problem as soon as possible. pLEASE HELP!

atticdweller commented 9 years ago

@ckd28

If I remember correctly I was having all of the problems from using the latest version of processing and Arduino. I remember I needed to use some version of Arduino before 1.0 but can't remember specifically the version. Good luck.

Pwdr commented 9 years ago

Please keep in mind to use Arduino IDE version 1.0. I'll investigate what needs to be changed for the newer versions.

On Wed, Oct 15, 2014 at 8:08 PM, atticdweller notifications@github.com wrote:

@ckd28 https://github.com/ckd28

If I remember correctly I was having all of the problems from using the latest version of processing and Arduino. I remember I needed to use some version of Arduino before 1.0 but can't remember specifically the version. Good luck.

— Reply to this email directly or view it on GitHub https://github.com/Pwdr/Pwdr-Model-0.1/issues/22#issuecomment-59249358.