Junk Box arduino Ten Projects in Upcycled Electronics — The Ultimate Arduino-Hacker’s Playground Guide — James R. Strickland Junk Box Arduino Ten Projects in Upcycled Electronics James R. Strickland Junk Box Arduino: Ten Projects in Upcycled Electronics James R. Strickland Highlands Ranch, Colorado, USA ISBN-13 (pbk): 978-1-4842-1426-8 ISBN-13 (electronic): 978-1-4842-1425-1 DOI 10.1007/978-1-4842-1425-1 Library of Congress Control Number: 2016944327 Copyright © 2016 by James R. Strickland This work is subject to copyright. All rights are reserved by the Publisher, whether the whole or part of the material is concerned, specifically the rights of translation, reprinting, reuse of illustrations, recitation, broadcasting, reproduction on microfilms or in any other physical way, and transmission or information storage and retrieval, electronic adaptation, computer software, or by similar or dissimilar methodology now known or hereafter developed. Exempted from this legal reservation are brief excerpts in connection with reviews or scholarly analysis or material supplied specifically for the purpose of being entered and executed on a computer system, for exclusive use by the purchaser of the work. Duplication of this publication or parts thereof is permitted only under the provisions of the Copyright Law of the Publisher’s location, in its current version, and permission for use must always be obtained from Springer. Permissions for use may be obtained through RightsLink at the Copyright Clearance Center. Violations are liable to prosecution under the respective Copyright Law. Trademarked names, logos, and images may appear in this book. Rather than use a trademark symbol with every occurrence of a trademarked name, logo, or image we use the names, logos, and images only in an editorial fashion and to the benefit of the trademark owner, with no intention of infringement of the trademark. The use in this publication of trade names, trademarks, service marks, and similar terms, even if they are not identified as such, is not to be taken as an expression of opinion as to whether or not they are subject to proprietary rights. Permission granted by ANSI on behalf of INCITS to use material from X.3221-1994. The X3.221 is a withdrawn standard and cannot be referred to as an approved document. Information about this withdrawn standard is provided for historical interest only and should not be used for new designs. All copyrights remain in full effect. All rights reserved. While the advice and information in this book are believed to be true and accurate at the date of publication, neither the authors nor the editors nor the publisher can accept any legal responsibility for any errors or omissions that may be made. The publisher makes no warranty, express or implied, with respect to the material contained herein. Managing Director: Welmoed Spahr Lead Editor: Jonathan Gennick Development Editor: James Markham Technical Reviewer: Terry King and Andrew Terranova Editorial Board: Steve Anglin, Pramila Balen, Louise Corrigan, Jim DeWolf, Jonathan Gennick, Robert Hutchinson, Celestin Suresh John, James Markham, Susan McDermott, Matthew Moodie, Douglas Pundick, Ben Renow-Clarke, Gwenan Spearing Coordinating Editor: Melissa Maldonado Copy Editor: Laura Lawrie Compositor: SPi Global Indexer: SPi Global Artist: SPi Global Distributed to the book trade worldwide by Springer Science+Business Media New York, 233 Spring Street, 6th Floor, New York, NY 10013. Phone 1-800-SPRINGER, fax (201) 348-4505, e-mail o [email protected] , or visit w ww.springer.com . Apress Media, LLC is a California LLC and the sole member (owner) is Springer Science + Business Media Finance Inc (SSBM Finance Inc). SSBM Finance Inc is a Delaware corporation. For information on translations, please e-mail [email protected] , or visit w ww.apress.com . Apress and friends of ED books may be purchased in bulk for academic, corporate, or promotional use. eBook versions and licenses are also available for most titles. For more information, reference our Special Bulk Sales–eBook Licensing web page at w ww.apress.com/bulk-sales . Any source code or supplementary materials referenced by the author in this text is open source and available to readers at w ww.apress.com . For detailed information about how to locate your book’s source code, go to www.apress.com/source-code/ . Printed on acid-free paper For Marcia, who’s been very patient with little bits of wire everywhere. Contents at a Glance About the Author ............................................................................xix About the Technical Reviewers ......................................................xxi Introduction ..................................................................................xxiii How to Use This Book .....................................................................xxv ■ Chapter 1: Your Shopping List ........................................................1 ■ Chapter 2: Cestino ........................................................................29 ■ Chapter 3: Kick the Tires, Light the Fire .......................................55 ■ Chapter 4: 8 Bit Ports ...................................................................81 ■ Chapter 5: Collector, Base, and Emitter ......................................103 ■ Chapter 6: TTL: The Missing Link ...............................................125 ■ Chapter 7: Logic Probe ...............................................................149 ■ Chapter 8: EPROM/Flash Explorer ..............................................161 ■ Chapter 9: ATA Explorer ..............................................................203 ■ Chapter 10: Time Out For a Quick Game .....................................271 ■ Chapter 11: Z80 Explorer ............................................................303 Index ..............................................................................................399 v Contents About the Author ............................................................................xix About the Technical Reviewers ......................................................xxi Introduction ..................................................................................xxiii How to Use This Book .....................................................................xxv ■ Chapter 1: Your Shopping List ........................................................1 Tools and Supplies ..................................................................................1 An Arduino ................................................................................................................1 Solderless Breadboards ............................................................................................2 Jumpers (Optional) ...................................................................................................3 Hookup Wire .............................................................................................................4 A Multimeter .............................................................................................................5 Screwdrivers ............................................................................................................6 Wire Cutters/Strippers ..............................................................................................7 USB to 5v TTL Level Serial Cable ..............................................................................8 Optional: A Universal Programmer ..........................................................................10 Software and Documentation ................................................................10 Arduino 1.6.5 or Later .............................................................................................10 ATmega1284p Data Sheet ......................................................................................11 Texas Instruments 74xx00 Data Sheet ...................................................................11 Calculator ...............................................................................................................11 Optional: Adafruit Circuit Playground/Electrodroid .................................................11 vii ■ CONTENTS Parts ......................................................................................................11 A Word On Resistors ...............................................................................................12 A Word On Capacitors .............................................................................................14 Some Words on Junk ..............................................................................................16 Parts by Project .....................................................................................17 Cestino ....................................................................................................................17 Morse Code Practice Translator ..............................................................................19 Larson (Memorial) Scanner ....................................................................................20 Transistor Tester .....................................................................................................21 TTL Tester ...............................................................................................................21 Logic Probe/Injector ...............................................................................................22 ROM/EPROM/EEPROM Explorer ..............................................................................22 ATA Explorer ............................................................................................................24 Dice Device .............................................................................................................25 Z80 Explorer ...........................................................................................................26 Postage Is Not Your Friend ....................................................................28 Summary ...............................................................................................28 ■ Chapter 2: Cestino ........................................................................29 The Stuff You Need ................................................................................30 New Parts ...............................................................................................................30 New or Used Parts ..................................................................................................30 Anatomy of the Cestino .........................................................................31 The ATmega1284P Microcontroller .........................................................................32 20 MHz TTL Full Can Oscillator ...............................................................................35 Placing Components ..............................................................................36 Power Circuits .......................................................................................38 viii ■ CONTENTS A Dab of Ohm’s Law ..............................................................................41 How It Works ...........................................................................................................42 Examples ................................................................................................................42 LED Circuit .............................................................................................43 Clock Circuit ..........................................................................................45 Reset Circuit ..........................................................................................46 TTL RS-232 Circuits ...............................................................................48 RTS-Reset Circuit ...................................................................................................49 TX, RX, and CTS Circuits .........................................................................................50 Testing, Board Layout, and Static ..........................................................52 Credit Where Credit Is Due ....................................................................52 Further ...................................................................................................53 ■ Chapter 3: Kick the Tires, Light the Fire .......................................55 The Stuff You Need ................................................................................55 New Parts ...............................................................................................................55 New or Used Parts ..................................................................................................55 Software .................................................................................................................55 Bootloader and Core ..............................................................................56 Bootloader ..............................................................................................................56 Core ........................................................................................................................56 A Little History of Software Abstraction ..................................................................57 Set Up the Arduino Application ..............................................................57 ISP: In Circuit Programmer ....................................................................58 Arduino as ISP .......................................................................................59 How ArduinoISP Works ...........................................................................................59 Set Up the ArduinoISP Sketch .................................................................................60 Set the Programmer and Board in the Arduino Application ....................................60 ix
Description: