MarginallyClever / Makelangelo-software

Software for plotters - especially the wall-hanging polargraph also called Makelangelo.
http://www.marginallyclever.com/
GNU General Public License v2.0
349 stars 155 forks source link

DrawbotGUI will not start on OSX or Windows #4

Closed maudette01432 closed 11 years ago

maudette01432 commented 12 years ago

I tried on both windows and osx and they both fail with similar exceptions. Occasionally (haven't figured out why) on OSX I can get it to start running with sudo. When started jogging and spooling seem to work but when I go to DRAW a design it just hangs. This is running the experimental branch.

WARNING: RXTX Version mismatch Jar version = RXTX-2.2pre1 native lib Version = RXTX-2.2pre2 Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException at DrawbotGUI.UpdateRecentFiles(DrawbotGUI.java:573) at DrawbotGUI.OpenFile(DrawbotGUI.java:547) at DrawbotGUI.OpenFileOnDemand(DrawbotGUI.java:620) at DrawbotGUI.CreateContentPane(DrawbotGUI.java:1313) at DrawbotGUI.CreateAndShowGUI(DrawbotGUI.java:1337) at DrawbotGUI.access$2(DrawbotGUI.java:1329) at DrawbotGUI$4.run(DrawbotGUI.java:1349) at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:209) at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:682) at java.awt.EventQueue.access$000(EventQueue.java:85) at java.awt.EventQueue$1.run(EventQueue.java:643) at java.awt.EventQueue$1.run(EventQueue.java:641) at java.security.AccessController.doPrivileged(Native Method) at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:87) at java.awt.EventQueue.dispatchEvent(EventQueue.java:652) at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:296) at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:211) at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:201) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:196) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:188) at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)

i-make-robots commented 12 years ago

Ok... that null pointer exception shouldn't be possible. I'll see if I can rework the offending area to be more robust.

maudette01432 commented 12 years ago

thanks, I'm wondering if it's 64-bit vs 32-bit. If you think you get it fixed let me know and I'll give it a whirl.

            -Mike

On Aug 11, 2012, at 1:37 PM, Dan Royer notifications@github.com wrote:

Ok... that null pointer exception shouldn't be possible. I'll see if I can rework the offending area to be more robust.

— Reply to this email directly or view it on GitHub.

maudette01432 commented 12 years ago

OSX and Windows - latest experimental branch:

WINDOWS: C:\Users\maudette\Desktop\DrawBot-fb88927[1]\i-make-robots-DrawBot-fb88927\java>"C:\Program Files (x86)\Java\jre7\bin\ja va" -classpath RXTXcomm.jar -Djava.library.path=classes\rxtxnative\Windows\i3680mingw32 -jar DrawbotGUI.jar java.lang.UnsatisfiedLinkError: no rxtxSerial in java.library.path thrown while loading gnu.io.RXTXCommDriver Exception in thread "AWT-EventQueue-0" java.lang.UnsatisfiedLinkError: no rxtxSerial in java.library.path at java.lang.ClassLoader.loadLibrary(Unknown Source) at java.lang.Runtime.loadLibrary0(Unknown Source) at java.lang.System.loadLibrary(Unknown Source) at gnu.io.CommPortIdentifier.(CommPortIdentifier.java:123) at DrawbotGUI.ListSerialPorts(DrawbotGUI.java:356) at DrawbotGUI.UpdateMenuBar(DrawbotGUI.java:1196) at DrawbotGUI.CreateMenuBar(DrawbotGUI.java:1139) at DrawbotGUI.CreateAndShowGUI(DrawbotGUI.java:1358) at DrawbotGUI.access$19(DrawbotGUI.java:1351) at DrawbotGUI$5.run(DrawbotGUI.java:1371) at java.awt.event.InvocationEvent.dispatch(Unknown Source) at java.awt.EventQueue.dispatchEventImpl(Unknown Source) at java.awt.EventQueue.access$000(Unknown Source) at java.awt.EventQueue$3.run(Unknown Source) at java.awt.EventQueue$3.run(Unknown Source) at java.security.AccessController.doPrivileged(Native Method) at java.security.ProtectionDomain$1.doIntersectionPrivilege(Unknown Source) at java.awt.EventQueue.dispatchEvent(Unknown Source) at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source) at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source) at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source) at java.awt.EventDispatchThread.pumpEvents(Unknown Source) at java.awt.EventDispatchThread.pumpEvents(Unknown Source) at java.awt.EventDispatchThread.run(Unknown Source)

C:\Users\maudette\Desktop\DrawBot-fb88927[1]\i-make-robots-DrawBot-fb88927\java>

OSX:

Mikes-iMac:java maudette01432$ sudo ./osx_runme.sh Password: WARNING: RXTX Version mismatch Jar version = RXTX-2.2pre1 native lib Version = RXTX-2.2pre2 Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException at DrawbotGUI.UpdateRecentFiles(DrawbotGUI.java:568) at DrawbotGUI.LoadGCode(DrawbotGUI.java:542) at DrawbotGUI.OpenFileOnDemand(DrawbotGUI.java:617) at DrawbotGUI.CreateContentPane(DrawbotGUI.java:1338) at DrawbotGUI.CreateAndShowGUI(DrawbotGUI.java:1359) at DrawbotGUI.access$19(DrawbotGUI.java:1351) at DrawbotGUI$5.run(DrawbotGUI.java:1371) at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:209) at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:682) at java.awt.EventQueue.access$000(EventQueue.java:85) at java.awt.EventQueue$1.run(EventQueue.java:643) at java.awt.EventQueue$1.run(EventQueue.java:641) at java.security.AccessController.doPrivileged(Native Method) at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:87) at java.awt.EventQueue.dispatchEvent(EventQueue.java:652) at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:296) at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:211) at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:201) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:196) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:188) at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)

i-make-robots commented 12 years ago

This might help: http://www.cloudhopper.com/opensource/rxtx/ the 64-bit version of RXTX.

On Sat, Aug 11, 2012 at 4:17 PM, maudette01432 notifications@github.comwrote:

OSX and Windows - latest experimental branch:

WINDOWS: C:\Users\maudette\Desktop\DrawBot-fb88927[1]\i-make-robots-DrawBot-fb88927\java>"C:\Program Files (x86)\Java\jre7\bin\ja va" -classpath RXTXcomm.jar -Djava.library.path=classes\rxtxnative\Windows\i3680mingw32 -jar DrawbotGUI.jar java.lang.UnsatisfiedLinkError: no rxtxSerial in java.library.path thrown while loading gnu.io.RXTXCommDriver Exception in thread "AWT-EventQueue-0" java.lang.UnsatisfiedLinkError: no rxtxSerial in java.library.path at java.lang.ClassLoader.loadLibrary(Unknown Source) at java.lang.Runtime.loadLibrary0(Unknown Source) at java.lang.System.loadLibrary(Unknown Source) at gnu.io.CommPortIdentifier.(CommPortIdentifier.java:123) at DrawbotGUI.ListSerialPorts(DrawbotGUI.java:356) at DrawbotGUI.UpdateMenuBar(DrawbotGUI.java:1196) at DrawbotGUI.CreateMenuBar(DrawbotGUI.java:1139) at DrawbotGUI.CreateAndShowGUI(DrawbotGUI.java:1358) at DrawbotGUI.access$19(DrawbotGUI.java:1351) at DrawbotGUI$5.run(DrawbotGUI.java:1371) at java.awt.event.InvocationEvent.dispatch(Unknown Source) at java.awt.EventQueue.dispatchEventImpl(Unknown Source) at java.awt.EventQueue.access$000(Unknown Source) at java.awt.EventQueue$3.run(Unknown Source) at java.awt.EventQueue$3.run(Unknown Source) at java.security.AccessController.doPrivileged(Native Method) at java.security.ProtectionDomain$1.doIntersectionPrivilege(Unknown Source) at java.awt.EventQueue.dispatchEvent(Unknown Source) at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source) at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source) at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source) at java.awt.EventDispatchThread.pumpEvents(Unknown Source) at java.awt.EventDispatchThread.pumpEvents(Unknown Source) at java.awt.EventDispatchThread.run(Unknown Source)

