Here is what the Massachusetts Audubon Society suggests.
RACCOONS AND GARDENS
Raccoons will readily harvest the fruits (and vegetables) of your labor if your garden is unprotected. The only proven deterrent is proper fencing.
Place 3 foot wide chicken wire flat on the ground and erect a four or six foot high vertical chicken wire fence on top of that. Place the vertical fence 2 ½ feet in from the outside edge of the horizontal chicken wire (there will be six inches on the side of the vertical fence closest to the garden). Animals tend to start digging at the base of a vertical fence, but this method will make it impossible to get through.
Bright flashing lights strung around the garden or a loud radio placed in the garden have also been known to discourage night raids by raccoons. Eventually, however, the animals will acclimate to these tricks if the prize is tempting enough.
For more information from the Audubon Society, click here