- Published: Monday, 10 December 2012
- Written by Rangerbob
Anyone who has used the Arduino libraries will have probably come across the "millis" command. This useful function allows the user program to time events in millisecond resolution. In Swordfish I have mostly seen complex timer setups, or wasteful delay loops to perform similar operations. After having used the Swordfish Ethernet libraries for a while, I discovered a particular gem buried in it; the tick.bas module. In the ethernet libraries it is used for keeping track of various bits of timing, but I realised that it would work perfectly well standalone. I have been using for various projects for a while now and using tick.bas gives us the same millis functionality with minimal setup.