BBC Micro: Bit Recipes: Learn Programming with Microsoft Makecode Blocks


Price:
Sale price$39.99

Description

Chapter 1: Getting in to programming with MakeCodeChapter Goal: This chapter demonstrates some simple programs that can be built with MakeCode to provide context for what follows and introduces you to the Microsoft MakeCode online web editor.
  1. Using MakeCode editor
  2. Display text on the display, one character at a time
  3. Display numbers on the display, one number at a time
  4. Display text on the display, loop it over and over again
  5. Display numbers on the display, loop it over and over again
  6. Pauses the program for a number of milliseconds specified
  7. Displaying icons
Chapter 2: Displaying Images
Chapter Goal: This chapter presents how to display images and control LEDs on the micro: bit display. First, it shows how to display the built-in images. Then, it shows how to create custom images.
  1. Display built-in images
  2. Creating an image
  3. Creating a double-sized image
  4. Images offsetting
  5. Scrolling images
  6. Animating series of images
  7. Creating a flashing effect
  8. Stopping animation
  9. Displaying arrows
  10. Plotting a LED on the display
  11. Unpotting a LED on the display
  12. Toggling a LED
  13. Getting the state of the specified LED
  14. Displaying a vertical bar graph
  15. Clearing screen
  16. Plotting a LED on the screen with specified brightness
  17. Changing brightness of a LED
  18. Getting the brightness of a LED
  19. Turning on or off the display
Chapter 3: Inputs and OutputsChapter Goal: This chapter presents how to use buttons and pins on the micro: bit to handle inputs and outputs.
  1. Using built-in buttons as inputs
  2. Using external buttons
  3. Connecting LEDs
  4. Controlling LEDs
  5. Using potentiometer to control the brightness of a LED
  6. Mapping values
  7. Configuring PWM of the analog output
  8. Controlling servos
Chapter 4: Loops and LogicChapter Goal: The first part of this chapter guides you how to create loops to repeat things for specified number of times and do things while a condition is met. Finally, it presents how to use logical operations on values.
  1. Repeating a thing for specified number of times
  2. Run a sequence of actions while a condition is met
  3. If a value is true, then do some statements
  4. Check whether both inputs are equal each other
  5. Check whether both inputs are not equal each other
  6. Check whether both inputs true
  7. Check whether at least of the inputs is true
  8. Inverse an input
Chapter 5: Using Mathematical FunctionsChapter Goal: This chapter offers how to use the built-in mathematical functions to add, subtract, multiply, or divide numeric values, creating pseudorandom numbers, finding absolute value of a number, calculating remainder, finding max and min values, and convert ASCII characters to text.
  1. Adding numbers
  2. Subtracting numbers
  3. Multiplying numbers
  4. Dividing numbers
  5. Generating random numbers
  6. Generating true and false randomly
  7. Finding remainder
  8. Finding minimum and maximum value
  9. Finding absolute value of a number
  10. Converting ASCII characters to text
Chapter 6: Using VariablesChapter Goal: This chapter presents how to use variables to hold data and use them. First, it shows how to declare different type of variables by initializing them with different type of data. Then, it shows how to get data from variables and process them. Finally, it shows how to change data i

Author: Pradeeka Seneviratne
Publisher: Apress
Published: 07/02/2019
Pages: 352
Binding Type: Paperback
Weight: 1.16lbs
Size: 9.21h x 6.14w x 0.78d
ISBN13: 9781484249123
ISBN10: 1484249127
BISAC Categories:
- Computers | Hardware | General
- Computers | Programming | Games
- Computers | Computer Science

About the Author
Pradeeka Seneviratne is a software engineer with over 10 years of experience in computer programming and systems design. He is an expert in the development of Arduino and Raspberry Pi-based embedded systems and is currently a full-time embedded software engineer working with embedded systems and highly scalable technologies. Previously, Pradeeka worked as a software engineer for several IT infrastructure and technology servicing companies.
Pradeeka is an author of many books: Building Arduino PLCs [Apress], Internet of Things with Arduino Blueprints [Packt], Raspberry Pi 3 Projects for Java Programmers [Packt], Beginning BBC micro: bit [Apress], and Hands-on Internet of Things with Blynk [Packt].