C:\Users\maudette\Desktop\DrawBot-fb88927[1]\i-make-robots-DrawBot-fb88927\java>

OSX:

Mikes-iMac:java maudette01432$ sudo ./osx_runme.sh Password:

WARNING: RXTX Version mismatch Jar version = RXTX-2.2pre1 native lib Version = RXTX-2.2pre2 Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException at DrawbotGUI.UpdateRecentFiles(DrawbotGUI.java:568) at DrawbotGUI.LoadGCode(DrawbotGUI.java:542) at DrawbotGUI.OpenFileOnDemand(DrawbotGUI.java:617) at DrawbotGUI.CreateContentPane(DrawbotGUI.java:1338) at DrawbotGUI.CreateAndShowGUI(DrawbotGUI.java:1359) at DrawbotGUI.access$19(DrawbotGUI.java:1351) at DrawbotGUI$5.run(DrawbotGUI.java:1371)

at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:209) at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:682) at java.awt.EventQueue.access$000(EventQueue.java:85) at java.awt.EventQueue$1.run(EventQueue.java:643) at java.awt.EventQueue$1.run(EventQueue.java:641) at java.security.AccessController.doPrivileged(Native Method) at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:87) at java.awt.EventQueue.dispatchEvent(EventQueue.java:652) at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:296) at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:211) at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:201) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:196) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:188) at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)

— Reply to this email directly or view it on GitHubhttps://github.com/i-make-robots/DrawBot/issues/4#issuecomment-7671200.

Dan Royer, Marginally Clever Software http://www.marginallyclever.com/ - Robotics & Website Management Solutions. Ph: +1.604.916.2281

maudette01432 commented 12 years ago

It might. But there is no osx binary. I'll see if I can build one without having to build an entire tool chain.

I stumbled on another one too...

Sent from my iPhone

On Aug 11, 2012, at 7:31 PM, Dan Royer notifications@github.com wrote:

This might help: http://www.cloudhopper.com/opensource/rxtx/ the 64-bit version of RXTX.

On Sat, Aug 11, 2012 at 4:17 PM, maudette01432 notifications@github.comwrote:

OSX and Windows - latest experimental branch:

WINDOWS: C:\Users\maudette\Desktop\DrawBot-fb88927[1]\i-make-robots-DrawBot-fb88927\java>"C:\Program Files (x86)\Java\jre7\bin\ja va" -classpath RXTXcomm.jar -Djava.library.path=classes\rxtxnative\Windows\i3680mingw32 -jar DrawbotGUI.jar java.lang.UnsatisfiedLinkError: no rxtxSerial in java.library.path thrown while loading gnu.io.RXTXCommDriver Exception in thread "AWT-EventQueue-0" java.lang.UnsatisfiedLinkError: no rxtxSerial in java.library.path at java.lang.ClassLoader.loadLibrary(Unknown Source) at java.lang.Runtime.loadLibrary0(Unknown Source) at java.lang.System.loadLibrary(Unknown Source) at gnu.io.CommPortIdentifier.(CommPortIdentifier.java:123) at DrawbotGUI.ListSerialPorts(DrawbotGUI.java:356) at DrawbotGUI.UpdateMenuBar(DrawbotGUI.java:1196) at DrawbotGUI.CreateMenuBar(DrawbotGUI.java:1139) at DrawbotGUI.CreateAndShowGUI(DrawbotGUI.java:1358) at DrawbotGUI.access$19(DrawbotGUI.java:1351) at DrawbotGUI$5.run(DrawbotGUI.java:1371) at java.awt.event.InvocationEvent.dispatch(Unknown Source) at java.awt.EventQueue.dispatchEventImpl(Unknown Source) at java.awt.EventQueue.access$000(Unknown Source) at java.awt.EventQueue$3.run(Unknown Source) at java.awt.EventQueue$3.run(Unknown Source) at java.security.AccessController.doPrivileged(Native Method) at java.security.ProtectionDomain$1.doIntersectionPrivilege(Unknown Source) at java.awt.EventQueue.dispatchEvent(Unknown Source) at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source) at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source) at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source) at java.awt.EventDispatchThread.pumpEvents(Unknown Source) at java.awt.EventDispatchThread.pumpEvents(Unknown Source) at java.awt.EventDispatchThread.run(Unknown Source)

C:\Users\maudette\Desktop\DrawBot-fb88927[1]\i-make-robots-DrawBot-fb88927\java>

OSX:

Mikes-iMac:java maudette01432$ sudo ./osx_runme.sh Password:

WARNING: RXTX Version mismatch Jar version = RXTX-2.2pre1 native lib Version = RXTX-2.2pre2 Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException at DrawbotGUI.UpdateRecentFiles(DrawbotGUI.java:568) at DrawbotGUI.LoadGCode(DrawbotGUI.java:542) at DrawbotGUI.OpenFileOnDemand(DrawbotGUI.java:617) at DrawbotGUI.CreateContentPane(DrawbotGUI.java:1338) at DrawbotGUI.CreateAndShowGUI(DrawbotGUI.java:1359) at DrawbotGUI.access$19(DrawbotGUI.java:1351) at DrawbotGUI$5.run(DrawbotGUI.java:1371)

at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:209) at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:682) at java.awt.EventQueue.access$000(EventQueue.java:85) at java.awt.EventQueue$1.run(EventQueue.java:643) at java.awt.EventQueue$1.run(EventQueue.java:641) at java.security.AccessController.doPrivileged(Native Method) at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:87) at java.awt.EventQueue.dispatchEvent(EventQueue.java:652) at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:296) at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:211) at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:201) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:196) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:188) at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)

— Reply to this email directly or view it on GitHubhttps://github.com/i-make-robots/DrawBot/issues/4#issuecomment-7671200.

Dan Royer, Marginally Clever Software http://www.marginallyclever.com/ - Robotics & Website Management Solutions. Ph: +1.604.916.2281* * — Reply to this email directly or view it on GitHub.

maudette01432 commented 12 years ago

Latest code - before I hit the sack.

WARNING: RXTX Version mismatch Jar version = RXTX-2.2pre1 native lib Version = RXTX-2.2pre2 Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException at DrawbotGUI.UpdateRecentFiles(DrawbotGUI.java:593) at DrawbotGUI.OpenFile(DrawbotGUI.java:565) at DrawbotGUI.OpenFileOnDemand(DrawbotGUI.java:646) at DrawbotGUI.CreateContentPane(DrawbotGUI.java:1359) at DrawbotGUI.CreateAndShowGUI(DrawbotGUI.java:1385) at DrawbotGUI.access$0(DrawbotGUI.java:1377) at DrawbotGUI$2.run(DrawbotGUI.java:1399) at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:209) at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:682) at java.awt.EventQueue.access$000(EventQueue.java:85) at java.awt.EventQueue$1.run(EventQueue.java:643) at java.awt.EventQueue$1.run(EventQueue.java:641) at java.security.AccessController.doPrivileged(Native Method) at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:87) at java.awt.EventQueue.dispatchEvent(EventQueue.java:652) at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:296) at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:211) at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:201) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:196) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:188) at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)

