Merge of makerbot/replicatorg head (version 40 I believe) into my fork.