How to rig this simple machine?
As @MohammadHossein has said, it's important to have the length of the link longer than the driving arm.
I think of this as  a 2-bone IK rig, just like a character arm, if you want to look up tutorials on how to do those.

I've labelled the bones by analogy to an arm.

The Fore Arm bone has an IK bone constraint, target: IK Target, Pole:
IK Pole. The chain length is 2, to include the Upper arm.
The bones, target, and pole all lie in the same plane, parallel to the floor, normal to the axes of rotation
The IK target is parented to the rotating arm, and is the only connection between the rotating arm and the IK chain.
The meshes do not need to be in the same plane as the bones.

The differences from a character arm are:

It's mechanical, no need for deformation, weight-painting. Instead, the mesh-objects are directly Bone Parented to their bones

There are no poses, no disadvantage in having Empties as your IK target and IK Pole.



The rotation of the driving arm will then result in the reciprocal motion of the fan.