The Gameduino 2 Tutorial, Reference and Cookbook James Bowman
[email protected] Excamera Labs, Pescadero CA, USA c 2013, James Bowman All rights reserved First edition: December 2013 Bowman, James. The Gameduino 2 Tutorial, Reference and Cookbook / James Bowman. – 1st Excamera Labs ed. 200 p. Includes illustrations, bibliographical references and index. ISBN 978-1492888628 1. Microcontrollers – Programming I. Title Contents I Tutorial 9 1. Plug in. Power up. Play something 11 2. Quick start 13 2.1. Hello world...................................... 14 2.2. Circles are large points.............................. 16 2.3. Color and transparency.............................. 18 2.4. Demo: fizz....................................... 20 2.5. Playing notes..................................... 21 2.6. Touch tags....................................... 22 2.7. Game: Simon..................................... 24 3. Bitmaps 29 3.1. Loading a JPEG................................... 30 3.2. Bitmap size...................................... 31 3.3. Bitmap handles.................................... 34 3.4. Bitmap pixel formats................................ 36 3.5. Bitmap color...................................... 38 3.6. Converting graphics................................ 39 3.7. Bitmap cells...................................... 40 3.8. Rotation, zoom and shrink............................ 42 4. More on graphics 47 4.1. Lines........................................... 48 4.2. Rectangles....................................... 50 4.3. Gradients.......................................