Tageloquent

Eloquent bounded waiting: the await construct

Sometimes you may need to wait for a certain condition to become true, but you don't want to wait forever: it may be awaiting for Serial, for the Wifi to connect to a network, or the response from a SoftwareSerial peripheral. The await construct lets you put an upper bound to the time you're willing to wait.

Continue reading

Eloquent non-blocking code: the Every construct

The every construct lets you run a piace of code at regular intervals in a fluent way. If you don't need to start, stop, pause your timer, this construct is a valid alternative to more complex timer libraries already available: it only takes a time interval as argument and will execute the code block periodically.

Continue reading

How to write clean Arduino code: introducing the Eloquent library

Eloquent Arduino is an attempt to bring sanity and clarity in Arduino projects. The purpose of this library is to create a wide range of constructs to clearly translate your ideas into meaningful code: stop writing spaghetti code only you can undestand, please! I'll show you how.

Continue reading