Section 315 in The Code of Criminal Procedure
Title: Accused person to be competent witness
(1) Any person accused of an offence before a Criminal Court shall be a competent witness for the defence and may give evidence on oath in disproof of the charges made against him or any person charged together with him at the same trial:
(a) he shall not be called as a witness except on his own request in writing;
(b) his failure to give evidence shall not be made the subject of any comment by any of the parties or the Court or give rise to any presumption against himself or any person charged together with him that the same trial.
(2) Any person against whom proceedings are instituted in any Criminal Court under section 98, or section 107 or section 108, or section 109, or section 110, or under Chapter IX or under Part B, Part C or Part D of Chapter X, may offer himself as a witness in such proceedings:
Provided that in proceedings under section 108, section 109, or section 110, the failure of such person to give evidence shall not be made the subject of any comment by any of the parties or the Court or give rise to any presumption against him or any other person proceeded against together with him at the same inquiry
Title: No influence to be used to induce disclosure
Except as provided in sections 306 and 307, no influence, by means of any promise or threat or otherwise, shall be used to an accused person to induce him to disclose or withhold any matter within his knowledge
Title: Provision for inquiries and trial being held in the absence of accused in certain cases
(1) At any stage of an inquiry or trial under this Code, if the Judge or Magistrate is satisfied, for reasons to be recorded, that the personal attendance of the accused before the Court is not necessary in the interests of justice, or that the accused persistently disturbs the proceedings in Court, the Judge or Magistrate may, if the accused is represented by a pleader, dispense with his attendance and proceed with such inquiry or trial in his absence, and may, at any subsequent stage of the proceedings, direct the personal attendance of such accused.
(2) If the accused in any such case is not represented by a pleader, or if the Judge or Magistrate considers his personal attendance necessary, he may, if he thinks fit and for reasons to be recorded by him, either adjourn such inquiry or trial, or order that the case of such accused be taken up or tried separately.
In the principal Act, to section 317, the following Explanation shall be added, namely:--
"Explanation:--For the purpose of this section "Personal attendance of the accused” shall include his attendance through the medium of Electronic Video Linkage as provided in section 273.".
[Vide Gujarat Act 31 of 2017, s. 6.]
Title: Procedure where accused does not understand proceedings
If the accused, though not of unsound mind, cannot be made to understand the proceedings, the Court may proceed with the inquiry or trial; and, in the case of a Court other than a High Court, if such proceedings result in a conviction, the proceedings shall be forwarded to the High Court with a report of the circumstances of the case, and the High Court shall pass thereon such order as it thinks fit.
Title: Power to proceed against other persons appearing to be guilty of offence
(1) Where, in the course of any inquiry into, or trial of, an offence, it appears from the evidence that any person not being the accused has committed any offence for which such person could be tried together with the accused, the Court may proceed against such person for the offence which he appears to have committed.
(2) Where such person is not attending the Court, he may be arrested or summoned, as the circumstances of the case may require, for the purpose aforesaid.
(3) Any person attending the Court, although not under arrest or upon a summons, may be detained by such Court for the purpose of the inquiry into, or trial of, the offence which he appears to have committed.
(4) Where the Court proceeds against any person under sub-section (1), then
(a) the proceedings in respect of such person shall be commenced afresh, and the witnesses re-heard;
(b) subject to the provisions of clause (a), the case may proceed as if such person had been an accused person when the Court took cognizance of the offence upon which the inquiry or trial was commenced.