##
7. Units and Conversion

• Units are essential when describing real things.

• Good engineering practice demands that each number should always be accompanied with a unit.

7.1 How to Use Units
• This table does not give an exhaustive list of conversion factors, but instead a minimal (but fairly complete) set is given. From the values below any conversion value can be derived. If you are not sure about this, ask the instructor to show you how.

• A simple example of unit conversion is given below,

7.2 Using SI Units
1. Beware upper/lower case letter in many cases they can change meanings.

e.g. m = milli, mega

2. Try to move prefixes out of the denominator of the units.

e.g., N/cm or KN/m

3. Use a slash or exponents.

e.g., (kg•m/s2) or (kg•m•s-2)

4. Use a dot in compound units.

e.g., N•m

5. Use spaces to divide digits when there are more than 5 figures, commas are avoided because their use is equivalent to decimal points in some cultures.

• In some cases units are non-standard. There are two major variations US units are marked with ‘US’ and Imperial units are marked with ‘IMP’.

7.3 Common Conversion Factors
Major Division

Distance

1 ft. (feet) = 12 in. (inches) = 0.3048 m (meter)

1 mile = 1760 yards = 5280 ft = 1.609km

1 in.(inch) = 2.540 cm

1 yd (yard) = 3 ft.

1 nautical mile = 6080 ft. = 1852 m = 1.150782 mi

1 micron = 10-6 m

1 angstrom = 10-10 m

1 mil = 10-6 in

1 acre = 43,560 ft. = 0.4047 hectares

1 furlong = 660 ft

1 lightyear = 9.460528e15 m

1 parsec = 3.085678e16 m

Area

1 acre = 43,559.66 ft2

1 Hectare (ha) = 10,000 m2

1 Hectare (ha) = 10,000 m2

1 Hectare (ha) = 10,000 m2

1 Hectare (ha) = 10,000 m2

Velocity

1 mph = 0.8689762 knot

Angle

1 rev = 2PI radians = 360 degrees = 400 gradians

1 degree = 60 minutes

1 minute = 60 seconds

Volume

1 US gallon = 231 in3

1 CC = 1 cm3

1 IMP gallon = 277.274 in3

1 barrel = 31 IMP gal. = 31.5 US gal.

1 US gal. = 3.785 l = 4 quarts = 8 pints = 16 cups

1 liter (l) = 0.001 m3 = 2.1 pints (pt) = 1.06 quarts (qt) = 0.26 gallons (gal)

1 qt (quart) = 0.9464 l

1 cup (c) = 0.2365882 l = 8 USoz

1 US oz = 8 US drams = 456.0129 drops = 480 US minim = 1.040842 IMP oz

= 2 tablespoons = 6 teaspoons

1 IMP gal. = 1.201 U.S. gal.

1 US pint = 16 US oz

1 IMP pint = 20 IMP oz

1tablespoon = 0.5 oz.

1 bushel = 32 quarts

1 peck = 8 quarts

Force/Mass

1 N (newton) = 1 kg•m/s2 = 100,000 dyne

1 dyne = 2.248*10-6 lb. (pound)

1 kg = 9.81 N (on earth surface) = 2.2046 lb

1lb = 16 oz. (ounce) = 4.448N

1 oz. = 28.35 g (gram) = 0.2780N

1 lb = 0.03108 slug

1 kip = 1000 lb.

1 slug = 14.59 kg

1 imperial ton = 2000 lb = 907.2 kg

1 metric tonne = 1000 kg

1 troy oz = 480 grain (gr)

1 g = 5 carat

1 pennyweight = 24 grain

1 stone = 14 lb

1 long ton = 2240 lb

1 short ton = 2000 lb

Pressure

1 Pascal (Pa) = 1 N/m2

1 atm (metric atmos.) =760 mmHg at 0°C=14.223 lb/in2=1.0132*105 N/m2

1 psi = 2.0355 in. Hg at 32F = 2.0416 in. Hg at 62F = 6894.8 Pa

1 microbar = 0.1 N/m2

Scale/Magnitude

atto (a) = 10-18

femto (f) = 10-15

pico (p) = 10-12

nano (n) = 10-9

micro (μ) = 10-6

milli (m) = 10-3

centi (c) 10-2

deci (d) = 10-1

deka (da) = 10

hecto (H) = 102

kilo (K) = 103

mega (M) = 106

giga (G) = 109

tera (T) = 1012

peta (P) = 1015

exa (E) = 1018

Power

