Sec. 2. (a) In all criminal cases, other than misdemeanor cases of which the justice court or municipal court has jurisdiction, which are tried before a jury on a plea of not guilty, the judge shall, before argument begins, first submit to the jury the issue of guilt or innocence of the defendant of the offense or offenses charged, without authorizing the jury to pass upon the punishment to be imposed. If the jury fails to agree on the issue of guilt or innocence, the judge shall declare a mistrial and discharge the jury, and jeopardy does not attach in the case.
(b) Except as provided by Article 37.071 or 37.072, if a finding of guilty is returned, it shall then be the responsibility of the judge to assess the punishment applicable to the offense; provided, however, that (1) in any criminal action where the jury may recommend community supervision and the defendant filed his sworn motion for community supervision before the trial began, and (2) in other cases where the defendant so elects in writing before the commencement of the voir dire examination of the jury panel, the punishment shall be assessed by the same jury, except as provided in Section 3(c) of this article and in Article 44.29. If a finding of guilty is returned, the defendant may, with the consent of the attorney for the state, change his election of one who assesses the punishment.
(c) Punishment shall be assessed on each count on which a finding of guilty has been returned.