The coffee may taste bad due to the following reasons:
1. Age of coffee grounds affects its taste. Old coffee may taste stale. The coffee will taste the best if you use fresh beans/grounds.
2. Quality of coffee grounds and type of water you use will have an impact on the coffee taste.
3. The cleanliness of your coffeemaker. Make sure to clean the unit every 40-80 brews.