# Cycling machine

Recently I had a problem at work, where I had to cycle some membranes with water pressure for 50000 cycles and then repeat the procedure two more times. This is what I did…

(This is a live project and is updated regularly.)

# Goal

The goal of the machine is being able to adjust and execute:

• number of cycles from 1…100000,
• duty cycle from 1…99% and
• cycle time from 1…100 s,

as shown in Figure 1.

Duty cycle is defined as:

$Latex formula$

# The machine

The heart of the machine is Arduino Uno. It runs on 5 V DC, so the voltage needed to be stepped-down from 24 V to 5 V.

For powering the Arduino I used the power module as described in one of my previous projects (conveniently named Arduino 5 V power supply). In short the base of the power supply is LM2575T step-down switching supply, which is a very efficient circuit.

I wanted the machine to output 24 V DC, because there are many industrial devices, that require 24 V DC, for example a spool of a 5/2 pneumatic valve like the one in Figure 2.

## Circuit

I will not be the only one using this machine, so I wanted a user to intuitively be able to configure and run this machine. I consider this good design practice. After the program is uploaded to this machine, there is no need for a computer anymore.

The cycling machine is configured by 4 potentiometers, wired as voltage dividers to analog inputs A0…A3:

3. Number of cycles adjustment 1…10
4. Multiplier of number of cycles 1, 10, 100, 1000, 10000.

There are two buttons to run/pause the machine and reset the number of cycles.

An LED is used as an indicator of output stage, to indicate whether the voltage at the output is ON or OFF.

## Program

The program architecture is based on the Moore state machine, which granted a lot of flexibility when I had to add functionalities later in the project.

The code is published right here…

# Conclusion

A very primal function was achieved with this machine. Applying pressure in regular cycles or turning something ON/OFF for a specified number of cycles is in my opinion a basic test, very useful to determine durability of a part or assembly.

This machine saved our company a lot of time and money and hopefully it will save you some too.

There are other ways to execute the same function and I would love to hear how you would tackle this problem.

Until next time… Don’t be afraid to make mistakes. I do them all the time.

# TAPR and GPL open source licenses

The plans and code are published under TAPR and GPL licenses.