Jianlin Cao

Update 3

• Final

The body is made from a section of poster tube with vinyl on it. As a minion, it start with the most common yellow colour body until I realise that we run out of yellow ABS/PLA to match the colour.

images

So, i change it to my favourite colour, red.

images images

Glasses for minion

images

And eyeballs with support generated by meshmixer.

images

Finished eye assembly

images

The heart of minion, the microcontroller and motor driver board. (with a fault on mcu pin, fixed by flywire)

images

A sad face due to countless fallen down during PID tuning

images

And dead eventrully

images

Get the files

You can download the source files directly.

Week 17: Invention, Intellectual Property, and Income

• Assignments

This week’s assignments

develop a plan for dissemination of your final project

License

For everything on this website, i would like to release them under ‘Creative Commons Attribution 4.0 International Public License’. This project was made for fab academy 2015 final project. Most of code are based on open source software and i have no plan for commerciallise. This project will remian open source.

Share — copy and redistribute the material in any medium or format
Adapt — remix, transform, and build upon the material for any purpose

More detail could be found from here.

Week 16: Mechanical Design, Machine Design

• Assignments

This week’s assignments

make a machine, including the end effector
build the passive parts and operate it manually
document the group project and your individual contribution

My main job is that find a way to convert pictures to files that could be read by our drawing machine.

Start with software called ‘StippleGen_2’ to generate .svg file for next step. It solves the classic traveling sales man problem that is almost exactlly what we want.

images images

Then the .svg file is converted to both python code and .csv for drawing machine by the following matlab code.

function csv_gen(file_name,maximum_size)

%file_name='evil_minion'; maximum_size=200;

%read svg to text
[data, result]= readtext(sprintf('%s.svg',file_name),' ');

%read coordinates from text
m=1;
for n=1:result.rows
   if isnumeric(cell2mat(data(n,1))) & ~isempty(cell2mat(data(n,1)))
       if isnumeric(cell2mat(data(n,2))) & ~isempty(cell2mat(data(n,2)))
           coor(m,1)=cell2mat(data(n,1));
           coor(m,2)=cell2mat(data(n,2));
           m=m+1;
       end
   end
end

min_coor=min(coor);
for n=1:length(coor)
    coor_shifted(n,:)=coor(n,:)-min_coor;
end

%re-scale to 200mm size
coor_a=coor_shifted*maximum_size/(max(max(coor_shifted)));

% %convert to relative coordinates
% coor_r=coor_a(1,:);
% for n=2:length(coor_a)
%     coor_r(n,:)=coor_a(n,:)-coor_a(n-1,:);
% end

%generate .csv file
csvwrite(sprintf('%s.csv',file_name),coor_a);
%csvwrite(sprintf('%s_r.csv',file_name),coor_r);

%generate python code in .txt
fid = fopen(sprintf('%s.txt',file_name),'wt'); 
fprintf(fid,'moves = [');
fprintf(fid,'[%d,%d]',coor_a(1,1),coor_a(1,2));
for n=2:length(coor_a)
    fprintf(fid,',[%d,%d]',coor_a(n,1),coor_a(n,2));
end
fprintf(fid,']');
fclose(fid);

% fid = fopen(sprintf('%s_r.txt',file_name),'wt'); 
% fprintf(fid,'moves = [');
% fprintf(fid,'[%d,%d]',coor_r(1,1),coor_r(1,2));
% for n=2:length(coor_a)
%     fprintf(fid,',[%d,%d]',coor_r(n,1),coor_r(n,2));
% end
% fprintf(fid,']');
% fclose(fid);

plot(coor_a);

Update 2

• Final

Due to the budget limit which i didn’t realised at the very beginning. I have decide to make a new ‘fab academy’ version of my old balanced robot prototype.

Week 15: Applications and Implications

• Assignments

This week’s assignments

propose a final project that integrates the range of units covered:
  what will it do?

  	Self balance, remote controlled minion

  who's done what beforehand?

  	Errr..almost everything. There are tons of balanced robot design online availiable already. The unique feature of this one is the BLDC motors. And it is pretty similar as the brushless gimbal.

  what materials and components will be required?

  	Still..almost everything. 3d printed body, brushless motor, wheel, etc..

  where will they come from?

  	My electronic 'magic' box and old projects

  how much will it cost?

  	BLDC motor £8 each

  	the rest could be sourced from fablab or my old projects

  what processes will be used?

  	Atmega328p

  what tasks need to be completed?

  	Modify gimbal controller board software, PID tunning

  how will it be evaluated?

  	Self balance stand would be a good point to start with.

Week 14: Interface and Application Programming

• Assignments

This week’s assignments

write an application that interfaces with an input &/or output device

A very simple board is created with msp430g2553 and programed with Energia.

images

Mini USB connector is for power only.

images

Jumper wires from TI Launchpad

images

The board is connect to a bluetooth module (HC-05) via serial port.

