MIT2_007s09_lec14_note

MIT2_007s09_lec14_note - MIT OpenCourseWare...

Info iconThis preview shows pages 1–13. Sign up to view the full content.

View Full Document Right Arrow Icon
MIT OpenCourseWare http://ocw.mit.edu 2.007 Design and Manufacturing I Spring 2009 For information about citing these materials or our Terms of Use, visit: http://ocw.mit.edu/terms .
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
2.007 –Design and Manufacturing I Microcomputers, Programming, Electronics, and Sensors Dan Frey 31 MAR 2009 Images removed due to copyright restrictions. Please see http://media.digikey.com/photos/Honeywell%20Photos/BZ-2RW82.jpg http://media.digikey.com/photos/Parallax%20Photos/MFG_30056.jpg http://www2.gpmd.com/imagem/f/mfutl0832.jpg
Background image of page 2
The Homework Board Each pin sources at most 20 milli Amps
Background image of page 3

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
What happens? NOTE: As we discussed in class, the motor will turn accelerating to its no load speed for 5V. Since the connection is to Vdd (not Vin) the motor “sees” 5V from the regulated supply, thus it is essentially independent of the current draw as long as the 9V battery is not dragged down to below 5V. This particular regulator can’t “buck” the voltage back up. BATTERY Figure by MIT OpenCourseWare. Figure by MIT OpenCourseWare.
Background image of page 4
The Basic Stamp Editor
Background image of page 5

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
PBASIC Programming Language name VAR size (BIT, NIB, BYTE, WORD) •I F T H E N •F O R N E X T • GOTO label (define label like -- Loop:) •P U L S O U T pin, period (2 μ sec per unit) • PAUSE period (1 milli sec per unit) •D E B U G OutputData (to your PC screen)
Background image of page 6
Make an LED Flash DO HIGH 14 PAUSE 500 LOW 14 PAUSE 500 LOOP The unit of the PAUSE command is milli seconds, so this line will result in a ½ sec pause. Just a jumper wire is needed because a 220 resistor is built into the pins of the Homework board
Background image of page 7

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
What happens? NOTE: As we discussed in class, the motor will turn accelerating to its no load speed for 5V. Since the connection is to Vdd (not Vin) the motor “sees” 5V from the regulated supply, thus it is essentially independent of the current draw as long as the 9V battery is not dragged down to below 5V. This particular regulator can’t “buck” the voltage back up. BATTERY Figure by MIT OpenCourseWare. Figure by MIT OpenCourseWare.
Background image of page 8
What happens? area makes c “clips”. For m http://en.wikip Figure by MIT OpenCourseWare. BATTERY Figure by MIT OpenCourseWare. NOTE: Same as the last slide. The proto board onnections between the rows of 5 ore background, see edia.org/wiki/Breadboard
Background image of page 9

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
What happens? across the “tro connection wit BATTERY Figure by MIT OpenCourseWare. Figure by MIT OpenCourseWare. NOTE: Nothing happens -- unlike the last slide. The proto board area does not make connections ugh” (unless you make such a h a wire).
Background image of page 10
Memory and Variable types Mouse VAR BIT ' Mouse is a variable that takes values 0 or 1 Cat VAR NIB ' Cat is a variable that uses four bits ‘NOTE: The term “NIB” is short for a “Nibble” which is a small Byte Dog VAR BYTE ' Dog is a variable that uses eight bits Horse VAR Word ' Horse is a variable that that uses 16 bits Dog = 250 ' Assign a value to the byte sized variable DEBUG ? Dog ' Display the result to the screen Dog = 260 ' Try to assign a value larger than the byte data type can hold DEBUG ? Dog ' Display the result to the screen
Background image of page 11

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
http://en.wikibooks.org/wiki/PBASIC_Programming/Loops#FOR_.2F_NEXT
Background image of page 12
Image of page 13
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 02/23/2012 for the course MECHANICAL 2.007 taught by Professor Fry during the Spring '11 term at MIT.

Page1 / 39

MIT2_007s09_lec14_note - MIT OpenCourseWare...

This preview shows document pages 1 - 13. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online