Jackson, who has been hospitalized on and off since June for treatment of bipolar disorder, gave up his seat in Congress after 17 years. NBC's Kelly O'Donnell reports.

Updated 2:59 p.m. ET — Rep. Jesse Jackson Jr., D-Ill., resigned from Congress on Wednesday following a prolonged treatment for mental health issues.

An aide to House Speaker John Boehner, R-Ohio, told NBC News that the speaker's office received a letter from the Illinois congressman this afternoon.

"During this journey, I have made my share of mistakes," Jackson wrote in his letter. "I am aware of the ongoing federal investigation into my activities, and I am doing my best to address the situation responsibly, cooperate with the investigators, and accept responsibility for my mistakes, for they are my mistakes and mine alone. None of us is immune from our share of shortcomings or human frailties and I pray that I will be remembered for what I did right."

Rep. Jesse Jackson Jr.'s resignation comes just two weeks after he won a ninth term as a representative of Illinois without campaigning and after being out of the public eye for months due to a personal struggle with mental illness. NBC's Kelly O'Donnell reports.

The son of the Rev. Jesse Jackson, the civil rights leader, Jackson, Jr. had sought treatment for bipolar depression at the Mayo Clinic for much of the past summer and fall. His last vote in Congress was on June 10, and his mysterious disappearance from official duties prompted speculation about the reason for the Democrat's prolonged absence.

Jackson was first elected to Congress in 1995 in a Chicago-area district's special election, and had won re-election to eight full terms since then. He won re-election just 15 days ago by a 40-point margin in the heavily Democratic district. Jackson also survived a Democratic primary challenge this summer from former Rep. Debbie Halvorson. President Barack Obama and Chicago Mayor Rahm Emanuel (D) each endorsed Jackson in the primary.

Amid his battles against mental illness, Jackson has also been embroiled in ethics allegations, which prompted the congressman to reportedly hire an attorney in recent weeks.

In particular, Jackson's efforts to convince then-Illinois Gov. Rod Blagojevich to appoint him as Barack Obama's successor in the Senate have drawn scrutiny. Blagojevich, a Democrat, was subsequently convicted of having sought favors and donations in exchange for the appointment.