Fighting with computers

Computers are not always friendly.

Saturday, March 29, 2014

Viewing g-code files in Linux and OSX

Working with CNC machines and 3D printers and developing CAM software myself I need a tool to quickly display the 3D view of any g-code file generated. For a while I have been using EMC2 software on Linux and Pleasant3D in OSX. The former was a bit picky about certain commands that were not understood that would prevent the displaying of a file completely. The latter is ok, but being oriented to 3D printers, it is not very convenient when handling files of several square feet. It works but your viewing ability and angles are a bit limited.

After a bit of searching and playing with several potential candidates I have settled with version 0.2.3 of OpenSCAM that I had used in the past on Windows but somehow was not available at the time for OSX or Linux (or I was lazy enough not to try to compile it from the sources myself). Current version worked nicely in OSX and gave me some minor problems in Ubuntu Linux, that could be solved by installing libv8-dev library and doing a soft link. And I really liked the software provides a machining-time estimate, which is great when you are developing different CAM strategies and want to compare them time-wise. 

Other tools I tried but were not up to the task were tatlin, this Python-based viewer and this online tool. Don't get me wrong these tools are ok but have a 3D printer orientation so they are a bit out of the water if fed with other type of g-code. 


Thursday, March 27, 2014

Delta 3D printers

Since the presentation of the Rostock 3D printer, I have been amazed on the kind of motion that these machines make to print a part. While I have found quite hypnotic the way layers are deposited to create plastic part using fused filament fabrication, when the process is done by a delta robot instead of by a cartesian robot, the show is even more interesting.

However the Rostock was a big machine, not compatible with the space I have available at home. But when I saw Richard's 3DR printers, I thought it was a good way for me to venture into the interesting world of this type of printers. Contrary to the Rostock, the 3DR had a small footprint so I built one. But that was just part of the challenge.

Delta 3D printers use three vertical parallel carriages linked by a set of rods to a central platform where the hotend is placed. But contrary to some other printers, those vertical axis are not screw-driven but belt-driven, which allows very fast motion. As a result, Delta 3D printers can move the low-inertia effector very fast accurately. Besides, z-axis speed is no longer restricted compared to the other axis speeds, which enables operations like raising the hotend in z-axis when retracting (before a non-extruding movement).

The second part of the challenge is properly calibrating the printer. A bit more difficult that its equivalent on a cartesian bot. But this is an interesting world where smart people are creating cool innovations on a daily basis. A new feature to auto bed-leveling permits not to have to worry about bed-leveling when using a delta. This make its operation simpler but requires to have a way to detect when the head is touching the bed. Several ways have been developed to do that, like a dedicated retractable switch, proximity switches or even force sensitive resistors on the bed. But the most radical idea was to use the printer to probe itself in order to create its own calibration data.  Just run "G30 A" command and wait your printer to create its own calibration values.

video

Tuesday, March 11, 2014

Of pumps and stepper motors

I have been quite busy lately due to several factors. One of them things not working out as expected. Of course every failure is a learning opportunity and this case, my chance to get familiar with the world of hydraulics and fluid dynamics. As a Computer Scientist, you do not get any training on that matter (other than maybe learning about fans for cooling down electronic parts).

I have been working for more than a year on a project where the least I was expecting was to have trouble with what it is eating a lot of my time lately: pushing a viscous fluid in a precise, controlled-way, from a container to the printing area of a 3D-printer we have designed and successfully built as part of our research project.

If you are familiar with 3D printing, you can think of us trying to create a reliable paste extruder. There are many open paste extruder designs out there, but many are designed for not so viscous pastes or liquids. Others can handle viscous fluids but only a very small amount of it (ie. syringe-based ones). And one effect I have learned is the more viscous the fluid the less likely is to move through a narrow tube. And every inch of tube will increase the need of output pressure in your pump.

Another thing I have learned is that pressurized tubes and 3D printed parts are not a good match, so it is difficult to create your own pump. Or more exactly, it is difficult to achieve a good performance level (ie pressure) with your 3D printed parts.

