News    The Project    Technology    RoboSpatium    Contribute    Subject index    Download    Responses    Games    Gadgets    Contact   

<<< Software Arduino         Hardware Raspberry >>>

mail2code: Introduction

Video about the mail2code system

About mail2code

I have already shown in many videos and chapters on HomoFaciens how peripheral devices have to be designed in order to be able to use digital signals from General Purpose Input Output pins - more chapters will follow. To start teaching the software side of "Physical Computing", I have now created the "mail2code" project: This gives you the opportunity to remotely program hardware that I have installed on my attic, in order to gain a deeper understanding of microcontrollers. All you need to learn how to program hardware is a device that can send emails and display videos. This works with an ancient laptop, a decrepit tablet or almost any smartphone. A Bluetooth keyboard should be connected to the latter devices, because programming means writing text, even if Hollywood sometimes fools you into believing that it would be enough to push colored symbols around the largest possible screens. In principle, a compact keyboard for programming on the go is sufficient, but a larger version makes writing text much more comfortable. If typing source code in an e-mail program is too cumbersome, you can use any external editor and then either copy and paste the code or attach it to the e-mail as a file. Once the source code has been entered, it can be sent to my mail2code server, which is running on a Raspberry Pi, here. Everything else runs automatically.

A first hardware setup is online

mail2code, first hardware setup
Figure 1:
It is a Raspberry Pi with an Arduino UNO connected to an USB port. A few basic peripherals can be controlled via the Arduino's GPIOs:
With this experimental setup you can learn to program the ATmega328 microcontroller of the Arduino UNO - if you like my project, more microcontrollers will follow.
LEDs serve as a classic entry point into the world of "physical computing". The "digitalWrite()" function switches a pin to logical HIGH or LOW level, which can be visualized most easily with an LED. 8 green LEDs are arranged in a row, which can be used to illustrate the binary system, port programming or bit manipulation, for example. 7 red LEDs are arranged in the pattern of a dice, which will be used to teach pin assignment, arrays or random number generation, among other things.
Then there's a bipolar stepper motor that can be controlled via a driver board with step and directory signals. A magnet is glued to the motor shaft, with which the rotation of the stepper motor can be detected via a corresponding sensor. This makes it possible to explain how to read analogue input signals.
A DC motor with two sensor discs is a little more complex to understand - it can be used to study "closed loop" systems. The two sensor discs are each scanned by 3 light sensors. The orange sensor disc is driven by a 20:1 reduction gear. You can easily count the revolutions of that disc. The green sensor disc is connected to the shaft of the DC motor and therefore rotates very quickly, which is why interrupt routines are required to record the input signals.

Tutorials, Tutorials, Tutorials

Of course I don't want to leave you alone with the hardware and will (have to) therefore write many chapters on the software to teach you how to program machines step by step. If you want to spend me some coins as a motivational injection, go for it! You have the opportunity to do so both on this page and on the newly launched mail2code project page.
Many thanks to everyone who has already sent me an Obol!

You'd like to try it out?

The instructions are still sparse, but anyone who has ever programmed an Arduino UNO will see how it works relatively quickly.
Here you go directly to the page where you can try out the basic setup.
Leave a comment on what could be improved about the system - thanks!

<<< Software Arduino         Hardware Raspberry >>>

News    The Project    Technology    RoboSpatium    Contribute    Subject index    Archives    Download    Responses    Games    Links    Gadgets    Contact    Imprint   

Twitter YouTube Hackaday Patreon TPO