Ethics is the study of what we should or should not do. Socrates stuck to his ethical viewpoint during his trial, which lead to his sentence and death.
Ethics considers the moral rules (morality) that govern our lives and whether they are valid.