Tuesday, September 21, 2010

Mendel 3D renders

Yesterday I was looking on the wiki for some renders of a completely assembled Mendel. The only thing I found was a tiny picture of the front view. That's really too small to be of any use. I did find the 3D-models of an older version of Mendel made in Solid Edge. Luckily my university has a license for Solid Edge, so I downloaded and installed the software. Once installed, I opened the file and wanted to render it.
I got a lot of errors telling me that the included files had an absolute path reference to \\campus\files\MechEng\... well, just a very long path from a filesystem on a university. I looked for a way to fix them all at once. The only solution I found was putting all files in the same folder as the general-assembly.asm file. I was now able to see the whole Mendel in 3D. That will certainly help me once I start building mine.
I made some high resolution renders of the front, back, top and bottom for people without access to Solid Edge. If you click on a picture, you will be taken to a page with the small version of the image. There is a download button on the top left corner of that page. That's the one you need to download the big image. The images are over 1MB each, so you have been warned.
If you want a view from a different angle or from a specific part of the assembly, leave a reaction below and I'll render it for you.

Front view
Rear view
Bottom view
Top view

Wednesday, September 15, 2010

Arrival of the first parts

While I was programming the extension for mediawiki, some parts for my Mendel arrived in the mail. First one to arrive was the nichrome wire for my heated bed. It's just 10m of nichrome wire for my heated bed, so I don't tink a picture is required.

My broken soldering iron
Next package to arrive was a new soldering iron. I bought a very cheap one on ebay. One would think its just a heating element, so even a cheap one is good right? Wrong. After like 5 minutes of usage, I saw sparks coming out of the metal part. I send a message to tk-stores-494 but still haven't got a reply. They really sell junk, never buy anything there. As I wasn't getting a reply and shipping it back to them would probably just be more expensive then buying a new one, I decided to open it to see what was broken. It was all burned inside. That should really not happen after just 5 minutes.
As it was broken beyond repair, I ordered a new and more expensive one from an other store. The new one hasn't arrived yet.

The next day two packages arrived. The smaller package contained the extruder parts I ordered from reifsnyderb with a .5mm and .35mm nozzle. The nozzles are easy to exchange and everything looks sturdy. The bigger package contained the filament I ordered from reprapsource. It was nicely packaged and they even added a small sample of their black filament. I tried inserting the filament in the extruder, and it fitted nicely.

Today the plastic parts from nophead arrived. The box was smaller then I expected, but it was full of plastic. The parts are nicely made and have almost no errors. I hope I can make stuff with the same quality when my Mendel is finally working. To have a better look at them and see if nothing was missing, I laid the parts out on my desk. After comparing them to a requirement-list, it seems I am missing two x-bar-clamp-m3 and two x-motor-bracket-space. It is an old list, so its possible that these parts aren't needed anymore. I'll only know the answer for sure once I start building my Mendel. If anyone knows the answer, feel free to let me know in a reply. It seems its complete, I should learn to watch more carefully before posting.

That's all that has arrived for now. I'll post updates when more stuff arrives or when I did something else worth mentioning.

Tuesday, September 14, 2010

Upload3D extension

During the past days, I have been working on an extension to integrate my stl2png script in mediawiki. I found very little documentation and comments in their source code. It looks like the only documentation they have is how end-users should use it, but nothing for developers. Every function has about two lines of documentation on what it actually does. A little longer description would have been useful. Because of the lack of documentation, it was hard to use their classes and I had to find some workarounds and hacks to make my code work, as an extension is not allowed to change their files. I just made my script change the $_FILES and $_POST arrays. I know that's not smart to do, but its the only way I managed to tell the wiki it should use an other file as source, and not the uploaded zip.

The extension works, but is still in alpha version. The form for uploading the zip still needs work, and the newly uploaded files don't receive a description for some unknown reason. I have temporarily placed a demo of the extension on my pc at home. You can find it on http://tman.webhop.net:8765/wiki. This won't stay there forever and my pc isn't always online, so its very possible that it won't be accessible. Hopefully it will be used on the reprap-wiki by then. The source code can be found on http://www.reprap.org/wiki/File:Upload3D.zip

I'll stop working on this for a while now. With the demo online, it should give people a clear idea of what is possible with mediawiki. Even with the bad documentation, I still managed to make this in a few days. I hope they won't exchange the wiki for an other type of documentation-system. There is a reason that wikipedia is so big, so it would be stupid to change to an other system if you ask me.

Friday, September 10, 2010

A big upload button

As the delivery of the hardware has been delayed, I decided to search for something else that I could do. I found a page on the wiki mentioning that there was a need for a big upload button. After asking, it seemed that they might drop the whole wiki, so maybe the button wouldn't be needed. I don't really understand why they would replace the wiki with something else, as a wiki keeps a history of both documentation and files, so it sounds like a stupid idea to replace it with something else to me.
Anyway, even if they do change the method of keeping the information, it will still require something similar to the upload button. For that reason I decided to make a script in php that would take a zip as input and give stl-files and the matching renders as png-files. I won't create something to integrate everything in mediawiki yet, until I know for sure that they will keep using it.

