User:Mike Barnkob/Projects/Liquid handling robot: Difference between revisions

From OpenWetWare
Jump to navigationJump to search
No edit summary
Line 39: Line 39:


'''Tuesday:'''
'''Tuesday:'''
Continued working on the dispensing handling. Created a successful design with two motors that press down on the pipet. I'm a bit nervous about the stress on the motor, but for now they seem to do fine.
The battery in one of the NTX bricks already ran out. I've ordered a rechargeable battery - but no transformer, since they are not sold here. Hopefully the inlet will accepts other transformers as well.
Programmed two aspiration and dispensing programs, called 'asp & disp 1 and 2 (16-03-10).c'. The code for asp & disp 2 is:
<code>#pragma config(Motor,  motorA,          motor_A,      tmotorNormal, PIDControl, encoder)
#pragma config(Motor,  motorB,          motor_B,      tmotorNormal, PIDControl, encoder)
//*!!Code automatically generated by 'ROBOTC' configuration wizard              !!*//
//DECLARING FUNCTIONS
//Control of the dispenser
void DispensControl (int DCmotor, int DCencode, int DCpause) {
  //Syncronizing motors
  nSyncedMotors = synchAB;
  nSyncedTurnRatio = +100; // Left motor turns 100% of right motor
  //Power up
  while( !(nMotorEncoder[motor_A]==DCencode) ) {
    motor[motor_A]=DCmotor;
    nxtDisplayClearTextLine(5);
    nxtDisplayClearTextLine(6);
    nxtDisplayString (5,"%d, %d", nMotorEncoder[motorA],nMotorEncoder[motorB]);
    nxtDisplayString (6,"%d, %d", DCencode, DCmotor);
    wait1Msec (1);
  }
  motor [motorA] = 0;
  //End pause if any
  wait10Msec(DCpause);
}
//MAIN TASK
task main () {
  nxtDisplayString (1,"DISPENSING 2");
  nMotorEncoder [motor_A] = 0;
  //Air-out
  nxtDisplayClearTextLine(3);
  nxtDisplayString (3,"Air-out");
  DispensControl(30, 30, 0);
  DispensControl(70, 60, 250);
  //Aspiring
  nxtDisplayClearTextLine(3);
  nxtDisplayString (3,"Aspiring");
  DispensControl(-15, 0, 250);
  //Dispensing
  nxtDisplayClearTextLine(3);
  nxtDisplayString (3,"Dispensing");
  DispensControl(30, 40, 0);
  DispensControl(70, 80, 250);
  //Resetting
  nxtDisplayClearTextLine(3);
  nxtDisplayString (3,"Resetting");
  DispensControl(-15, 0, 250);
}</code>

Revision as of 02:44, 17 March 2010

Liquid handling robot

Introduction

Background

Ressources

Software

Hardware

Knowledge

Ideas

Notebook

Week 1

Monday: Worked on the primary handling operation with a very simpel design and set up the lab space.

The linear actuator works up to aboout 1,6 cm, putting a limit on how much the pipet can be pushed down. Solutions might be: using two actuators, using a rail-design instead or adding more power to the actuator.

The design is becoming quite big. Solution might be to use the power function powers, which are smaller.

The pipet needs to be tested for accuracy.

Tuesday: Continued working on the dispensing handling. Created a successful design with two motors that press down on the pipet. I'm a bit nervous about the stress on the motor, but for now they seem to do fine.

The battery in one of the NTX bricks already ran out. I've ordered a rechargeable battery - but no transformer, since they are not sold here. Hopefully the inlet will accepts other transformers as well.

Programmed two aspiration and dispensing programs, called 'asp & disp 1 and 2 (16-03-10).c'. The code for asp & disp 2 is:

#pragma config(Motor, motorA, motor_A, tmotorNormal, PIDControl, encoder)

  1. pragma config(Motor, motorB, motor_B, tmotorNormal, PIDControl, encoder)

//*!!Code automatically generated by 'ROBOTC' configuration wizard  !!*//

//DECLARING FUNCTIONS

//Control of the dispenser void DispensControl (int DCmotor, int DCencode, int DCpause) {

 //Syncronizing motors
 nSyncedMotors = synchAB;
 nSyncedTurnRatio = +100; // Left motor turns 100% of right motor
 //Power up
 while( !(nMotorEncoder[motor_A]==DCencode) ) {
   motor[motor_A]=DCmotor;
   nxtDisplayClearTextLine(5);
   nxtDisplayClearTextLine(6);
   nxtDisplayString (5,"%d, %d", nMotorEncoder[motorA],nMotorEncoder[motorB]);
   nxtDisplayString (6,"%d, %d", DCencode, DCmotor);
   wait1Msec (1);
 }
 motor [motorA] = 0;
 //End pause if any
 wait10Msec(DCpause);

}


//MAIN TASK task main () {

 nxtDisplayString (1,"DISPENSING 2");
 nMotorEncoder [motor_A] = 0;
 //Air-out
 nxtDisplayClearTextLine(3);
 nxtDisplayString (3,"Air-out");
 DispensControl(30, 30, 0);
 DispensControl(70, 60, 250);
 //Aspiring
 nxtDisplayClearTextLine(3);
 nxtDisplayString (3,"Aspiring");
 DispensControl(-15, 0, 250);
 //Dispensing
 nxtDisplayClearTextLine(3);
 nxtDisplayString (3,"Dispensing");
 DispensControl(30, 40, 0);
 DispensControl(70, 80, 250);
 //Resetting
 nxtDisplayClearTextLine(3);
 nxtDisplayString (3,"Resetting");
 DispensControl(-15, 0, 250);

}