TINKER PiEDESIGN IN INDIA
Intermediate

Spinning Shape GalleryMake a row of colourful shapes and spin them for ever with a loop.

You write a short TinkerPie Python program by following the Code guide in the workspace, then press Run. The sample program and step-by-step guide are always there to help.

What you will learn

  • Lists of objects
  • for loops with range()
  • Animation with small steps

What you need

  • Any laptop, tablet or phone. For VR: a phone and a phone VR viewer (TinkerPie VR viewer or any phone headset)

Steps

  1. Type the program from the Code guide, then press Run.
  2. Watch the shapes spin.
  3. Try VR headset mode on a phone.

How it works

Animation is many small changes shown quickly. Each loop turns every shape by 3 degrees and waits 0.03 seconds, so they spin smoothly.

Coding concepts

range()
range(6) gives 0 to 5.
Animation
Small changes, repeated quickly.

Expected output

Six shapes in a row, in six colours, spinning at night under the stars.

Challenges

  • Make the balls bounce up and down instead.
  • Spin every second shape the other way.
  • Add your name as a sign.

More AR/VR projects

Intermediate20 minAR / VR, Gesture Recognition

AR Air Drawing

Draw glowing lines in the air with your fingertip; open your hand to wipe the picture.

  • Fingertip tracking
  • Drawing with points
  • Pen up / pen down logic
Hardware: Laptop, tablet or phone cameraAI Cube: Virtual Cube only · Virtual Cube: laptop or phone camera
Intermediate15 minAR / VR, Gesture Recognition

AR Magic Hands

Make stars appear on your hands, and hearts when you show a thumbs up.

  • Stickers on hands
  • Gestures that change AR
  • Counting hands
Hardware: Laptop, tablet or phone cameraAI Cube: Virtual Cube only · Virtual Cube: laptop or phone camera
Intermediate20 minAR / VR

Night Forest Walk

Grow a random forest under the stars and walk through it in VR.

  • Random positions
  • Loops that build worlds
  • Exploring a scene in VR
Hardware: Any device; a phone VR viewer for headset modeAI Cube: Virtual Cube only · Virtual Cube: laptop or phone camera