maudette01432 commented 12 years ago

Here's the windows trace from the most recent version: "C:\Program Files (x86)\Java\jre7\bin\java" -classpath .\RXTXcomm.jar -Djava.library.path=classes\rxtxnative\Windows\i3680mingw32 -jar DrawbotGUI.jar

java.lang.UnsatisfiedLinkError: no rxtxSerial in java.library.path thrown while loading gnu.io.RXTXCommDriver Exception in thread "AWT-EventQueue-0" java.lang.UnsatisfiedLinkError: no rxtxSerial in java.library.path at java.lang.ClassLoader.loadLibrary(Unknown Source) at java.lang.Runtime.loadLibrary0(Unknown Source) at java.lang.System.loadLibrary(Unknown Source) at gnu.io.CommPortIdentifier.(CommPortIdentifier.java:123) at DrawbotGUI.ListSerialPorts(DrawbotGUI.java:356) at DrawbotGUI.UpdateMenuBar(DrawbotGUI.java:1196) at DrawbotGUI.CreateMenuBar(DrawbotGUI.java:1139) at DrawbotGUI.CreateAndShowGUI(DrawbotGUI.java:1358) at DrawbotGUI.access$19(DrawbotGUI.java:1351) at DrawbotGUI$5.run(DrawbotGUI.java:1371) at java.awt.event.InvocationEvent.dispatch(Unknown Source) at java.awt.EventQueue.dispatchEventImpl(Unknown Source) at java.awt.EventQueue.access$000(Unknown Source) at java.awt.EventQueue$3.run(Unknown Source) at java.awt.EventQueue$3.run(Unknown Source) at java.security.AccessController.doPrivileged(Native Method) at java.security.ProtectionDomain$1.doIntersectionPrivilege(Unknown Source) at java.awt.EventQueue.dispatchEvent(Unknown Source) at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source) at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source) at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source) at java.awt.EventDispatchThread.pumpEvents(Unknown Source) at java.awt.EventDispatchThread.pumpEvents(Unknown Source) at java.awt.EventDispatchThread.run(Unknown Source)

maudette01432 commented 12 years ago

I've been poking around the code and checked to make sure Java7 was installed and up to date. I even forced the path to the java 7 binary and no change. I think the issue in the code is related to updating the recent file list and/or loading the preferences through the API. I'm not sure if there is a tool for browsing the Java preference stored in the system to make sure they are good. i.e. when it retrieves the list of recent files and they aren't defined.

i-make-robots commented 12 years ago

When they aren't defined they are set to empty strings. It shouldn't e barfing on that line. Maybe windows is paranoid and isn't giving java access to prefs?

(adventuring)

On 2012-08-15, at 5:42, maudette01432 notifications@github.com wrote:

I've been poking around the code and checked to make sure Java7 was installed and up to date. I even forced the path to the java 7 binary and no change. I think the issue in the code is related to updating the recent file list and/or loading the preferences through the API. I'm not sure if there is a tool for browsing the Java preference stored in the system to make sure they are good. i.e. when it retrieves the list of recent files and they aren't defined.

— Reply to this email directly or view it on GitHub.

maudette01432 commented 12 years ago

Yeah that part of the code looks good - the part I was wondering about was the portion hat "deletes" the recents…if I had say 5 recents and all the files were removed is it possible for the delete portion to leave an empty array/null pointer?

If I knew how the java was being compiled I'd try a few things my self - I do have the most recent Oracle JDK installed on my system. Do you have a makefile or script you are using to build it? Java looks pretty straight forward as a language goes - even though I've never wrote a program in it.

Oracle also has a doc up on their website for packaging as a .app…If I could get it to start I was going to try that.

                -Mike

On Aug 15, 2012, at 10:39 AM, Dan Royer notifications@github.com wrote:

When they aren't defined they are set to empty strings. It shouldn't e barfing on that line. Maybe windows is paranoid and isn't giving java access to prefs?

(adventuring)

On 2012-08-15, at 5:42, maudette01432 notifications@github.com wrote:

I've been poking around the code and checked to make sure Java7 was installed and up to date. I even forced the path to the java 7 binary and no change. I think the issue in the code is related to updating the recent file list and/or loading the preferences through the API. I'm not sure if there is a tool for browsing the Java preference stored in the system to make sure they are good. i.e. when it retrieves the list of recent files and they aren't defined.

— Reply to this email directly or view it on GitHub.

— Reply to this email directly or view it on GitHub.

i-make-robots commented 12 years ago

I use eclipse. For some reason eclipse doesn't store the project files with the source so it doesn't end up in the hit repository. V annoying.

(adventuring)

On 2012-08-15, at 7:57, maudette01432 notifications@github.com wrote:

Yeah that part of the code looks good - the part I was wondering about was the portion hat "deletes" the recents…if I had say 5 recents and all the files were removed is it possible for the delete portion to leave an empty array/null pointer?

If I knew how the java was being compiled I'd try a few things my self - I do have the most recent Oracle JDK installed on my system. Do you have a makefile or script you are using to build it? Java looks pretty straight forward as a language goes - even though I've never wrote a program in it.

Oracle also has a doc up on their website for packaging as a .app…If I could get it to start I was going to try that.

-Mike

On Aug 15, 2012, at 10:39 AM, Dan Royer notifications@github.com wrote:

When they aren't defined they are set to empty strings. It shouldn't e barfing on that line. Maybe windows is paranoid and isn't giving java access to prefs?

(adventuring)

On 2012-08-15, at 5:42, maudette01432 notifications@github.com wrote:

I've been poking around the code and checked to make sure Java7 was installed and up to date. I even forced the path to the java 7 binary and no change. I think the issue in the code is related to updating the recent file list and/or loading the preferences through the API. I'm not sure if there is a tool for browsing the Java preference stored in the system to make sure they are good. i.e. when it retrieves the list of recent files and they aren't defined.

— Reply to this email directly or view it on GitHub.

— Reply to this email directly or view it on GitHub.

— Reply to this email directly or view it on GitHub.

maudette01432 commented 12 years ago

Dan,

It's definitely related to the build environment - your build will not run on my windows or OSX machine. I downloaded the latest Oracle JDK and installed it and got hacking a little bit to see if I could get an executable to start.

I was able to build the "master' and experimental branch from the command line and got it to start reliably every single time on OS X and windows. It took a while - since I don't normally code in java but I did manage to get it to build (and into a single jar file + the serial binaries - and it doesn't rely on the Eclipse jar-in-jar classes either) using the following script:

!/bin/bash --verbose

rm -rf *.class rm -rf gnu

rm -rf MANIFEST.MF META-INF rm -rf RXTXcomm.jar

cp ../RXTXcomm.jar .

javac -g -sourcepath . -classpath ./classes Filter.java javac -g -sourcepath . -classpath ./classes Filter_BlackAndWhite.java javac -g -sourcepath . -classpath ./classes Filter_DitherFloydSteinberg.java javac -g -sourcepath . -classpath ./classes Filter_Resize.java javac -g -sourcepath . -classpath ./classes Point2D.java javac -g -sourcepath . -classpath ./classes Point3D.java javac -g -sourcepath . -classpath ./RXTXcomm.jar:./ -extdirs rxtxnative/Mac_OS_X Filter_TSPCodeGenerator.java

