(WHTM) – It is a sure sign of summer when you begin to see those lightning bugs (or fireflies) glow across the land. But have you ever wondered how they glow and why?

North Carolina State University says these insects are not flies or bugs; they are actually soft-winged beetles that really produce light, an ability called bioluminescence. The university says this is relatively rare in living organisms.

To produce this light, fireflies use special organs in their abdomens. There they combine a chemical called luciferin, oxygen and enzymes called luciferases. Scientists believe these insects control the flashing by regulating how much oxygen goes into the organ that produces the light.

Every species of lightning bug has its own signaling system, the university says. Males fly around at a certain height during a certain time at night and flash a unique signal. Females sit on the ground waiting for the males. When a female sees a male sending out a signal specific to her species, she will then flash one back.

If the conditions are right between the male and female, the male will fly down to the female and they will mate.

Most male lightning bugs fly around and do their own thing and signal independently of each other. But some synchronize their flashes when there are many others around.

The university says there are two species that do this in North America, including the Photinus carolinus of the Appalachian Mountains and the Photuris frontalis, which can be found in such places as South Carolina.

In both species, scientists think the males synchronize so everyone has a chance to look for females and for females to signal males.

The university says the study of these insects is still in its infancy, though scientists have identified about 170 different species in North America.