Is there a question attached to this?
If it is the title then what sort of help?
Sorry my wrong. I did not finish what I wanted to say and the toipic created! Again Sorry.
What I would like is to built a 3d printer. I have read many articles about 3d printing.
I understood what is made on the above link but I want to make an arduino uno 3d printer using the g-Code.
My problem is that I can not found the whole code for arduino uno. I found make codes but not something complete or any ino file and some that I found had problems on compiling process.
For example I found a site that was intresting but I could not find the ino file.
http://dank.bengler.no/-/page/show/5471_gettinggrbl?ref=checkpoint
I need help.
Sorry for my bad English !
I have some code here:-
http://www.thebox.myzen.co.uk/Hardware/CNC_Conversion.html
Grumpy_Mike:
I have some code here:-
http://www.thebox.myzen.co.uk/Hardware/CNC_Conversion.html
First of all thank you for your immediate response.
There you have done nice work,however I downloaded your code and when I try to compile then it shows that there as some problems.
CNC_Cotroller:12: error: variable or field 'serialEvent' declared void
CNC_Cotroller:12: error: expected )' before 'cncPort' CNC_Cotroller:16: error: variable or field 'controlEvent' declared void CNC_Cotroller:16: error: 'ControlEvent' was not declared in this scope CNC_Cotroller:8: error: 'import' does not name a type CNC_Cotroller:9: error: 'import' does not name a type CNC_Cotroller:11: error: 'Serial' does not name a type CNC_Cotroller:15: error: 'ControlP5' does not name a type CNC_Cotroller:16: error: 'Textlabel' does not name a type CNC_Cotroller:17: error: 'Textlabel' does not name a type CNC_Cotroller:31: error: expected constructor, destructor, or type conversion before 'int' CNC_Cotroller.pde: In function 'void setup()': CNC_Cotroller:34: error: 'size' was not declared in this scope CNC_Cotroller.pde: In function 'void portConnect()': CNC_Cotroller:49: error: expected unqualified-id before '[' token CNC_Cotroller:51: error: 'ports' was not declared in this scope CNC_Cotroller:51: error: 'class HardwareSerial' has no member named 'list' CNC_Cotroller:53: error: 'class HardwareSerial' has no member named 'list' CNC_Cotroller:56: error: 'class HardwareSerial' has no member named 'list' CNC_Cotroller:57: error: 'println' was not declared in this scope CNC_Cotroller:58: error: 'cnc' was not declared in this scope CNC_Cotroller:58: error: expected type-specifier before 'Serial' CNC_Cotroller:58: error: expected
;' before 'Serial'
CNC_Cotroller.pde: At global scope:
CNC_Cotroller:68: error: variable or field 'serialEvent' declared void
CNC_Cotroller:68: error: expected )' before 'cncPort' Controls:6: error: 'ControlP5' does not name a type Controls.pde: In function 'void addControls()': Controls:10: error: 'joyButton' was not declared in this scope Controls:10: error: expected type-specifier before 'ControlP5' Controls:10: error: expected
;' before 'ControlP5'
Controls:18: error: 'Radio' was not declared in this scope
Controls:18: error: expected ;' before 'r' Controls:19: error: request for member 'setColorForeground' in 'r', which is of non-class type 'void ()()' Controls:19: error: 'color' was not declared in this scope Controls:20: error: request for member 'setColorActive' in 'r', which is of non-class type 'void ()()' Controls:21: error: request for member 'setColorLabel' in 'r', which is of non-class type 'void ()()' Controls:23: error: request for member 'add' in 'r', which is of non-class type 'void ()()' Controls:24: error: request for member 'add' in 'r', which is of non-class type 'void ()()' Controls:25: error: request for member 'add' in 'r', which is of non-class type 'void ()()' Controls:26: error: request for member 'add' in 'r', which is of non-class type 'void ()()' Controls:27: error: request for member 'add' in 'r', which is of non-class type 'void ()()' Controls:28: error: request for member 'add' in 'r', which is of non-class type 'void ()()' Controls:29: error: request for member 'deactivateAll' in 'r', which is of non-class type 'void ()()' Controls:31: error: 'jogLabel' was not declared in this scope Controls:33: error: 'XLabel' was not declared in this scope Controls:35: error: 'YLabel' was not declared in this scope Controls:37: error: 'ZLabel' was not declared in this scope Controls:39: error: 'XmaxLabel' was not declared in this scope Controls:41: error: 'XminLabel' was not declared in this scope Controls:43: error: 'YmaxLabel' was not declared in this scope Controls:45: error: 'YminLabel' was not declared in this scope Controls:47: error: 'ZmaxLabel' was not declared in this scope Controls:49: error: 'ZminLabel' was not declared in this scope Controls:51: error: 'firstCommentLabel' was not declared in this scope Controls:52: error: 'filePathNameLabel' was not declared in this scope Controls:54: error: 'setButton' was not declared in this scope Controls:54: error: expected type-specifier before 'ControlP5' Controls:54: error: expected
;' before 'ControlP5'
Controls:71: error: 'controlButton' was not declared in this scope
Controls:71: error: expected type-specifier before 'ControlP5'
Controls:71: error: expected ;' before 'ControlP5' Controls:78: error: 'stopButtton' was not declared in this scope Controls:78: error: expected type-specifier before 'ControlP5' Controls:78: error: expected
;' before 'ControlP5'
Controls.pde: In function 'void drawGraphics()':
Controls:91: error: 'background' was not declared in this scope
Controls:92: error: 'noFill' was not declared in this scope
Controls:93: error: 'stroke' was not declared in this scope
Controls:96: error: 'strokeWeight' was not declared in this scope
Controls:97: error: 'line' was not declared in this scope
Controls:108: error: 'fill' was not declared in this scope
Controls:111: error: 'quad' was not declared in this scope
Controls:112: error: 'quad' was not declared in this scope
Controls:113: error: 'quad' was not declared in this scope
Controls:114: error: 'quad' was not declared in this scope
Controls:117: error: 'quad' was not declared in this scope
Controls:118: error: 'quad' was not declared in this scope
Controls:119: error: 'quad' was not declared in this scope
Controls:120: error: 'quad' was not declared in this scope
Controls.pde: At global scope:
Controls:123: error: variable or field 'controlEvent' declared void
Controls:123: error: 'ControlEvent' was not declared in this scope
You seem to be trying to compile code for the Processing language on an arduino!!!!
Take time to read what it says.
Have you looked at the RepRap wiki and the RepRap forum. There are several variants of OpenSource 3D printer control software that works on Arduino hardware - for example Sprinter.
I am in the process of writing my own simplified software because I want it to control a small lathe as well as using the lathe mechanics as the base for a 3D printer. I am willing to share if you want to go that route but it is unlikely to be suitable for a complete novice. I am NOT prepared to put in the time to provide extensive support.
...R
@Grumpy_Mike, thanks for this link. It has a lot of interesting stuff in it.
What software are you using to generate GCode from drawings? I haven't been able to find anything free that generates GCode for a lathe.
I am planning to do a lot of the interpretation of the GCode on my PC and send very simple data to a simple Arduino program that just has to count integers and generate movement pulses at the right time.
...R
Grumpy_Mike:
I have some code here:-
http://www.thebox.myzen.co.uk/Hardware/CNC_Conversion.html
What software are you using to generate GCode from drawings?
The only drawing package I use with it is inkscape. There is a CNC plug in, however I mainly use that for producing Gcode for engraving text.
I need to cut holes and slots as well as mill out PCBs so basically I wrote my own in processing.
Some of them (not all ) are here:-
http://www.thebox.myzen.co.uk/Mac_Apps/Processing.html
However I doubt if they are suitable for a lathe but it might get you started.
Robin2:
Have you looked at the RepRap wiki and the RepRap forum. There are several variants of OpenSource 3D printer control software that works on Arduino hardware - for example Sprinter.I am in the process of writing my own simplified software because I want it to control a small lathe as well as using the lathe mechanics as the base for a 3D printer. I am willing to share if you want to go that route but it is unlikely to be suitable for a complete novice. I am NOT prepared to put in the time to provide extensive support.
...R
I have looked at RepRap wiki but I did not find any sketch for arduino uno that can be compiled. All that I have tried show some errors. If you have on mind anything that works please send me the link.
Also I think that Sprinter is not compatible with arduino uno.
Of course and I would like to see your code ! Thank you !
Grumpy_Mike:
You seem to be trying to compile code for the Processing language on an arduino!!!!Take time to read what it says.
You were right .
I downloaded your Arduino_CNC code. I tried to compile it and it shows the following message.
GCode_Interp328a.pde:19:22: error: WProgram.h: No such file or directory
In file included from GCode_Interp328a.pde:22:
pins.h:21: error: 'byte' does not name a type
pins.h:47: error: 'byte' does not name a type
GCode_Interp328a:28: error: 'LiquidCrystalDircet' does not name a type
GCode_Interp328a:29: error: 'SPI' does not name a type
GCode_Interp328a.pde: In function 'void setup()':
GCode_Interp328a:76: error: 'lcd' was not declared in this scope
GCode_Interp328a.pde: In function 'byte expanderR(byte, byte)':
GCode_Interp328a:129: error: 'SS_PIN' was not declared in this scope
GCode_Interp328a:130: error: 'Spi' was not declared in this scope
GCode_Interp328a.pde: In function 'byte expanderW(byte, byte, byte)':
GCode_Interp328a:139: error: 'SS_PIN' was not declared in this scope
GCode_Interp328a:140: error: 'Spi' was not declared in this scope
process_string.pde: In function 'void process_string(char*, int)':
process_string:211: error: 'lcd' was not declared in this scope
stepper_control.pde: In function 'void init_steppers()':
stepper_control:26: error: 'stepperByte' was not declared in this scope
stepper_control.pde: In function 'void dda_checkStops()':
stepper_control:41: error: 'lcd' was not declared in this scope
stepper_control:45: error: 'lcd' was not declared in this scope
stepper_control:46: error: 'lcd' was not declared in this scope
stepper_control:47: error: 'lcd' was not declared in this scope
stepper_control:48: error: 'lcd' was not declared in this scope
stepper_control:49: error: 'lcd' was not declared in this scope
stepper_control:50: error: 'lcd' was not declared in this scope
stepper_control:51: error: 'lcd' was not declared in this scope
stepper_control.pde: In function 'void dda_move(long int)':
stepper_control:111: error: 'stepperByte' was not declared in this scope
stepper_control:126: error: 'stepperByte' was not declared in this scope
stepper_control:141: error: 'stepperByte' was not declared in this scope
stepper_control:151: error: 'stepperByte' was not declared in this scope
stepper_control.pde: In function 'void displaySteps()':
stepper_control:180: error: 'lcd' was not declared in this scope
stepper_control.pde: In function 'void lcdDisplayInt(long int)':
stepper_control:197: error: 'lcd' was not declared in this scope
stepper_control:201: error: 'lcd' was not declared in this scope
stepper_control.pde: In function 'void calculate_deltas()':
stepper_control:270: error: 'stepperByte' was not declared in this scope
stepper_control:270: error: 'stepperByte' was not declared in this scope
stepper_control:271: error: 'stepperByte' was not declared in this scope
stepper_control:271: error: 'stepperByte' was not declared in this scope
stepper_control:272: error: 'stepperByte' was not declared in this scope
stepper_control:272: error: 'stepperByte' was not declared in this scope
stepper_control:274: error: 'stepperByte' was not declared in this scope
stepper_control.pde: In function 'void enable_steppers()':
stepper_control:321: error: 'stepperByte' was not declared in this scope
stepper_control.pde: In function 'void disable_steppers()':
stepper_control:330: error: 'stepperByte' was not declared in this scope
For the message : GCode_Interp328a.pde:18:22: error: WProgram.h: No such file or directory
I think that this is because in newer versions the WProgram.h was renamed into Arduino.h so
I can just rename it (but if it is easy for you please send me the file in order to work perfect.)
The rest issues why do they appear ?
any help ?
Have you tried Googling "arduino wprogram.h"? I just did and it explains how to solve that problem.
Maybe that will sort out the other problems too.
You need a Mega to run Sprinter. That's probably your simplest option.
I will need to do a bit more work on my program before I can share it - another few days, perhaps. However it probably won't be any help to you as you will still have to do some work on it, and create a desktop app yourself to feed it with data.
...R
I suggest you Google for the error message:
WProgram.h: No such file or directory
I have now replaced all the WProgram.h: with Arduino.h and up loaded it to my site. So it should compile under IDE 1.0.5.
Don't forget to update the LCD library that is included as well. That needed a bit of a change as the write function it overwrites has changed to return a particularly useless value.
Grumpy_Mike:
I have now replaced all the WProgram.h: with Arduino.h and up loaded it to my site. So it should compile under IDE 1.0.5.
Don't forget to update the LCD library that is included as well. That needed a bit of a change as the write function it overwrites has changed to return a particularly useless value.
First of all thank you for your time. I added the lcd library as you said !
At the compiling process it showed problem at SPI SPI();
and it appeared the following message:
GCode_Interp328a:27: error: 'SPI' does not name a type
GCode_Interp328a.ino: In function 'byte expanderR(byte, byte)':
GCode_Interp328a:127: error: 'SS_PIN' was not declared in this scope
GCode_Interp328a:128: error: 'Spi' was not declared in this scope
GCode_Interp328a.ino: In function 'byte expanderW(byte, byte, byte)':
GCode_Interp328a:137: error: 'SS_PIN' was not declared in this scope
GCode_Interp328a:138: error: 'Spi' was not declared in this scope
So I deleted it and inside void setup() I added
SPI.begin(); // initilise SPI object
Also I changed Spi.transfer into SPI.transfer
I do not Know if it is right but I suppose that it is ok. What is your oninion ?
After this, another problem appeared at
digitalWrite(SS_PIN, LOW);
with the following message :
Mine_GCode_Interp328a.ino: In function 'byte expanderR(byte, byte)':
Mine_GCode_Interp328a:128: error: 'SS_PIN' was not declared in this scope
Mine_GCode_Interp328a.ino: In function 'byte expanderW(byte, byte, byte)':
Mine_GCode_Interp328a:138: error: 'SS_PIN' was not declared in this scope
what I have to do with the SS_PIN ?
may be needed inside pins.h something like
#define SS_PIN (byte) 10
Is it ok this pin and that code ?
Have you replaced WProgram.h: with Arduino.h in the SPI library?
Grumpy_Mike:
Have you replaced WProgram.h: with Arduino.h in the SPI library?
My SPI library was already updated with Arduino.h and I also rechecked it.
However I think that with the way I was refered previously the problem with SPI was solved.
Do you think that it is wrong ?
I think that the main remainning issue now is about "digitalWrite(SS_PIN, LOW);"
What do you think ?
The SS_PIN is defined in the SPI library
In the Spi.h file is the following lines:-
#define SCK_PIN 13
#define MISO_PIN 12
#define MOSI_PIN 11
#define SS_PIN 10
If your code is not seeing this then the updated SPI library does not include these lines. Just add them to the start of the code.