javac -g -sourcepath . -classpath ./classes StatusBar.java javac -g -sourcepath . -classpath ./classes DrawPanel.java javac -g -sourcepath . -classpath ./RXTXcomm.jar:./ -extdirs rxtxnative/Mac_OS_X DrawbotGUI.java

echo "Manifest-version: 1.0" > MANIFEST.MF echo "Main-Class: DrawbotGui" >> MANIFEST.MF

jar xvf RXTXcomm.jar rm -rf META-INF

jar -cvfe DrawbotGUI.jar DrawbotGUI *.class rxtxnative gnu

TO START Issue:

java -Djava.library.path="./rxtxnative/Mac_OS_X" -jar DrawbotGUI.jar

I still get the version mismatch warning on the command line: Mikes-iMac:src maudette01432$ java -Djava.library.path="./rxtxnative/Mac_OS_X" -jar DrawbotGUI.jar WARNING: RXTX Version mismatch Jar version = RXTX-2.2pre1 native lib Version = RXTX-2.2pre2

but the rest of the GUI seems to run and start reliable. In fact I was able to get it to connect, jog, any "gasp" draw a complete picture without hanging. (success!!!!) I also was able to start the app on Windows - although I didn't test any of the functions with it yet.

There does however seem to be an issue with preferences and general file IO. I am building a small list of bugs and will see if I can fix some of them. Any thoughts on storing the "machine limits" and "paper size" on the machine and using Mcodes to set and retrieve them like most of the 3d printers do? It's not like any user is ever - in a reasonable life time be able to write the eeprom so many times it will fail. I might be able to modify the Arduino code to do this pretty trivially and then possibly the Java code once I get my head wrapped around it.

I have attached my JAR if you want to give it a go. It's built with JAVA 7.

-Mike

On Aug 15, 2012, at 12:11 PM, Dan Royer notifications@github.com wrote:

I use eclipse. For some reason eclipse doesn't store the project files with the source so it doesn't end up in the hit repository. V annoying.

(adventuring)

On 2012-08-15, at 7:57, maudette01432 notifications@github.com wrote:

Yeah that part of the code looks good - the part I was wondering about was the portion hat "deletes" the recents…if I had say 5 recents and all the files were removed is it possible for the delete portion to leave an empty array/null pointer?

If I knew how the java was being compiled I'd try a few things my self - I do have the most recent Oracle JDK installed on my system. Do you have a makefile or script you are using to build it? Java looks pretty straight forward as a language goes - even though I've never wrote a program in it.

Oracle also has a doc up on their website for packaging as a .app…If I could get it to start I was going to try that.

-Mike

On Aug 15, 2012, at 10:39 AM, Dan Royer notifications@github.com wrote:

When they aren't defined they are set to empty strings. It shouldn't e barfing on that line. Maybe windows is paranoid and isn't giving java access to prefs?

(adventuring)

On 2012-08-15, at 5:42, maudette01432 notifications@github.com wrote:

I've been poking around the code and checked to make sure Java7 was installed and up to date. I even forced the path to the java 7 binary and no change. I think the issue in the code is related to updating the recent file list and/or loading the preferences through the API. I'm not sure if there is a tool for browsing the Java preference stored in the system to make sure they are good. i.e. when it retrieves the list of recent files and they aren't defined.

— Reply to this email directly or view it on GitHub.

— Reply to this email directly or view it on GitHub.

— Reply to this email directly or view it on GitHub.

— Reply to this email directly or view it on GitHub.

i-make-robots commented 12 years ago

Awesome work! Can you send that to me in a format that makes it easy to apply to all future versions?

I used to store settings in the EEPROM, then thought better of it. There's no reason to mess up the EEPROM with settings. Heck, if I could get away with not putting the GUID in there I would. Also, if I store the settings in the cloud later then anyone with the software can connect to your bot, get the GUID, request settings from the cloud, and be all set to go. I swap between different machines often and this saves me a lot of headache. It also lets me gather stats on the typical machine size and number of machines in the wild. Soon I'll start saying "join the dozens of others who love their drawbots!"

Can you send me a picture of your success? I'd love to blog it.

On Wed, Aug 15, 2012 at 12:26 PM, maudette01432 notifications@github.comwrote:

Dan,

It's definitely related to the build environment - your build will not run on my windows or OSX machine. I downloaded the latest Oracle JDK and installed it and got hacking a little bit to see if I could get an executable to start.

I was able to build the "master' and experimental branch from the command line and got it to start reliably every single time on OS X and windows. It took a while - since I don't normally code in java but I did manage to get it to build (and into a single jar file + the serial binaries - and it doesn't rely on the Eclipse jar-in-jar classes either) using the following script:

!/bin/bash --verbose

rm -rf *.class rm -rf gnu

rm -rf MANIFEST.MF META-INF rm -rf RXTXcomm.jar

cp ../RXTXcomm.jar .

javac -g -sourcepath . -classpath ./classes Filter.java javac -g -sourcepath . -classpath ./classes Filter_BlackAndWhite.java javac -g -sourcepath . -classpath ./classes Filter_DitherFloydSteinberg.java javac -g -sourcepath . -classpath ./classes Filter_Resize.java javac -g -sourcepath . -classpath ./classes Point2D.java javac -g -sourcepath . -classpath ./classes Point3D.java javac -g -sourcepath . -classpath ./RXTXcomm.jar:./ -extdirs rxtxnative/Mac_OS_X Filter_TSPCodeGenerator.java

javac -g -sourcepath . -classpath ./classes StatusBar.java javac -g -sourcepath . -classpath ./classes DrawPanel.java javac -g -sourcepath . -classpath ./RXTXcomm.jar:./ -extdirs rxtxnative/Mac_OS_X DrawbotGUI.java

echo "Manifest-version: 1.0" > MANIFEST.MF echo "Main-Class: DrawbotGui" >> MANIFEST.MF

jar xvf RXTXcomm.jar rm -rf META-INF

jar -cvfe DrawbotGUI.jar DrawbotGUI *.class rxtxnative gnu

TO START Issue:

java -Djava.library.path="./rxtxnative/Mac_OS_X" -jar DrawbotGUI.jar

I still get the version mismatch warning on the command line: Mikes-iMac:src maudette01432$ java -Djava.library.path="./rxtxnative/Mac_OS_X" -jar DrawbotGUI.jar WARNING: RXTX Version mismatch Jar version = RXTX-2.2pre1 native lib Version = RXTX-2.2pre2

but the rest of the GUI seems to run and start reliable. In fact I was able to get it to connect, jog, any "gasp" draw a complete picture without hanging. (success!!!!) I also was able to start the app on Windows - although I didn't test any of the functions with it yet.

There does however seem to be an issue with preferences and general file IO. I am building a small list of bugs and will see if I can fix some of them. Any thoughts on storing the "machine limits" and "paper size" on the machine and using Mcodes to set and retrieve them like most of the 3d printers do? It's not like any user is ever - in a reasonable life time be able to write the eeprom so many times it will fail. I might be able to modify the Arduino code to do this pretty trivially and then possibly the Java code once I get my head wrapped around it.

I have attached my JAR if you want to give it a go. It's built with JAVA 7.

-Mike

On Aug 15, 2012, at 12:11 PM, Dan Royer notifications@github.com wrote:

I use eclipse. For some reason eclipse doesn't store the project files with the source so it doesn't end up in the hit repository. V annoying.

(adventuring)

On 2012-08-15, at 7:57, maudette01432 notifications@github.com wrote:

