An image explaining the data required for the spoke length calculator
Input in millimeters.
The comma as well as the point may be used as decimal-point.
Diameter of the circle through the spoke ends D=ERD mm
Diameter of the circle through the hub flange holes d mm
Distance hub flange - central plane of the wheel a mm
Number of spoke crossings k  
Number of spokes n  

mm

Diameter of the circle through the spoke ends (Effective Rim Diameter):
To find out, take two (old) spokes and shorten them to 250 mm (20'' wheel: 150 mm) by pinching off their heads. Screw the spokes into nipples until the spoke ends are flush with the grounds of the nipples' slits. Insert the two spokes into exactly opposite holes of the rim. The distance between the inside ends of the spokes (where the spoke heads have been pinched away), added with the lengths of the two spokes (2 * 250 mm or 2 * 150 mm, respectively), will amount to the sought diameter.

Diameter of the Hub Flange:
Diameter of the circle passing through the centers of the flange holes, since usually the spoke length is measured starting at the
"center line" of the spoke heads.

The central plane of the wheel
is usually situated in the middle between the dropouts of the frame or fork, respectively. This means, in the middle between
the outermost hub axle nuts (those touching the inside planes of the dropouts). And, for this reason, not necessarily
in the middle between the hub flanges (for instance: rear wheel hubs, or front wheel hubs for disc brakes).