First of all, I had to re-install a linux os on one of my pcs. I downloaded kubuntu server edition, set up a lamp server in VMWare and added phpmyadmin on the server. The easyest part was already done. Now I had to install povray and stl2pov. I had no problems installing povray, as it was in multiverse of ubuntu (here).
The problems started happening when I had to build stl2pov myself. It seemed I needed gcc, so I installed that one and uncommented the line in the makefile to make it use gcc. The installation instructions now said that everything should work when I used the make command. But it just gave me an ugly error:
Makefile:9: *** missing separator. Stop.
As that line was an include command, I just opened version.inc, copied everything in there and pasted that over the include command. So the first error was solved.
There was still a second error however. The program didn't recognize .if !defined(NOPORTDOCS), I thought "this is a new installation, I bet it won't be defined for me" and removed the if-test. The compilation did work now. Once that was done, "sudo make install" installed everything just as expected.

Now that the software was installed, I searched for how to run it. Stl2pov was very straightforward and didn't need any parameters or settings files. It just converted the file. I was happy it didn't cause me more troubles. Povray however did require settings and parameters. The parameters  were well documented on their site and I quickly found that -i is for the input file, -o is for the output file, +W is for the width of the image and +H for the height. I added 2 more options to the command: +GA for giving all errors in the terminal and -D for not showing the picture while rendering. So that makes the whole command for rendering an image:
povray -i\"render.pov\" +W600 +H600 -o\"$output\" +GA -D
Now I needed to find how to add settings to tell the program how to render the objects. After looking a little around the internet, I tried some different settings and these seemed to work. I found a basic script on a site, but didn't save the url. Sorry, if it yours let me know and I'll add a link to give you credit. I changed the colors, rotation, light source and camera location a little, but didn't touch the things I didn't know what they were for like the global settings or sky sphere. It works and that's good enough for me.

The file requires an include-file that describes the object that has to be drawn. It expects the object to be called  MODELNAME. So in my script I had to replace the name stl2pov was giving it. A few simple lines of code later, my php script could rename the model. As the rendering is the most intensive part of the script, I didn't think about efficiency while replacing the name and just wrote something that is quick to code instead of quick to execute. My script was now able to render any given stl-file into a png. I uploaded it to the wiki.

After dinner I still had some free time and quickly added the extra feature of unzipping the contents of a given zip, looking for stl-files and matching png-images and rendering them if they were not found. That was basically just extracting files, looping over them and deleting unnecessary files, so I won't go into detail about that.

You can now find the script I just created in the wiki as stl2png. I added a few lines of comments in there, but really not that much. If anything isn't clear about how it works, feel free to ask me.

Monday, September 6, 2010

Buying the last parts

Yesterday I saw that it was possible to pre-order the generation 6 electronics. I already payed a lot of shipping costs for all the parts I bought, so I hoped it was possible to send them along with the other parts I had already paid for. I send an email to Camiel from mendel-parts.com to ask if it was possible to change my order and add the new electronics. He was very friendly and suggested to delete my old order and give me a refund. Then I could place a new order with everything together in it.

The combined shipping of the electronics and hardware does mean that the hardware will also arrive later. That delays the building of my Mendel to the beginning of October. But the waiting is worth 7€ to me. In the mean time I can read and learn a little more about it. That certainly won't be bad.

As everything has been ordered now, I can be certain of how much my new 3D-printer costs. In the table below I have put a breakdown of the costs including VAT. All the prices have been converted to euro just like my bank charged me. So there could be a little extra cost for the conversion of the currencies. The total price was a little lower than the maximum of 800€ that I predicted earlier. I also added where I bought the parts, so if you want to buy them at the same shop you can do so.

plastic partsnophead210,33 €22,14 €232,47 €
hardwaremendel-parts.com200,52 €7,95 €208,47 €
electronicsmendel-parts.com177,31 €0 €177,31 €
motorsmendel-parts.com65,45 €0 €65,45 €
kapton tapemendel-parts.com11,9 €0 €11,9 €
thermistormendel-parts.com2,68 €0 €2,68 €
electric cablesmendel-parts.com9,28 €0 €9,28 €
gluemendel-parts.com10,71 €0 €10,71 €
nichrome wireebay3,41 €2,23 €5,64 €
thermostatfuturelec.com7,25 €2,9 €10,14 €
extruderreifsnyderb24,02 €5,12 €29,13 €
722,85 €40,34 €763,18 €

Saturday, September 4, 2010

Buying some more components

I've ordered some more parts for my mendel. The hybrid thermal barrier that reifsnyderb is selling seemed to be better than the regular nozzle, so I ordered one from him together with a barrel and nozzle. I hope I made the right choice on that one, as it is more expensive than the 12€ default one mendel-parts is selling.