Yeah that part of the code looks good - the part I was wondering about was the portion hat "deletes" the recents…if I had say 5 recents and all the files were removed is it possible for the delete portion to leave an empty array/null pointer?

If I knew how the java was being compiled I'd try a few things my self

  • I do have the most recent Oracle JDK installed on my system. Do you have a makefile or script you are using to build it? Java looks pretty straight forward as a language goes - even though I've never wrote a program in it.

Oracle also has a doc up on their website for packaging as a .app…If I could get it to start I was going to try that.

-Mike

On Aug 15, 2012, at 10:39 AM, Dan Royer notifications@github.com wrote:

When they aren't defined they are set to empty strings. It shouldn't e barfing on that line. Maybe windows is paranoid and isn't giving java access to prefs?

(adventuring)

On 2012-08-15, at 5:42, maudette01432 notifications@github.com wrote:

I've been poking around the code and checked to make sure Java7 was installed and up to date. I even forced the path to the java 7 binary and no change. I think the issue in the code is related to updating the recent file list and/or loading the preferences through the API. I'm not sure if there is a tool for browsing the Java preference stored in the system to make sure they are good. i.e. when it retrieves the list of recent files and they aren't defined.

— Reply to this email directly or view it on GitHub.

— Reply to this email directly or view it on GitHub.

— Reply to this email directly or view it on GitHub.

— Reply to this email directly or view it on GitHub.

— Reply to this email directly or view it on GitHubhttps://github.com/i-make-robots/DrawBot/issues/4#issuecomment-7766415.

Dan Royer, Marginally Clever Software http://www.marginallyclever.com/ - Robotics & Website Management Solutions. Ph: +1.604.916.2281

maudette01432 commented 12 years ago

Dan,

Here is a packaged up OSX app. I did learn a couple new things today. This app is "large" due to the fact that the jvm runtime is packaged up with it - as would be required on the AppStore. It can be redistributed without it but it would hone have a dependency on the user having the proper version of Java installed etc…this makes it more "foolproof".

Grab it from my DropBox here - it'll be there for the next couple days. https://www.dropbox.com/s/innwlkfyb1tvtck/DrawbotGUI.zip Unzip - and double click or drag to your app folder. I'm going to make a drawboted "D" icon for the app too - if I have time.

I also added the build script to my drop-box - it has all the compilation commands to build the JAR file (which works great on both windows and OSX) as well as the additional steps to build the packaged OSX App. The build script can be found here. I don't have eclipse (or the project files) so I don't know if I could automate the build any further - this just works for me.

https://www.dropbox.com/s/xhtl06e1ipwk9jb/osx_build_app.sh

This is a "unix/osx" build script put it in the "java/src" directory and type './osx_build_app.sh' at the command prompt. It does have a dependency on the RXTXcomm.jar - since the source didn't appear on git - I just extracted all the classes from the jar with the jar command. The other thing that's required is appbunlder which can be downloaded from http://java.net/projects/appbundler/downloads. The script checks for this - as it's required to build the .app" package.

Try it out - let me know if it works for you.

-Mike

On Aug 15, 2012, at 3:35 PM, Dan Royer notifications@github.com wrote:

Awesome work! Can you send that to me in a format that makes it easy to apply to all future versions?

I used to store settings in the EEPROM, then thought better of it. There's no reason to mess up the EEPROM with settings. Heck, if I could get away with not putting the GUID in there I would. Also, if I store the settings in the cloud later then anyone with the software can connect to your bot, get the GUID, request settings from the cloud, and be all set to go. I swap between different machines often and this saves me a lot of headache. It also lets me gather stats on the typical machine size and number of machines in the wild. Soon I'll start saying "join the dozens of others who love their drawbots!"

Can you send me a picture of your success? I'd love to blog it.

On Wed, Aug 15, 2012 at 12:26 PM, maudette01432 notifications@github.comwrote:

Dan,

It's definitely related to the build environment - your build will not run on my windows or OSX machine. I downloaded the latest Oracle JDK and installed it and got hacking a little bit to see if I could get an executable to start.

I was able to build the "master' and experimental branch from the command line and got it to start reliably every single time on OS X and windows. It took a while - since I don't normally code in java but I did manage to get it to build (and into a single jar file + the serial binaries - and it doesn't rely on the Eclipse jar-in-jar classes either) using the following script:

!/bin/bash --verbose

rm -rf *.class rm -rf gnu

rm -rf MANIFEST.MF META-INF rm -rf RXTXcomm.jar

cp ../RXTXcomm.jar .

javac -g -sourcepath . -classpath ./classes Filter.java javac -g -sourcepath . -classpath ./classes Filter_BlackAndWhite.java javac -g -sourcepath . -classpath ./classes Filter_DitherFloydSteinberg.java javac -g -sourcepath . -classpath ./classes Filter_Resize.java javac -g -sourcepath . -classpath ./classes Point2D.java javac -g -sourcepath . -classpath ./classes Point3D.java javac -g -sourcepath . -classpath ./RXTXcomm.jar:./ -extdirs rxtxnative/Mac_OS_X Filter_TSPCodeGenerator.java

javac -g -sourcepath . -classpath ./classes StatusBar.java javac -g -sourcepath . -classpath ./classes DrawPanel.java javac -g -sourcepath . -classpath ./RXTXcomm.jar:./ -extdirs rxtxnative/Mac_OS_X DrawbotGUI.java

echo "Manifest-version: 1.0" > MANIFEST.MF echo "Main-Class: DrawbotGui" >> MANIFEST.MF

jar xvf RXTXcomm.jar rm -rf META-INF

jar -cvfe DrawbotGUI.jar DrawbotGUI *.class rxtxnative gnu

TO START Issue:

java -Djava.library.path="./rxtxnative/Mac_OS_X" -jar DrawbotGUI.jar

I still get the version mismatch warning on the command line: Mikes-iMac:src maudette01432$ java -Djava.library.path="./rxtxnative/Mac_OS_X" -jar DrawbotGUI.jar WARNING: RXTX Version mismatch Jar version = RXTX-2.2pre1 native lib Version = RXTX-2.2pre2

but the rest of the GUI seems to run and start reliable. In fact I was able to get it to connect, jog, any "gasp" draw a complete picture without hanging. (success!!!!) I also was able to start the app on Windows - although I didn't test any of the functions with it yet.

There does however seem to be an issue with preferences and general file IO. I am building a small list of bugs and will see if I can fix some of them. Any thoughts on storing the "machine limits" and "paper size" on the machine and using Mcodes to set and retrieve them like most of the 3d printers do? It's not like any user is ever - in a reasonable life time be able to write the eeprom so many times it will fail. I might be able to modify the Arduino code to do this pretty trivially and then possibly the Java code once I get my head wrapped around it.

I have attached my JAR if you want to give it a go. It's built with JAVA

-Mike

On Aug 15, 2012, at 12:11 PM, Dan Royer notifications@github.com wrote:

I use eclipse. For some reason eclipse doesn't store the project files with the source so it doesn't end up in the hit repository. V annoying.

(adventuring)

On 2012-08-15, at 7:57, maudette01432 notifications@github.com wrote:

Yeah that part of the code looks good - the part I was wondering about was the portion hat "deletes" the recents…if I had say 5 recents and all the files were removed is it possible for the delete portion to leave an empty array/null pointer?

If I knew how the java was being compiled I'd try a few things my self

  • I do have the most recent Oracle JDK installed on my system. Do you have a makefile or script you are using to build it? Java looks pretty straight forward as a language goes - even though I've never wrote a program in it.

