Homemade carpenter ant killer is made from equal parts of baking soda and powdered sugar, sometimes known as confectioner's sugar. Mix those two substances together and place the mixture in an area where ants have been seen. The carpenter ants will eat the mixture but will not be able to process it and will die.
Another homemade ant killer can be made with equal parts baking soda, powdered sugar and powdered vitamin C. This combination kills ants in the same manner as the baking soda/powdered sugar mix. You can crush a vitamin C pill until it turns into a fine powder.
Carpenter ants and other ant varieties do not like powdery, chalky substances as it inhibits their tracking abilities, making it harder for them to find one another and go about their usual ant business. Sprinkle baking soda in areas where you do not want the carpenter ants but have seen them previously. You can also sprinkle the baking soda in a line and the ants will not cross it. This is useful in doorways, around window sills or around the perimeter of your home or patio.
To help keep carpenter ants from being a huge problem, find out where they're coming from. Get rid of any rotting wood in the yard, such as old logs or tree stumps, especially if the wood is damp. If there are rotten boards on your porch or around the home, repair or replace those to deter ants from hanging around. Trim tree limbs that touch your house and garage to keep the limbs from being a roadway for ants and other pests. If there's no material around that carpenter ants like, they will relocate to somewhere else more ant-worthy.