Highlander01 / PythonCNCGUI-GRBL

HMI/GUI done in Python using Opengl for graphics is used to interface to modified Simen Grbl CNC code on an Arduino over USB. Operating System Notes: Currently runs well in Linux with Ubuntu and Python2.5. Also in process it now runs in Windows XP 32bit with Python2.7 but comms need to be improved to run faster and gcode files only partial open. Change usbport to ex. COM3 when running windows.
25 stars 10 forks source link

error running UC_Vlk.py #2

Closed cllsj closed 13 years ago

cllsj commented 13 years ago

I just downloaded and tried to run UC_vlk.py. I after installing a few additional python modules I received the following error.

python UC_V1k.py

The program 'python' received an X Window System error. This probably reflects a bug in the program. The error was 'BadDrawable (invalid Pixmap or Window parameter)'. (Details: serial 330 error_code 9 request_code 137 minor_code 8)

I'll be happy to provide more info.

chuck

Highlander01 commented 13 years ago

Hello,

It has been about 10 months since I did much with the code. Your error does not look familiar to me. I took a break/just started back in with building a new/bigger cnc. I will be getting back into the code hopefully in about a month.

What are you trying to run it on though? Linux? Windows? Python version? other imports, I have tkinter wxpython, serial.... I did fire the software up in linux the other day and ran it. I am getting ready to cut some pieces on my small cnc/for my bigger cnc.

Note: It does not work directly with Simens version of Grbl. I added additional back and forth data across the usb to make sure good data was getting sent out. My version of Grbl is now some what old compared to what has been getting develop at Simens location. A few months down the road from now I plan to go back update to newer grbl code but change usb handshaking as I desire. I will probably get new Arduino Mega also that supposedly does better usb comms.