Oracle also has a doc up on their website for packaging as a .app…If I could get it to start I was going to try that.

-Mike

On Aug 15, 2012, at 10:39 AM, Dan Royer notifications@github.com wrote:

When they aren't defined they are set to empty strings. It shouldn't e barfing on that line. Maybe windows is paranoid and isn't giving java access to prefs?

(adventuring)

On 2012-08-15, at 5:42, maudette01432 notifications@github.com wrote:

I've been poking around the code and checked to make sure Java7 was installed and up to date. I even forced the path to the java 7 binary and no change. I think the issue in the code is related to updating the recent file list and/or loading the preferences through the API. I'm not sure if there is a tool for browsing the Java preference stored in the system to make sure they are good. i.e. when it retrieves the list of recent files and they aren't defined.

— Reply to this email directly or view it on GitHub.

— Reply to this email directly or view it on GitHub.

— Reply to this email directly or view it on GitHub.

— Reply to this email directly or view it on GitHub.

— Reply to this email directly or view it on GitHubhttps://github.com/i-make-robots/DrawBot/issues/4#issuecomment-7766415.

Dan Royer, Marginally Clever Software http://www.marginallyclever.com/ - Robotics & Website Management Solutions. Ph: +1.604.916.2281* * — Reply to this email directly or view it on GitHub.

Bluemetal09 commented 12 years ago

Mike,

Dan has created something really great and accessible with the Drawbot. I am almost done with mine (it uses Nema 8 motors I had at hand after I destroyed a few chips by not following instructions) and Dan has been extremely helpful during the build. I also appreciate your help with the applications.

I have tried to follow your path and managed to compile the OSX app using your previous script last night - it is a thing of beauty when it works :) .

I had also downloaded the JDK yesterday - my original goal was to see if there is a way to have control over how to pack the lines more closely during the creation of the gcode (there seems to be a variable "dots_per_cm" that apparently defines the density). It would be great to have that density as another choice in the area and paper dimensions.

It compiled ok but it did not start though as it complained that the rxtx... file was not available on the path (doing this from memory). It was late and I did not try to dig too deep and I will try the packaged app tonight on the mac at home to see how it works.

I was wondering if you are going to try to get the windows version working also since it seems to have the same issues.

Miguel Angelo

maudette01432 commented 12 years ago

Windows and OSX use the same JAR - and both worked for me. The windows batch file needs the full path to the JVM version 7 in it.

I'll make another issue to track the "configuration" option for dots_per_cm as an enhancement. There are a couple more things I'd like to change too. I know too many cooks can spoil the pot - but I want this thing to work great all the time too. I don't have access to the Git repository to check in my changes and I don't want to step on any toes. I'm sure I can help out Dan a little with this too.

i-make-robots commented 12 years ago

Dots per cm is a great idea. I think bobbin radius should be another. These should only be in the advanced user config, most people should never experience either of these.

On Thu, Aug 16, 2012 at 12:13 PM, maudette01432 notifications@github.comwrote:

Windows and OSX use the same JAR - and both worked for me. The windows batch file needs the full path to the JVM version 7 in it.

I'll make another issue to track the "configuration" option for dots_per_cm as an enhancement. There are a couple more things I'd like to change too. I know too many cooks can spoil the pot - but I want this thing to work great all the time too. I don't have access to the Git repository to check in my changes and I don't want to step on any toes. I'm sure I can help out Dan a little with this too.

— Reply to this email directly or view it on GitHubhttps://github.com/i-make-robots/DrawBot/issues/4#issuecomment-7795713.

Dan Royer, Marginally Clever Software http://www.marginallyclever.com/ - Robotics & Website Management Solutions. Ph: +1.604.916.2281

Bluemetal09 commented 12 years ago

Mike,

I am getting the following message when I try to run the windows_runme.bat file:

C:\Users\Miguel\Desktop\i-make-robots-DrawBot-0eb7db5\java>java -classpath RXTXcomm. jar -Djava.library.path=classes\rxtxnative\Windows\i3680mingw32 -jar Drawbot GUI.jar java.lang.UnsatisfiedLinkError: no rxtxSerial in java.library.path thrown while loading gnu.io.RXTXCommDriver Exception in thread "AWT-EventQueue-0" java.lang.UnsatisfiedLinkError: no rxtxSe rial in java.library.path at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1860) at java.lang.Runtime.loadLibrary0(Runtime.java:845) at java.lang.System.loadLibrary(System.java:1084) at gnu.io.CommPortIdentifier.(CommPortIdentifier.java:123) at DrawbotGUI.ListSerialPorts(DrawbotGUI.java:356) at DrawbotGUI.UpdateMenuBar(DrawbotGUI.java:1196) at DrawbotGUI.CreateMenuBar(DrawbotGUI.java:1139) at DrawbotGUI.CreateAndShowGUI(DrawbotGUI.java:1358) at DrawbotGUI.access$1100(DrawbotGUI.java:32) at DrawbotGUI$5.run(DrawbotGUI.java:1371) at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:251) at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:711) at java.awt.EventQueue.access$000(EventQueue.java:104) at java.awt.EventQueue$3.run(EventQueue.java:672) at java.awt.EventQueue$3.run(EventQueue.java:670) at java.security.AccessController.doPrivileged(Native Method) at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDo main.java:76) at java.awt.EventQueue.dispatchEvent(EventQueue.java:681) at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThre ad.java:244) at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread. java:163) at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThre ad.java:151) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:147) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:139) at java.awt.EventDispatchThread.run(EventDispatchThread.java:97)

I guess the issue is at "no rxtxSerial in java.library.path" but rxtxserial.dll is the same directory where the command is being executed.

What am I missing?

Miguel Angelo

maudette01432 commented 12 years ago

Try this as the .bat file:

"<path to java.exe" -Djava.library.path=classes\rxtxnative\Windows\i3680mingw32 -jar DrawbotGUI.jar

Where you JAR is you should have the classes folder.

classes\rxtxnative\Windows...

If that does't work try it without the java.library.path defined. It should pick up the DLL. I don't have my laptop on right now…

I think I just ran java.exe -jar DrawbotGUI.jar in the directory where that dll was when I played with it last night.

            -Mike

On Aug 16, 2012, at 7:34 PM, Bluemetal09 notifications@github.com wrote:

Mike,

I am getting the following message when I try to run the windows_runme.bat file:

C:\Users\Miguel\Desktop\i-make-robots-DrawBot-0eb7db5\java>java -classpath RXTXcomm. jar -Djava.library.path=classes\rxtxnative\Windows\i3680mingw32 -jar Drawbot GUI.jar java.lang.UnsatisfiedLinkError: no rxtxSerial in java.library.path thrown while loading gnu.io.RXTXCommDriver Exception in thread "AWT-EventQueue-0" java.lang.UnsatisfiedLinkError: no rxtxSe rial in java.library.path at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1860) at java.lang.Runtime.loadLibrary0(Runtime.java:845) at java.lang.System.loadLibrary(System.java:1084) at gnu.io.CommPortIdentifier.(CommPortIdentifier.java:123) at DrawbotGUI.ListSerialPorts(DrawbotGUI.java:356) at DrawbotGUI.UpdateMenuBar(DrawbotGUI.java:1196) at DrawbotGUI.CreateMenuBar(DrawbotGUI.java:1139) at DrawbotGUI.CreateAndShowGUI(DrawbotGUI.java:1358) at DrawbotGUI.access$1100(DrawbotGUI.java:32) at DrawbotGUI$5.run(DrawbotGUI.java:1371) at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:251) at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:711) at java.awt.EventQueue.access$000(EventQueue.java:104) at java.awt.EventQueue$3.run(EventQueue.java:672) at java.awt.EventQueue$3.run(EventQueue.java:670) at java.security.AccessController.doPrivileged(Native Method) at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDo main.java:76) at java.awt.EventQueue.dispatchEvent(EventQueue.java:681) at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThre ad.java:244) at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread. java:163) at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThre ad.java:151) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:147) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:139) at java.awt.EventDispatchThread.run(EventDispatchThread.java:97)

