The FreeEject utility is a simple tool designed to eject a variety of removable media by specifying a drive letter via the command line interface.
The real facility of FreeEject is the ability to use it from the command line, or through any method that can pass commands to the command line, for example a batch file. Here are the instructions for using the command line interface of FreeEject.
freeeject <drive letter>
Where drive letter is the drive letter associated with the removable media.
This will eject the removable media associated with drive letter d: as shown here