Some help with an arduino printer!

Hey all

I'm wondering if anyone can point me in the right direction? i want to make a sort of printer that takes an image and prints a simple picture out using an arduino and a series of pulleys. I think i will need to use proccesing for the image capture and manipulation but im not sure where to start. im not sure about what format to transfer the image to the arduino for printing.

any help would be appreciated!

Rob

There are several examples of arduino controlled inkjet printers on youtube.

If you just want to "print" something dump a string to port 9100. If it has to be a picture dump a PCL or Postscript file from a data shield to port 9100.

using an arduino and a series of pulleys.

That's all your going to use? I want to see a sketch of how that might work, and a schematic. How will you be connecting the pulleys to the Arduino? Are they analog or digital pulleys?

I have worked out the processing sketch. i will threshold the image so its only black and white and the get an array of values which correspond to the pixel colour. I will pass this array as a string to the arduino and "print" out the picture in an array format from to to bottom or whatever way you like. I was thinking of doing it with a 2d array controlled with stepper motors either moving the brush/pen or moving the canvas. but i thought it would be more interesting using 2 pulleys above the canvas held vertically and suspend the pen/brush/ink from the pulleys.

you think this will work?

If you are going to engineer something like this, it will be most helpful if you use correct terminology. A pulley is a device that guides a belt. How will you hang a pen from a pulley?

I will pass this array as a string to the arduino and "print" out the picture in an array format from to to bottom or whatever way you like.

Assuming that the paper is white, the "printer" only needs to be concerned about the black parts of the picture.

You'll need to know where a black pixel is, and what that translates to on the paper. You'll need to command the stepper motors to move back and forth, or up and down, as appropriate, to move the "print head" over the whole area that the pixel represents.

You will not be able to pass the entire image as string to the Arduino. It does not have enough memory to hold all the picture data. Unless the picture is very small. Converting the picture to a string will not decrease its size.

This is not an impossible project, but it is not a trivial project, by any means.

There are many examples in the Exhibition section that show how much work it really is.

But, break it into steps. Make the Arduino spin a stepper motor that is connected to nothing. Then connect it to the pulley and pen assembly, and make the Arduino move the pen a fixed amount.

Repeat for the other axis. Make the Arduino move the pen to "home", wherever that is.

Now, you need to be able to move the pen up and down.

Once this all works, then you can work on the part that moves it to specific locations based on what Processing has determined needs to be drawn.

Passing it as a string will be cumbersome.. you can do this a lot more efficient.
If you pass it as a single, or a set of numbers, it will become a lot more compressed :wink:

ie: use the binary representation of the number

11000011 = 195
01100110 = 102
00111100 = 60
00011000 = 24

4 numbers, 1 per line of pixels
This 'bitmap' would represent a V :wink:

While what PaulS says is true, that only the black pixels matter.. do not ignore the 'white' pixels.
It is possible to heavily compress a bitmap (see above), but if you'd send a list of black pixels with their location, it becomes a lot harder to compress it to useable sizes.

Well the "pen" will be attached to a cradle which will be attached to a belt/string witch in turn is attached to a 2 pulley, now if the cradel is suspended in front of the canvas which is standing vertically, by changing the length of the 2 belts/strings the cradle holding th pen will be able to be transported to almost anywhere below the pulleys. right? if i know how big the image is in pixels and the pass an array of binary 1 or 0 will that make the image smaller in size? since i only need black or white?

Is this going to be inkjet cartridge driven I assume?

no, i still need to decide how im going to get the ink/paint on the canvas, but i want it to be rustic, probably paint. but right now im more interested in how i am going to pass the image to the arduino and how im going to navigate around the canvas.

Then depending on how large your media is it may be easier to move the media than to move your "pen" or Print head.

i thought of that, might be an option, just want to figure out the best way to send the image, will it be easier to send locations of only black pixels or send a long string of all the pixels. the image will most likely be 400*600 so thats 20000 pixels.

That would depend on the "pen" that you use.

You can not implement a way to control something with an understanding of what you are trying to control.

If you use an injet head I would just send it the byte it needs to write that line on the media.

If you use a pen on a solonoid I would just send it the bit to either turn it on or off.

If you used a laser you would have a whole other set of problems.

You can not implement a way to control something with an understanding of what you are trying to control.

Hmmm. I always thought that such an understanding WAS required.

If I understand you right, you want to make something like this:

http://pingmag.jp/2006/04/21/vectors-hektor-and-wobble-preventing-algorithms/

From what I understand, Hektor doesn't work with bitmaps, but rather vectors (hence its name, I think); the Arduino probably has enough memory to store a medium-complexity vector image.

If you are planning on painting a bitmap, though, you'll only be able to transmit so much data to the Arduino to have it paint; in fact, likely you'll still be transmitting position translation commands - the code on the PC controlling the Arduino would have to convert the bitmap into a series of "moves" to plot the image (it would probably be best to have it "random" fill the image, rather than top/bottom/left/right scan - it would just look more interesting).

Still, doing something like this, however you plan on doing it - won't be trivial, as already mentioned. But if you take it a step at a time, you can get there. As it has already been noted, start with getting a single motor turning (actually, I would start with the PC/Arduino communications portion - that always seems to be a hangup in projects of this sort). Work your way up from there...

:slight_smile:

Hektor's home page:

Jürg Lehni's homepage (Hektor's creator - plus information on a different machine, he calls "Rita"):

:slight_smile:

Thats almost exactly what i want to make. but with a paintbrush not a spray can. thanks