I guess the issue is at "no rxtxSerial in java.library.path" but rxtxserial.dll is the same directory where the command is being executed.

What am I missing?

Miguel Angelo

— Reply to this email directly or view it on GitHub.

i-make-robots commented 12 years ago

the dll should be in classes\rxtxnative\Windows\i3680mingw32

On Thu, Aug 16, 2012 at 4:34 PM, Bluemetal09 notifications@github.comwrote:

Mike,

I am getting the following message when I try to run the windows_runme.bat file:

C:\Users\Miguel\Desktop\i-make-robots-DrawBot-0eb7db5\java>java -classpath RXTXcomm.

jar -Djava.library.path=classes\rxtxnative\Windows\i3680mingw32 -jar Drawbot GUI.jar java.lang.UnsatisfiedLinkError: no rxtxSerial in java.library.path thrown while loading gnu.io.RXTXCommDriver Exception in thread "AWT-EventQueue-0" java.lang.UnsatisfiedLinkError: no rxtxSe rial in java.library.path at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1860) at java.lang.Runtime.loadLibrary0(Runtime.java:845) at java.lang.System.loadLibrary(System.java:1084)

at gnu.io.CommPortIdentifier.(CommPortIdentifier.java:123) at DrawbotGUI.ListSerialPorts(DrawbotGUI.java:356) at DrawbotGUI.UpdateMenuBar(DrawbotGUI.java:1196) at DrawbotGUI.CreateMenuBar(DrawbotGUI.java:1139) at DrawbotGUI.CreateAndShowGUI(DrawbotGUI.java:1358) at DrawbotGUI.access$1100(DrawbotGUI.java:32) at DrawbotGUI$5.run(DrawbotGUI.java:1371) at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:251) at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:711) at java.awt.EventQueue.access$000(EventQueue.java:104) at java.awt.EventQueue$3.run(EventQueue.java:672) at java.awt.EventQueue$3.run(EventQueue.java:670) at java.security.AccessController.doPrivileged(Native Method) at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDo main.java:76) at java.awt.EventQueue.dispatchEvent(EventQueue.java:681) at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThre ad.java:244) at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread. java:163) at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThre ad.java:151) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:147) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:139) at java.awt.EventDispatchThread.run(EventDispatchThread.java:97)

I guess the issue is at "no rxtxSerial in java.library.path" but rxtxserial.dll is the same directory where the command is being executed.

What am I missing?

Miguel Angelo

— Reply to this email directly or view it on GitHubhttps://github.com/i-make-robots/DrawBot/issues/4#issuecomment-7802969.

Dan Royer, Marginally Clever Software http://www.marginallyclever.com/ - Robotics & Website Management Solutions. Ph: +1.604.916.2281

Bluemetal09 commented 12 years ago

I just noticed that the rxtxserial.dll is actually in the folder called i3680-mingw32 ! There is a dash there that is not in the folder name in the .bat file. Could that be the issue?

Running without the path works though ( java -D -d DrawbotGUI.jar ). You still get the RXTX mismatch as you've mentioned above but the application comes up.

I need to go to settings to confirm the dimensions which come up as stored so it is just to OK it. The jog works (though I get orange "Invalid command: 'M114;' after every jog.

The issue now is converting the file. If I try to open a jpg file, that an earlier version converted just fine, the prompt turns green and say Opening file.... and is stuck there.

The terminal windows has the following output:

C:\Users\Miguel\Desktop\i-make-robots-DrawBot-0eb7db5\java>java -D -jar DrawbotGUI.jar WARNING: RXTX Version mismatch Jar version = RXTX-2.2pre1 native lib Version = RXTX-2.1-7 min_intensity=0.0 max_intensity=253.0 Exception in thread "AWT-EventQueue-0" java.lang.IllegalArgumentException: Width (-629) and height (-489) cannot be <= 0 ..........

So I change the dimensions to have negative values on the left and positive values on the right ( Dan suggested the other way around that to get the motors to invert and behave properly and they did) and the file processing conversion works just fine :) but now the X directions are flipped ( +X moves to the left and -X moves to the right ). Jog in and out still does in and out but with the other motor than before

So I try switching the motors around on the shield and then X and Y go berserk. +X and -Y go left, -X and +Y go down.

If after the file conversion, I go and set the directions in the original way ( - values on the X right ) then the file seems to print correctly (a square is more like a slightly taller rectangle) but the directions as correct.

There is always the possibility of going into the firmware now that the software is doing everything is supposed to do.

maudette01432 commented 12 years ago

Since I rebuilt it with the script the -D option doesn't appear to be required. I'm no java guru so I don't understand why.

Make sure you are running the latest firmware from the arduino folder - I think I saw the M114 when I wasn't.

When you configured your machine what were the settings when you "configure limits"

The machine limits (outermost ring) should have negative values for left and bottom and positive for right and top. The GUI will let you enter in illegal values and go on it's merry way (BUG!) needs to be filed.

I think it throws an exception similar to what you are seeing.

Make sure you are running the latest firmware out of the experimental branch. Completely unload your bobbins. Make sure the left motor is plugged into M3/M4 and the right into M1/M2.

In the drawbot gui Open the settings jog motors.

Press IN on the L button and ensure the left motor jogs….if it does wind some tension with "IN" until it's dangling a little bit. If it doesn't something is wired wrong. Next follow the same procedure on the right. wind the bobbins IN until it starts lifting the pen holder.

Now wind L and R until the pen is in the center of the workspace. If you can't get this far you may need to power your motor controller with a better power supply. If the L and R motors are just humming or jumping around you may have the steppers wired to the stepper board wrong (I'm not sure if you ordered your stuff elsewhere I built my own out of salvaged printer parts.

The firmware works fine with my setup - I'm wondering if you selected the "invert" function and it gets stored and not recalled. Could also be that the bobbins are wound the wrong way. Mine was doing something similar until I re-wound them.

On Aug 16, 2012, at 9:12 PM, Bluemetal09 notifications@github.com wrote:

I just noticed that the rxtxserial.dll is actually in the folder called i3680-mingw32 ! There is a dash there that is not in the folder name in the .bat file. Could that be the issue?

Running without the path works though ( java -D -d DrawbotGUI.jar ). You still get the RXTX mismatch as you've mentioned above but the application comes up.

I need to go to settings to confirm the dimensions which come up as stored so it is just to OK it. The jog works (though I get orange "Invalid command: 'M114;' after every jog.

The issue now is converting the file. If I try to open a jpg file, that an earlier version converted just fine, the prompt turns green and say Opening file.... and is stuck there.

The terminal windows has the following output:

C:\Users\Miguel\Desktop\i-make-robots-DrawBot-0eb7db5\java>java -D -jar DrawbotGUI.jar WARNING: RXTX Version mismatch Jar version = RXTX-2.2pre1 native lib Version = RXTX-2.1-7 min_intensity=0.0 max_intensity=253.0 Exception in thread "AWT-EventQueue-0" java.lang.IllegalArgumentException: Width (-629) and height (-489) cannot be <= 0 ..........

So I change the dimensions to have negative values on the left and positive values on the right ( Dan suggested the other way around that to get the motors to invert and behave properly and they did) and the file processing conversion works just fine :) but now the X directions are flipped ( +X moves to the left and -X moves to the right ). Jog in and out still does in and out but with the other motor than before