Date: Mon, 11 Jul 2011 20:10:14 -0700 From: reply@reply.github.com To: gooder01@hotmail.com Subject: [Highlander01HMI] error running UC_Vlk.py (#2)

I just downloaded and tried to run UC_vlk.py. I after installing a few additional python modules I received the following error.

python UC_V1k.py

The program 'python' received an X Window System error. This probably reflects a bug in the program. The error was 'BadDrawable (invalid Pixmap or Window parameter)'. (Details: serial 330 error_code 9 request_code 137 minor_code 8)

I'll be happy to provide more info.

chuck

Reply to this email directly or view it on GitHub: https://github.com/Highlander01/Highlander01HMI/issues/2

cllsj commented 13 years ago

Thank you for getting back to me so quickly.

I'm running Bodhi Linux (based on Ubuntu 10.04). The program quits for me as soon as I try to run it. The error I showed is the first message when I attempt to run it from the command line. In IDLE with the debugger turned on I get

bdb.run(), line 368: exec cmd in globals, locals

main.(), line 21: import serial

In the python shell I typed all the import commands I saw and I seemed to have everything installed import serial import wx import sys import threading import time import math

if I highlight the bdb.run() line and open up the gobals on a line labeled builtins I see Arithmetic Error: AssertionError .....

I appear to be running python 2.6

Could I have gotten a corrupt version of the software?

chuck

cllsj commented 13 years ago

I tried a different computer with Debian Mint with the same results.

Highlander01 commented 13 years ago

I have not previously had your error.... I googled it though. I am not sure what comsol relates to but see if it applies. I am not sure if maybe so setting outside of the program some where applies maybe?

http://www.comsol.asia/community/forums/general/thread/7444/

Edit: Actually you could manually edit .comsol/v40/comsol.prefs and insert this line: graphics.rendering.2drend=swing

Date: Wed, 13 Jul 2011 18:44:33 -0700 From: reply@reply.github.com To: gooder01@hotmail.com Subject: Re: [Highlander01HMI] error running UC_Vlk.py (#2)

I tried a different computer with Debian Mint with the same results.

Reply to this email directly or view it on GitHub: https://github.com/Highlander01/Highlander01HMI/issues/2#issuecomment-1567587

Highlander01 commented 13 years ago

I am not complete sure what "x window" is or if it came with the base version linux I installed. I need to see what x is about.

Another link that I googled:

http://www.linuxquestions.org/questions/linux-software-2/x-error-of-failed-request-using-fc2-331451/

Date: Wed, 13 Jul 2011 18:44:33 -0700 From: reply@reply.github.com To: gooder01@hotmail.com Subject: Re: [Highlander01HMI] error running UC_Vlk.py (#2)

I tried a different computer with Debian Mint with the same results.

Reply to this email directly or view it on GitHub: https://github.com/Highlander01/Highlander01HMI/issues/2#issuecomment-1567587

Highlander01 commented 13 years ago

Might be related to graphics drivers? I saw some notes at http://ubuntuforums.org/archive/index.php/t-593640.html

I think there is a link between opengl and graphics cards and drivers etc. and the error you are seeing.

Date: Wed, 13 Jul 2011 18:44:33 -0700 From: reply@reply.github.com To: gooder01@hotmail.com Subject: Re: [Highlander01HMI] error running UC_Vlk.py (#2)

I tried a different computer with Debian Mint with the same results.

Reply to this email directly or view it on GitHub: https://github.com/Highlander01/Highlander01HMI/issues/2#issuecomment-1567587

cllsj commented 13 years ago

On 07/14/2011 10:52 AM, Highlander01 wrote:

Might be related to graphics drivers? I saw some notes at http://ubuntuforums.org/archive/index.php/t-593640.html

I think there is a link between opengl and graphics cards and drivers etc. and the error you are seeing.

Date: Wed, 13 Jul 2011 18:44:33 -0700 From: reply@reply.github.com To: gooder01@hotmail.com Subject: Re: [Highlander01HMI] error running UC_Vlk.py (#2)

I tried a different computer with Debian Mint with the same results.

Reply to this email directly or view it on GitHub: https://github.com/Highlander01/Highlander01HMI/issues/2#issuecomment-1567587 If it helps it errors out on line 1353 self.Show(True)

I'll have to figure out how to write a bit of python to test that function.

cllsj commented 13 years ago

On 07/14/2011 10:52 AM, Highlander01 wrote:

Might be related to graphics drivers? I saw some notes at http://ubuntuforums.org/archive/index.php/t-593640.html

I think there is a link between opengl and graphics cards and drivers etc. and the error you are seeing.

Date: Wed, 13 Jul 2011 18:44:33 -0700 From: reply@reply.github.com To: gooder01@hotmail.com Subject: Re: [Highlander01HMI] error running UC_Vlk.py (#2)

I tried a different computer with Debian Mint with the same results.

Reply to this email directly or view it on GitHub: https://github.com/Highlander01/Highlander01HMI/issues/2#issuecomment-1567587 I installed the ATI drivers and got past that error. Now I get a segmentation fault. Some days! I suppose, however, that is progress. :)

Thanks for your help.

chuck

cllsj commented 13 years ago

I reinstalled the OS (Bodhi Linux) and it works. I did try installing the ATI drivers, but the Dell Latitude with the Radeon 600x video card seems to be very picky and I gave up on that.

Thank you very much for your help.

chuck

Highlander01 commented 13 years ago

Cool! It is good to see some one else get it running! Curious, what are your plans for the software? Are you going to be doing cnc with it or are you using it for other graphical or serial coms projects? Note: to get it to work with Simens newest version of grbl you would need to change the serial coms part of the program some. Once I get my new cnc built I plan to go back and compare with Simens newest version of grbl and do another whole pass on things. Maybe get new Arduino Mega 2560 also, which is suppose to have better usb coms.

Date: Sat, 16 Jul 2011 06:34:45 -0700 From: reply@reply.github.com To: gooder01@hotmail.com Subject: Re: [Highlander01HMI] error running UC_Vlk.py (#2)

I reinstalled the OS (Bodhi Linux) and it works. I did try installing the ATI drivers, but the Dell Latitude with the Radeon 600x video card seems to be very picky and I gave up on that.

Thank you very much for your help.

chuck

Reply to this email directly or view it on GitHub: https://github.com/Highlander01/Highlander01HMI/issues/2#issuecomment-1586930

cllsj commented 13 years ago

On 07/16/2011 03:21 PM, Highlander01 wrote:

Cool! It is good to see some one else get it running! Curious, what are your plans for the software? Are you going to be doing cnc with it or are you using it for other graphical or serial coms projects? Note: to get it to work with Simens newest version of grbl you would need to change the serial coms part of the program some. Once I get my new cnc built I plan to go back and compare with Simens newest version of grbl and do another whole pass on things. Maybe get new Arduino Mega 2560 also, which is suppose to have better usb coms.

Date: Sat, 16 Jul 2011 06:34:45 -0700 From: reply@reply.github.com To: gooder01@hotmail.com Subject: Re: [Highlander01HMI] error running UC_Vlk.py (#2)

I reinstalled the OS (Bodhi Linux) and it works. I did try installing the ATI drivers, but the Dell Latitude with the Radeon 600x video card seems to be very picky and I gave up on that.

Thank you very much for your help.

chuck

Reply to this email directly or view it on GitHub: https://github.com/Highlander01/Highlander01HMI/issues/2#issuecomment-1586930 I plan is to run my 3 axis CNC router with it. So far I've only go the GUI to run. After that I've not been able to get the stepper motors to move at all. If I borrow my wife's laptop, run Windows, CNCdriver.exe, and GCode_Interpreter on the arduino it all works and I can make 3D things with my router. My wife, however, was not happy with me getting her laptop dirty. I think she really got mad when I sucked one of the keys off with my shop vac. Hence, I bought and old Dell laptop to use. I'm not sure how the Simens grbl is suppose to work as I didn't see any sort of configuration file to assign the pin. Did I mention I have the Sparkfun Easy Driver Stepper boards in the circuit? That means I have to assign pins for direction and steps. Anyway, at this point I'm stuck at now to write any Gcode to the arduino from the laptop.
Something like MyUSB.write("G1 X1.0 Y1.0 Z1.0"). I started this just for the learning experience and so far I've not been disappointed. So no worries, I'll figure it out someday.

chuck