1 h.p. (horsepower) = 745.7 W (watts) = 2.545 BTU/hr. = 550 ft.lb./sec.

1 ft•lb/s = 1.356 W

1 J (joule) = 1 N•m = 107 ergs = 0.2389 cal.

1 W = 1 J/s

1 ev = 1.60219*10-19 J

1 erg = 10-7 J

Temperature

°F = [(°C*9)/5]+32, °C = Celsius (Centigrade), F = Fahrenheit

K = Kelvin

Rankine (R) = F: 459.666

0.252 calories = 1 BTU (British Thermal Unit)

-273.2 °C = -459.7 °F = 0 K = 0 R = absolute zero

0 °C = 32 °F = 273.3 K = 491.7 R = Water Freezes

100°C = 212°F = 373.3 K = 671.7 R = Water Boils (1 atm. pressure)

1 therm = 100,000 BTU

Mathematical

π radians = 3.1416 radians = 180 degrees = 0.5 cycles

1 Hz = 1 cycle/sec.

1 rpm (revolutions per minute) = 60 RPS (Revolutions per second) = 60Hz

1 fps (foot per second) = 1 ft/sec

1 mph (miles per hour) = 1 mi./hr.

1 cfm (cubic foot per minute) = 1 ft3/min.

e = 2.718

Time

1 Hz (hertz) = 1 s-1

1 year = 365 days = 52 weeks = 12 months

1 leap year = 366 days

1 day = 24 hours

1 fortnight = 14 days

1 hour = 60 min.

1 min = 60 seconds

1 millenium = 1000 years

1 century = 100 years

1 decade = 10 years

Physical Constants

R = 1.987 cal/mole K = ideal gas law constant

K = Boltzmann’s constant = 1.3x10-16 erg/K = 1.3x10-23 J/K

h = Planck’s constant = 6.62x10-27 erg-sec = 6.62x10-34 J.sec

Avagadro’s number = 6.02x1023 atoms/atomic weight

density of water = 1 g/cm3

electron charge = 1.60x10-19 coul.

electron rest mass = 9.11*10**-31 Kg

proton rest mass = 1.67*10**-27 Kg

speed of light (c) = 3.00x1010 cm/sec

speed of sound in dry air 25 C = 331 m/s

gravitational constant = 6.67*10**-11 Nm**2/Kg**2

permittivity of free space = 8.85*10**-12 farad/m

permeability of free space = 1.26*10**-6 henry/m

mean radius of earth = 6370 Km

mass of earth = 5.98*10**24 Kg

Electromagnetic

magnetic flux = weber (We) = 10**8 maxwell

inductance = henry

magnetic flux density = tesla (T) = 10**4 gauss

magnetic intensity = ampere/m = 0.004*PI oersted

electric flux density = coulomb/m**2

capacitance = farad

permeability = henry/m

electric field strength = V/m

luminous flux = lumen

luminance = candela/m**2

1 flame = 4 foot candles = 43.05564 lux = 43.05564 meter-candles

illumination = lux

resistance = ohm

7.4 ASCII, Hex, and Binary Conversion
• The table below will allow conversions between decimal, binary, hexadecimal, and ASCII values. The values shown only go up to 127. ASCII values above this are not commonly used in robust applications.

7.5 G-Codes
• A basic list of ‘G’ operation codes is given below. These direct motion of the tool.

G00: Rapid move (not cutting)

G01: Linear move

G02: Clockwise circular motion

G03: Counterclockwise circular motion

G04: Dwell

G05: Pause (for operator intervention)

G08: Acceleration

G09: Deceleration

G17: x-y plane for circular interpolation

G18: z-x plane for circular interpolation

G19: y-z plane for circular interpolation

G20: turning cycle or inch data specification

G21: thread cutting cycle or metric data specification

G24: face turning cycle

G25: wait for input #1 to go low (Prolight Mill)

G26: wait for input #1 to go high (Prolight Mill)

G28: return to reference point

G29: return from reference point

G31: Stop on input (INROB1 is high) (Prolight Mill)

G33-35: thread cutting functions (Emco Lathe)

G35: wait for input #2 to go low (Prolight Mill)

G36: wait for input #2 to go high (Prolight Mill)

G40: cutter compensation cancel

G41: cutter compensation to the left

G42: cutter compensation to the right

G43: tool length compensation, positive

G44: tool length compensation, negative

G50: Preset position

G70: set inch based units or finishing cycle

G71: set metric units or stock removal

