
933 So.2d 689 (2006)
Brandon SMITH, Petitioner,
v.
STATE of Florida, Respondent.
No. 5D06-1389.
District Court of Appeal of Florida, Fifth District.
July 21, 2006.
Elaine A. Barbour, Orlando, for Petitioner.
Charles J. Crist, Jr., Attorney General, Tallahassee, and Rebecca Roark Wall, Assistant Attorney General, Daytona Beach, for Respondent.

ON MOTION FOR REHEARING
PALMER, J.
Brandon Smith (defendant) has filed a motion seeking rehearing of the opinion *690 issued by this court on May 15, 2006. We grant the motion, withdraw our previous opinion, and substitute this opinion in its stead.
The defendant, who is charged with committing the crime of first-degree murder, petitions this court for a writ of habeas corpus or, in the alternative, a writ of mandamus, claiming that the trial court erred in failing to comply with the provisions of section 907.041 of the Florida Statutes (2005) and rule 3.132 of the Florida Rules of Criminal Procedure before refusing to reinstate his pretrial release. We agree and accordingly grant the defendant's request for mandamus relief. See Dicolla v. State, 763 So.2d 1286 (Fla. 5th DCA 2000). See also Daniels v. Jenne, 847 So.2d 1081 (Fla. 4th DCA 2003)(holding that defendant was entitled to receive collateral relief when trial court denied his motion to reinstate pretrial release based solely on defendant's violation of a condition of his pretrial release without making any findings to show that no conditions of release can reasonably protect the community from risk of physical harm to persons or assure the presence of the accused at trial). Accord Buhbut v. Bieluch, 835 So.2d 1222 (Fla. 4th DCA 2003).
Accordingly, we direct the trial court to conduct an expedited evidentiary hearing to determine whether reasonable conditions of pretrial release would protect the community and assure the defendant's presence at trial.
PETITION GRANTED.
SAWAYA and TORPY, JJ., concur.