So I try switching the motors around on the shield and then X and Y go berserk. +X and -Y go left, -X and +Y go down.

If after the file conversion, I go and set the directions in the original way ( - values on the X right ) then the file seems to print correctly (a square is more like a slightly taller rectangle) but the directions as correct.

There is always the possibility of going into the firmware now that the software is doing everything is supposed to do.

— Reply to this email directly or view it on GitHub.

Bluemetal09 commented 12 years ago

I have not updated the firmware, so as soon as it finishes printing the Doctor Who Season 6 picture I will upgrade it.

I will also do the bobbin dance. Thank you for the great help.

Bluemetal09 commented 12 years ago

By the way, in the wiki assembly instructions the caption under the picture says:

"Notice how the M3M4 are on the same end as the (silver) USB connector."

When it is clear that M1/M2 are on the left side by the USB connector - you can actually read the M2 between the two blue connectors and you can also read M3 the chip and the base of the blue connector on the right side of the shield.

Should the L motor be connected to the blue connector by the Arduino USB port or to M3/M4? I had a 50% of getting it right and I think I missed it! :P

maudette01432 commented 12 years ago

Looking at mine my Right motor is connected to the USB side - my board is labeled M2/M3 on that side. The left motor is connected on the bottom of the board labeled M3/M4. This works for me and all the jog buttons go in the right direction….at least with the latest arduino code (the original code didn't step my motors properly for some reason - they would just sit and hum). (note I'm using a booty-fab setup just to debug software and play with it a little until I make some nice brackets….and clearly my pen holder has to go…this one doesn't work all that well. But it does draw as expected. (USB port is on the right). - the other thing hanging off is for a 1.5A adapter I have feeding the motors through an external power supply - the hbrudge chips on the motor shield get pretty hot but they can handle a little more power before they burn up :D - If I had some nice small motors I could probably just run it off the USB port….these won't even move without the adapter :D.

If it's drawing properly with the coordinates swapped around then the motors are likely swapped with the bobbins loaded the wrong way. It sounds like everything is actually moving the way it should so you might just have things flipped.

e-mail me directly at maudette01432@gmai.com - since we don't need the bot debug to clutter up the original problem ticket. :D BTW I really have nothing to do with this - I decided to give it a go and it a wall so I started debugging it. I'd really like to see SVG import for this too…then you cold plot whatever you wanted on say a white-board.

        -Mike

On Aug 16, 2012, at 10:28 PM, Bluemetal09 notifications@github.com wrote:

By the way, in the wiki assembly instructions the caption under the picture says:

"Notice how the M3M4 are on the same end as the (silver) USB connector."

When it is clear that M1/M2 are on the left side by the USB connector - you can actually read the M2 between the two blue connectors and you can also read M3 the chip and the base of the blue connector on the right side of the shield.

Should the L motor be connected to the blue connector by the Arduino USB port or to M3/M4? I had a 50% of getting it right and I think I missed it! :P

— Reply to this email directly or view it on GitHub.

i-make-robots commented 12 years ago

You know you've got the motors wired correctly when Settings > Jog Motors > L IN turns the left motor and Settings > Jog Motors > R IN turns the right motor. M114 is a newer command that requires a firmware update. It means "report my current position". That way you can move with greater precision. In future I'd like to be able to display the plotter XY position. If you have limit switches added you can use G28 to auto-center the machine. I'm working on documenting the feature now. It completely replaces the old "HOME" command - anything that can be switched to gcode is consistent, and consistent is a good thing, IMO.

Sorry about the "flip the numbers". I must have been tired.

On Thu, Aug 16, 2012 at 8:17 PM, maudette01432 notifications@github.comwrote:

Looking at mine my Right motor is connected to the USB side - my board is labeled M2/M3 on that side. The left motor is connected on the bottom of the board labeled M3/M4. This works for me and all the jog buttons go in the right direction….at least with the latest arduino code (the original code didn't step my motors properly for some reason - they would just sit and hum). (note I'm using a booty-fab setup just to debug software and play with it a little until I make some nice brackets….and clearly my pen holder has to go…this one doesn't work all that well. But it does draw as expected. (USB port is on the right). - the other thing hanging off is for a 1.5A adapter I have feeding the motors through an external power supply - the hbrudge chips on the motor shield get pretty hot but they can handle a little more power before they burn up :D - If I had some nice small motors I could probably just run it off the USB port….these won't even move without the adapter :D.

If it's drawing properly with the coordinates swapped around then the motors are likely swapped with the bobbins loaded the wrong way. It sounds like everything is actually moving the way it should so you might just have things flipped.

e-mail me directly at maudette01432@gmai.com - since we don't need the bot debug to clutter up the original problem ticket. :D BTW I really have nothing to do with this - I decided to give it a go and it a wall so I started debugging it. I'd really like to see SVG import for this too…then you cold plot whatever you wanted on say a white-board.

-Mike

On Aug 16, 2012, at 10:28 PM, Bluemetal09 notifications@github.com wrote:

By the way, in the wiki assembly instructions the caption under the picture says:

"Notice how the M3M4 are on the same end as the (silver) USB connector."

When it is clear that M1/M2 are on the left side by the USB connector - you can actually read the M2 between the two blue connectors and you can also read M3 the chip and the base of the blue connector on the right side of the shield.

Should the L motor be connected to the blue connector by the Arduino USB port or to M3/M4? I had a 50% of getting it right and I think I missed it! :P

— Reply to this email directly or view it on GitHub.

— Reply to this email directly or view it on GitHubhttps://github.com/i-make-robots/DrawBot/issues/4#issuecomment-7806119.

Dan Royer, Marginally Clever Software http://www.marginallyclever.com/ - Robotics & Website Management Solutions. Ph: +1.604.916.2281

i-make-robots commented 12 years ago

SVG is problematic. Java doesn't understand SVG and I've seen some that produce garbage output. SVG lets you have layers so what a human sees and what the computer sees are very different. When the robot processes all the hidden stuff the results look...bad.

[ going to move this to a separate enhancement] - there could be rules and layer selection. I have an inkscape plugin that will generate g-code directly complete with pen-up/down for my makerbot....that could easily be modified for generating gcode for Drawbot. And the polargraph project does it as well...

maudette01432 commented 12 years ago

Ok there are several things at play:

appbundler will not work w/ Java 6 - It works with Java 7 and it builds a 64-bit application A 64-bit bundled app will not run on a 32 bit os (or snow leopard for that matter) - the bundled app just crashes. I don't know how to build a stand-alone app for Windows (no app bundler equivalent) perhaps eclipse has a way.

The JAR built by the 64-bit Java 7 JDK should run on Lion and Mountain Lion as well as 64-bit windows

There may have to be a 32-bit windows version and a 32-bit OS X version of the JAR built as well to support 32-bit platforms. JAVA 7 only comes in 64-bit on OSX.

i-make-robots commented 11 years ago

does v0.8.2 fix this issue?

i-make-robots commented 11 years ago

Please try the latest (0.8.4a). There is a start.command that you should be able to double click to start the GUI. I have tested it in OSX.

i-make-robots commented 11 years ago

seems to be working?