An android app was created to receive data via bluetooth and plot them in real time. (This app is created as a favour to my friend, thus the interface is in chinese.)

images

Code

#define A_INPUT A6
#define D_INPUT P1_6

int adc;
int index=0;

void setup()
{
  Serial.begin(9600);
}
void loop()
{
  adc=analogRead(A_INPUT);
  Serial.write('1\t');
  Serial.write(index);
  Serial.write('\t');
  Serial.write(adc);
  Serial.write('\n');
  index++;
  delay(100);
}

Get the files

You can download the source files directly.

Week 13: Networking and Communications

• Assignments

This week’s assignments

design and build a wired &/or wireless network connecting at least two processors

images

A wired SPI connection is created between the board from ‘input’ and ‘output’ weeks. The power is provided via output connector on ‘output’ board.

The idea is used the sensor from ‘input’ board and send the value to ‘output’ board via SPI.

Week 12: Composites

• Assignments

This week’s assignments

design and make a 3D mold (~ft2), and produce a fiber composite part in it

What is my most favourite composite? Carbon fiber!

CNC machining the body of the boat from ‘thunder in paradise’

images images

Applying layers of glass fiber and carbon fiber to foam mold

images

Inside vacuume bag

images

Finished surface of special eproxy resin

images images

Compared to original foam mold images

Do not wash unfinished carbon fiber unless you have a heat gun! images

Tools Related CNC Router: Denford MRC40 6mm @ 3000 RPM Cut depth: 5mm Feed speed: 1000mm/min Start with 15% overlap Refined with 15% overlap Software: VR Milling V5 Bonus

3mm carbon fiber board test

images

Get the files

You can download the source files directly.

Week 11: Output Devices

• Assignments

This week’s assignments

add an output device to a microcontroller board you've designed and program it to do something

A very simple board that designed to control WS2812 RGB LEDs.

images images images

Code

#include <Adafruit_NeoPixel.h>
#include <avr/power.h>

#define PIN            4
#define NUMPIXELS      3

Adafruit_NeoPixel pixels = Adafruit_NeoPixel(NUMPIXELS, PIN, NEO_GRB + NEO_KHZ800);

int delayval = 50; // delay for half a second
int index=0;
int last_index=0;
int last_last_index=0;
char order=0;
void setup() {
  // This is for Trinket 5V 16MHz, you can remove these three lines if you are not using a Trinket
#if defined (__AVR_ATtiny85__)
  if (F_CPU == 16000000) clock_prescale_set(clock_div_1);
#endif
  // End of trinket special code

  pixels.begin(); // This initializes the NeoPixel library.
}

void loop() 
{ 
  pixels.setPixelColor(last_last_index, pixels.Color(0,0,0));
  last_last_index=last_index; 
  pixels.setPixelColor(last_index, pixels.Color(20,0,0));
  last_index=index;
  if(order)
  {
    pixels.setPixelColor(index, pixels.Color(50,0,0));
    index++;
    if(index>=(NUMPIXELS-1)) 
    {
      order=0;
    }
  }
  else
  {
    pixels.setPixelColor(index, pixels.Color(100,0,0));
    index--;
    if(index<=0) 
    {
      order=1;
    }
  }
  pixels.show();
  delay(delayval);
}

Get the files

You can download the source files directly.

Week 10: Input Devices

• Assignments

This week’s assignments

measure something: add a sensor to a microcontroller board that you've designed and read it

TCRT 5000 is a reflective optical sensor with transistor that typically used by line followers. It is a simple analog sensor.

PCB

images

Top View

images

Side View

images

The LED with flashing in different speed according to the input.

Code

#define LED 3
#define IR A2
int adc=0;

void setup()
{
  pinMode(LED, OUTPUT);
}

void loop()
{
  digitalWrite(LED,HIGH);
  adc=analogRead(IR);
  delay(adc);
  digitalWrite(LED,LOW);
  delay(256-adc);  
}

Get the files

You can download the source files directly.

Week 9: Molding and Casting

• Assignments

This week’s assignments

design a 3D mold, machine it, and cast parts from it

Process

Machining the wax by Roland Modela.

images

Create negative mold by cold curing rubber.

images

Wax mold done!

images

Negative mold.

images

Casted part (white)

images

Eproxy Resin Bonus

images

Get the files

You can download the source files directly.

Week 8: Computer Controlled Machining

• Assignments

This week’s assignments

make something big

Result

Two different materials are used to cut this seat, that’s the reason why the appearence is keep changing.

images

The little leftover to prevent the pieces form move.

images

The ‘worst’ looking one.

images

The ‘better’ looking one. And the one that i actually took home.

images

Apply ‘carbon fiber’ vinyl to the top for an even better looking.

images

Love it!

images

Week 7: Embedded Programming

• Assignments

This week’s assignments

read a microcontroller data sheet
program your board to do something,
with as many different programming languages and programming environments as possible