G72: indicate finishing cycle (EMCO Lathe)

G72: 3D circular interpolation clockwise (Prolight Mill)

G73: turning cycle contour (EMCO Lathe)

G73: 3D circular interpolation counter clockwise (Prolight Mill)

G74: facing cycle contour (Emco Lathe)

G74.1: disable 360 deg arcs (Prolight Mill)

G75: pattern repeating (Emco Lathe)

G75.1: enable 360 degree arcs (Prolight Mill)

G76: deep hole drilling, cut cycle in z-axis

G77: cut-in cycle in x-axis

G78: multiple threading cycle

G80: fixed cycle cancel

G81-89: fixed cycles specified by machine tool manufacturers

G81: drilling cycle (Prolight Mill)

G82: straight drilling cycle with dwell (Prolight Mill)

G83: drilling cycle (EMCO Lathe)

G83: peck drilling cycle (Prolight Mill)

G84: taping cycle (EMCO Lathe)

G85: reaming cycle (EMCO Lathe)

G85: boring cycle (Prolight mill)

G86: boring with spindle off and dwell cycle (Prolight Mill)

G89: boring cycle with dwell (Prolight Mill)

G90: absolute dimension program

G91: incremental dimensions

G92: Spindle speed limit

G93: Coordinate system setting

G94: Feed rate in ipm (EMCO Lathe)

G95: Feed rate in ipr (EMCO Lathe)

G96: Surface cutting speed (EMCO Lathe)

G97: Rotational speed rpm (EMCO Lathe)

G98: withdraw the tool to the starting point or feed per minute

G99: withdraw the tool to a safe plane or feed per revolution

G101: Spline interpolation (Prolight Mill)

• M-Codes control machine functions and these include,

M00: program stop

M01: optional stop using stop button

M02: end of program

M03: spindle on CW

M04: spindle on CCW

M05: spindle off

M06: tool change

M07: flood with coolant

M08: mist with coolant

M08: turn on accessory #1 (120VAC outlet) (Prolight Mill)

M09: coolant off

M09: turn off accessory #1 (120VAC outlet) (Prolight Mill)

M10: turn on accessory #2 (120VAC outlet) (Prolight Mill)

M11: turn off accessory #2 (120VAC outlet) (Prolight Mill) or tool change

M17: subroutine end

M20: tailstock back (EMCO Lathe)

M20: Chain to next program (Prolight Mill)

M21: tailstock forward (EMCO Lathe)

M22: Write current position to data file (Prolight Mill)

M25: open chuck (EMCO Lathe)

M25: set output #1 off (Prolight Mill)

M26: close chuck (EMCO Lathe)

M26: set output #1 on (Prolight Mill)

M30: end of tape (rewind)

M35: set output #2 off (Prolight Mill)

M36: set output #2 on (Prolight Mill)

M38: put stepper motors on low power standby (Prolight Mill)

M47: restart a program continuously, or a fixed number of times (Prolight Mill)

M71: puff blowing on (EMCO Lathe)

M72: puff blowing off (EMCO Lathe)

M96: compensate for rounded external curves

M97: compensate for sharp external curves

M98: subprogram call

M99: return from subprogram, jump instruction

M101: move x-axis home (Prolight Mill)

M102: move y-axis home (Prolight Mill)

M103: move z-axis home (Prolight Mill)

• Other codes and keywords include,

Annn: an orientation, or second x-axis spline control point

Bnnn: an orientation, or second y-axis spline control point

Cnnn: an orientation, or second z-axis spline control point, or chamfer

Fnnn: a feed value (in ipm or m/s, not ipr), or thread pitch

Innn: x-axis center for circular interpolation, or first x-axis spline control point

Jnnn: y-axis center for circular interpolation, or first y-axis spline control point

Knnn: z-axis center for circular interpolation, or first z-axis spline control point

Lnnn: arc angle, loop counter and program cycle counter

Nnnn: a sequence/line number

Onnn: subprogram block number

Pnnn: subprogram reference number

Rnnn: a clearance plane for tool movement, or arc radius, or taper value

Qnnn: peck depth for pecking cycle

Snnn: cutting speed (rpm), spindle speed

Tnnn: a tool number

Unnn: relative motion in x

Vnnn: relative motion in y

Wnnn: relative motion in z

Xnnn: an x-axis value

Ynnn: a y-axis value

Znnn: a z-axis value

;: starts a comment (proLight Mill), or end of block (EMCO Lathe)

[an error occurred while processing this directive]