We'll explore introductory "Physical Computing" which is about writing software that interact with real things. Like, Pyxel, a robot "dog."
We'll use a block-based, drag-and-drop code editor, which is easy to use for first-time software engineers!
(It's like MIT Scratch, if you've seen that before.)
The Pyxel has these inputs:
touch sensor (above the nose)
proximity sensor (in front of the nose)
sound sensor
The Pyxel has these outputs:
sounds, lights, eye expressions
motion of legs, tail, body
moving forward and backward
The Program controls what all the outputs, in reaction to the sensors/inputs.
The Pyxel program commands include logic (if ... then), loops (do something some number of times), math (add, subtract, multiply, divide), and computer science ideas.
The program can very simple "When the touch sensor is touched, turn on the blue LED" or more complex "Move forward until the proximity sensor detects an obstacle (such as a wall) then move backward, turn to get away from the obstacle."
Here's an example of a simple Pyxel "Blockly" program: Let's demonstrate it and explains what it does.
introDemo.txt (you can download this program, then upload in the Pyxel Blocky editor.)