Code

This code is based on arduino firmware. Press the button to increase the brightness of LED.

#define LED 3
#define BUTTON 4
int brightness=0;

void setup()
{
  pinMode(LED, OUTPUT);
  pinMode(BUTTON, INPUT);
}

void loop()
{
  analogWrite(LED,brightness);
  
  if(digitalRead(BUTTON))
  {
    brightness++;
  }
  if(brightness>255)
  {
    brightness=0;
  }
  delay(10);
}

images

Week 6: Electronics Design

• Assignments

This week’s assignments

redraw the echo hello-world board
add (at least) a button and LED (with current-limiting resistor)
check the design rules, and make it
extra credit: simulate its operation

Result

This assigment is basicly covered by the fabisp week. But i do got a new ‘hello-world’ board redesigned.

PCB

images images

Knife cleaned PCB images

Completed ‘Hello World’ board images

#define LED 3
#define BUTTON 4

void setup()
{
  pinMode(LED, OUTPUT);
  pinMode(BUTTON, INPUT);
}

void loop()
{
  if(digitalRead(BUTTON))
  {
    digitalWrite(LED,HIGH);
  }
  else
  {
    digitalWrite(LED,LOW);
  }
  delay(100);  
}

Get the files

You can download the source files directly.

Week 5: 3D Scanning and Printing

• Assignments

This week’s assignments

design and 3D print an object (small, few cm) that could not be made subtractively
3D scan an object (and optionally print it)

3D Print

3D printer is a great for fast prototyping and they are right! (if you know how to use it)

Here is my battry tray replica for GUAI X3 RC helicopter.

The 3D model is designed in Fusion 360 which is a free cross-platform modelling software.

It is printed using Makerbot 2X with raft and support to protect the ABS from ‘curve’.

images

Compared to the original part, which cost £6.49 for 2.

images

And it fits perfectly!

images

3D Scan

The scanner that used in fab strathclyde is hand holded Sense 3D scanner, thus we decide to scan each other.

images

Here is the digital scan of me by Iain Chalmers test fitting my Iron Man helmet. images images

Bonus! My own minion! (hence the JC logo) images

Get the files

You can download the source files directly.

Week 4: Electronic Production

• Assignments

This week’s assignments

make the FabISP in-circuit programmer

What I have done

First, ignore the png file immediately, which is not considered as a decent solution.

Thanks to the fabTinyStar which has the eagle format schemetics file available.

PCB Design

images

The PCB is engraved by Denford PCB Engraver with floating head.

Engraved PCB

images

Finished board

images

Week 3: Computer-Controlled Cutting

• Assignments

This week’s assignments

design, make, and document a press-fit construction kit!

And here it is!

The design is a very straight forward press-fit box without lid. The press-fit part has a 0.3mm overlap for tight fit.

The laser cutter used in this project is Epllog 40 which is a 40W CO2 laser. I use the following setting to vector cut the 3mm board.

Speed: 10
Power: 100
Frequency: 500

images images images images

Miata Is Always The Answer!!

Even for late added vinyl cutting task.

Here are the vinyl cutted logo for the 25th anniversary of the world best selling roadster, Mazda MX-5 or Miata for US. The vinyl cutter used in this project is Roland GX24 with all default settings.

images

Get the files

You can download the source files for press-fit box directly.

Week 2: Computer-Aided Design

• Assignments

This week’s assignments

model (draw, render, animate, simulate, …) a possible final project, and post it on your class page

Basically, it is a remote controlled balanced robot. All the fancy part of this final project are well hidden in the software.

But, It does have a very lovely body to post.

images

The model is for demostration only. The body is made by a section of tube and the head is 3D printed which documented in the page of final project update 3.

Get the files

You can download the source files for press-fit box directly.

Update 1

• Final

My current plan for final project is a MYO controlled 4WD car. And it would allow conventional radio control for more fun.

The rear wheels are driven by BLDC motors directly for a higher top speed. The electronic speed controller (ESC) for them are specially design multicopter ESCs with reverse direction supported.

The front wheels would be driven by special BLDC motors designed for gimbals. This motor features high torque which is necessary for start. The front wheels and motors are connected via a single direction bearing to reduce the drag after start.

Therefore, the car is front wheel drive during the start and rear wheel drive after start.

A on-board 6DOF inertial measurement unit (IMU) is used for stability and traction control, apply the break to each wheel when necessary.

All wheel would be fitted with a simple push-rod suspension for better handling.

Overall, this would be a miniature version of modern hypercars, with a lot of fancy electronic systems.

A simple block diagram show below. (which i forgot to add the steering after MCU)

draft

Week 1: Principles and Practices, Project Management

• Assignments

This week’s assignments

build a personal site in the class archive describing you and your final project

Fablab logo

This week’s tasks are create a html webpage to document work for the rest of weeks and made commits in the fab academy archive.

If you can see this website, that means its done! Cheers