Put the lime pieces, melon and simple syrup into a cocktail glass and muddle until the melon and limes are broken down. Fill the glass with ice and add the Cachaca; stir with a cocktail spoon until very cold.
Pour the contents of the shaker into a rocks glass and serve immediately.
Bring the sugar and 1 cup water to a boil in a small saucepan. When the sugar is completely dissolved, remove the saucepan from the heat and cool the syrup to room temperature. Refrigerate, covered, for up to 1 month.