So I kind of gave up and looked around for pump manufacturers, but those that have small pumps could not work with the viscosity levels I needed. After getting some help from an hydraulics professor, the nice people from Food Technology department came to the rescue and lend us a mono pump that worked great with our material. The only problem being that the pump was powered by a 1CV AC motor driven by a variable frequency drive (VFD) to allow the user select different speeds.

But what we needed was a pump that can start and stop on a dime and that we can precisely control the material flow. That is was not possible with the setup of our pump. So our next step is to replace that motor with an stepper motor we can control.

In the previous blog entry I was visiting a company in Rome helping them out to put to work their home-built CNC machine. They have used powerful nema34 motors.

I thought I could use similar steppers, reaching up to 12.5 Nm of torque, to move a mono pump. The only current problem is that we run out of funds. So I am now in the process of piecing together the paperwork for a funding round to see if we can put the thing together and finally finish our research project successfully.

Till then, most of what I can show does not look pretty:


Thursday, January 16, 2014

First replication

With some friends we created a project a while ago for developing hardware and software for CNC
milling of large 3D sculptures. While one of the ideas was to market the hardware we developed, it does not seem to be a feasible thing to do unless you want to invest a fair amount of cash to get some paperwork done. Not being a fan of paperwork myself and not seeing a clear path to profitability, we have put on hold the idea of marketing such systems.

Another way of broadcasting our developments was to make it open source and help people to replicate our system. The problem is that while some people may want to have a cheap CNC machine, many of them are not in the mood of building it themselves.

But now we have been working with a company in Rome that is willing to do the extra mile and I am flying over to help them get it working. While we suggested one frame, they have gone more conservative and partially build their hardware around MechMate design, but plan on using our Arduino-based CNC controller (which is not much more than a standard Marlin 3D printer firmware).

Tuesday, December 31, 2013

Fighting with online shops too

Today I have got one bizarre experience. A few days ago I did shop some parts for a 3D printer I am building but I guess the site was overloaded (or poorly procured) and I got several errors till I got my order through.

So I decided to ask the seller about my order since a few days have passed without hearing from them. This is the chat transcript.

Start Time: 12/31/2013 00:06:30
End Time: 12/31/2013 00:35:14
Operators: Jayla
Transcripts:  
Please wait for a site operator to respond...
If you do not want to wait, please click here to leave us a message.
Operator Jayla has joined the chat.
[00:06:30] Jayla: Hi Miguel Sanchez, I hope you are doing fine. How may I help you? 
[00:06:38] Miguel Sanchez: HI
[00:06:54] Miguel Sanchez: I'd like to know about my order. 
[00:07:32] Miguel Sanchez: It's been a few days and it is my first order from you. But mostly the server was giving me errors while going through the order.
[00:07:45] Miguel Sanchez: 26 dic 2013 16:18:12 PST Id. de transacción: *****************************
[00:08:00] Miguel Sanchez: these is paypal payment details
[00:09:11] Jayla: Let me check your order. One moment please.
[00:09:18] Miguel Sanchez: thnx
[00:09:51] Miguel Sanchez: please note I did not set up a customer account when I did the order
[00:17:33] Miguel Sanchez: still here ...
[00:20:14] Jayla: I am verifying your payment. Please wait.
[00:20:20] Miguel Sanchez: ok
[00:22:06] Jayla: I have seen that you paid for $30.35 for the order but they did not give you an order number. Please contact paypal regarding that and you can place a dispute on them.
[00:22:40] Miguel Sanchez: You mean that I have paid for nothing?
[00:23:16] Miguel Sanchez: I was expecting to receive some sets of pushrods
[00:24:34] Miguel Sanchez: as I am sourcing from you I expected you do deliver the order or failing to do that, providing me a way for fixing any problem the order may have
[00:25:34] Miguel Sanchez: but if I understand you correctly my payment went through but you have no record of what I ordered nor have you contacted me to solve that. Am i right?
[00:26:24] Miguel Sanchez: And to add insult to injury you ask me to go to paypal to get my money back ? Is that it? (please note this is my first oder from hobby king)
[00:27:18] Miguel Sanchez: or maybe I am not understanding the problem and it is some obscure paypla thing
[00:29:13] Jayla: I understand you sir. In that case I will request for a refund to you because we cant process your order without having order number.
[00:29:57] Miguel Sanchez: wouldn't your company be interested on serving what I ordered?
[00:31:35] Jayla: We have not received any order informations sir. If you want I will process the refund and place an order again. for your next order, Please make an account through our website.
[00:31:38] Miguel Sanchez: it was six sets like this shipped in the cheapest post http://www.*********.com/*********/store/uh_viewitem.asp?idproduct=13099
[00:32:04] Miguel Sanchez: I was offered a discount prize
[00:32:41] Jayla: We can't place an order for you sir for your own security. 
[00:33:23] Miguel Sanchez: I see. Ok, I will like you to forward a copy of this dialog to your CEO.
[00:33:40] Miguel Sanchez: I appreciate your time and I understand you do what you are told to do.
[00:33:44] Miguel Sanchez: Have a nice day.
[00:34:18] Jayla: Thank you for undertsanding sir. Have a great day and Happy Holidays.
The transcript will be sent to "*******************".
The visitor has left the chat.
The chat is ended.