I've also asked if it will be possible to control a heated bed with the generation 6 electronics. It seems that there will come an addon to make this possible in the future, which would also require new firmware. I decided not to wait for the addon, as the electronics themselves are not even released.

Scheme for the thermostat
(Click to enlarge)
I searched for a cheap thermostat and found one I could make myself. Unfortunately international shipping was expensive, so I had to find an other seller of the components. I have no idea how these electronics work, but as it was only 10$ for the components and 4$ shipping at futurlec.com, I decided to try and make it. You can see the scheme in the picture on the right. I made it a little easyer to read and added the values of the components on the scheme. In case you want to try to make one too, I have listed everything I bought in the table below. There are cheaper alternatives on their site for some of these, like the trimpot, but I decided to go for these anyway. I'll make a new post telling whether it worked or not once I have everything assembled. As testing it requires building the whole machine, this might take a while.

CERM5K5k 1/2W Vert. Square Cermet Pot1,311,3
TL431CLPTL431CLP Program Precision Reference0,3510,35
LM358NLM358N - Low Power Dual Op Amp0,2510,25
LED3GGreen 3mm Round LED0,110,1
2SA10152SA1015 PNP General Purpose Transistor0,0510,05
1N41481N4148 100V 200mA General Purpose Diode0,220,4
1N40021N4002 100V 1A General Purpose Diode0,0520,1
1N9641N964 13V 400mW Zener Diode0,110,1
R010KMF10kohm 1/4W 1% Metal Film Resistor (10)0,210,2
R0047MMF4.7Mohm 1/4W 1% Metal Film Resistor (10)0,210,2
R0012KMF1.2kohm 1/4W 1% Metal Film Resistor (10)0,210,2
R001KMF1kohm 1/4W 1% Metal Film Resistor (10)0,210,2
R033R1W33ohm 1W 5% Carbon Film Resistor (10)0,410,4
C010UC0.01uF 50V Ceramic Capacitor0,0510,05
C470U16E470uF 16V Radial Electrolytic Capacitor0,1210,12
ICS88 Pin IC Socket0,0410,04
LM35DZLM35DZ - Precision C. Temp Sensor1,9511,95
JQC-21FF-12SPDT 12V 10A PCB Relay1,1511,15
ROCKERRNDBL10Black SPST Round Rocket Switch0,410,4
HEADS88 Pin .100 Straight Male Headers0,710,7
PROTO777Prototyping Board - 7771,511,5
DCCHM52.5mm PC Mount Male0,210,2

At this moment I've spend a little over 500€ on components and shipping costs. I still have to buy the electronics, motors and some smaller parts. I think the total costs will be just below 800€, including the heated bed. It's a little more expensive then the laser cut Mendel from BotMill, but a lot cheaper then their unassembled Mendel. So it was worth looking around for beter deals.

Wednesday, September 1, 2010

Blog Layout

I have been working on the layout of my new blog. I took one of those standard templates and changed the colors and html a little. Normally I make my own layouts, but this was just so much faster, and the result looks just as good. The only downsides on borrowing other peoples work is I don't have the fun of making it, and the tiny reference on the bottom showing that I didn't make it. I suppose that isn't too bad. I can still make my own custom layout later on.

I tried to make something that matches the layout of my homepage. (tman.be) The layout there has been made by me, without having to borrow anything. I changed the background color of the posts to something that is a little easier to read than the gray-on-blue from my site.
I don't like sites with big background images or too flashy backgrounds, so I don't add them on my own sites, as you might have noticed. A vague drawing on both sides of the page is about the limit of what is still acceptable for me. But a background image is still way better than those new ugly flash-sites with things flying all over the screen.
If you don't know what I mean, just look at ageofconan.com. They clearly put a lot of work in their site, but the result is just awful with the flashy green background, auto-starting music and opening scrolls whenever I dare to click a button. What a shame that such a good game has such a bad website.

Anyway, enough about other sites, this was about what I changed here. Apart from the changed colors, I also made a header. I didn't have much time, so the only thing I could come up with was some text with a little glow effect on it. I'm not satisfied with the result, but it will have to do for now. I removed the standard white line around the header, as it didn't look good at all. It took me longer than expected to find where in the code I had to add something to center the image. Apparently I had to tick a box to show the full code. Once I found that box, it was easy to find the <!--Show the image only--> tag and change the code underneath it. Always nice to adjust documented code. :-)

You might also have noticed that I added some ads in the lower part of the sidebar. It doesn't cost the viewer any money to look at them, so it can't be that bad. If you find them annoying, feel free to use ad-blocking extensions like Adblock Plus for Firefox or Adblock for Chrome. I hope most of the people that don't like ads are already using that kind of software.

That's about everything I did today. Those are probably not the things you are reading this blog for, but I hope it will make my coming posts more appealing to read.