Needless to say: next order from my cold dead fingers. But really, I think these sellers just shoot themselves on the foot. I do understand things may go wrong. I do use PayPal quite a lot as a buyer and I have never before (over 300 transactions) heard such a "problem" from any seller. So I mostly suspect this seller software should be improved and having a more powerful server will help. But hey, you can reduce the number of customers by pissing off first timers, this will sure lower your server's hits too. I will left you as an exercise to figure out who the seller was :-)

Update: PayPal refunded my money. In the mean time I have got a better deal for the same parts at another seller.

Tuesday, December 10, 2013

New tool for the workshop

A recent query from a local company made me revisit the work I did for reverse-engineering Ademco's
ECP bus years ago. I did not get this assignment but I learned this company was buying an inexpensive logic analyzer I have never heard of before.

After having a look a the device and its demo software (that works in Windows, OSX and Linux!!) I was sold. Even better was to learn that they do have an educational discount. Next day I bought one Logic8 8-bit USB digital analyzer.

It is not a digital osciloscope but a logic probe with 8 inputs. The beauty about the software is that it has built-in several serial protocols (ie. Async serial, I2C, SPI, etc). So going from the signals to meaningful data is time-effective and simple.


Monday, November 25, 2013

You get what you pay for ...

Last weekend I have hosted the fourth edition of a workshop where people build their own Prusa i3 3D printer. Trying to learn from past mistakes I attempted to cover all the basis, but unexpected things always come up. 

But what got me really angry was the poor quality of one of the boards we used. Once I realize that boards were like that, I double-checked each one, tracing back with the schematics the different pins involved in any faulty behavior observed. Re-soldering those pins did solve the issues discovered, but it was a painful and time-consuming operation, on hardware you already paid for and expected some QA on. (Well ... don't). 

This is the letter I sent to the manufacturer.


Hi,

In my last workshop I have used 10 of your RAMPS 1.4 boards. In a previous communication I reported 3 out of 10 boards showing some fault. Because of that, this time I checked all the boards in advance. What I saw was a mess: 7 out of ten showed some malfunction. I used several hours fiddling with them till I've got all sorted out. All problems were due to faulty solder work (whether it is the solder material or the work, I do not know).

What's even worse, three of these boards crap on me when people connected them during the workshop (not sure they were the three that worked ok for me during the initial test) forcing me to have to fix them on the fly. (Mechanical stress during insertion might have trigger the fault as these were already tested by me).

I find all the above totally unacceptable, and while I am not planning to use your hardware in the near future, I wanted you to know why, before I mention it to other people.

Maybe you should consider to add a new line of product of "Known to work" or "fully tested" RAMPS boards. I cannot understand how such an awful statistics are possible unless boards are not tested at all. (By testing I mean some real test. Just putting a sticker on them does not apply).

Kind regards,

Miguel Sánchez
Valencia, Spain