Wikipedia gives the procedure of the elections:
Before the sealing of the Sistine Chapel1. The cardinals hear two sermons before the election: one before actually entering the conclave, and one once they are settled in the Sistine Chapel. In both cases, the sermons are meant to lay out the current state of the Church, and to suggest the qualities necessary for a pope to possess in that specific time.
2. On the morning of the day designated by the Congregations of Cardinals, the cardinal electors assemble in St Peter's Basilica to celebrate the Eucharist.
3. Then, they gather in the afternoon in the Pauline Chapel of the Palace of the Vatican, proceeding to the Sistine Chapel while singing the Veni Creator Spiritus. The Cardinals then take an oath to observe the procedures set down by the apostolic constitutions; to, if elected, defend the liberty of the Holy See; to maintain secrecy; and to disregard the instructions of secular authorities on voting. The Cardinal Dean reads the oath aloud in full; in order of precedence, the other cardinal electors merely state, while touching the Gospels, that they "do so promise, pledge and swear."
4. After all the cardinals present have taken the oath, the Master of the Papal Liturgical Celebrations orders all individuals other than the cardinals electors and conclave participants to leave the Chapel. Traditionally, he stands at the door of the Sistine Chapel and calls out: "Extra omnes!" (Latin for, roughly, "Everybody else, out!") He then closes the door.
5. The Master himself may remain, as may one ecclesiastic designated by the Congregations prior to the commencement of the election. The ecclesiastic makes a speech concerning the problems facing the Church and on the qualities the new pope needs to have. After the speech concludes, the ecclesiastic leaves.
6. Following the recitation of prayers, the Cardinal Dean asks if any doubts relating to procedure remain. After the clarification of the doubts, the election may commence.
7. Cardinals who arrive after the conclave has begun are admitted nevertheless. An ill cardinal may leave the conclave and later be readmitted; a cardinal who leaves for any reason other than illness may not return to the conclave.
8. Although in the past cardinal electors could be accompanied by attendants ("conclavists"), now only a nurse may accompany a cardinal who for reasons of ill-health, as confirmed by the Congregation of Cardinals, needs such assistance.
9. The Secretary of the College of Cardinals, the Master of Papal Liturgical Celebrations, two Masters of Ceremonies, two officers of the Papal Sacristy and an ecclesiastic assisting the Dean of the College of Cardinals are also admitted to the conclave. Priests are available to hear confessions in different languages; two doctors are also admitted. Finally, a strictly limited number of servant staff are permitted for housekeeping and the preparing and serving of meals.
10. Secrecy is maintained during the conclave; the cardinals as well as the conclavists and staff are forbidden to disclose any information relating to the election. Cardinal electors may not correspond or converse with anyone outside the conclave, by post, radio, telephone or otherwise and eavesdropping is an offense punishable by excommunication latae sententiae.
11. Only three cardinals electors are permitted to communicate with the outside world under grave circumstances, prior to approval of the College, to fulfil their duties: the Major Penitentiary, the Cardinal Vicar for the Diocese of Rome, and the Vicar General for the Vatican City State. Before the conclave that elected Pope Benedict XVI, the Sistine Chapel was "swept" using the latest electronic devices to detect any hidden "bugs" or surveillance devices (there were no reports that any were found, but in previous conclaves there were discovered press reporters who had disguised themselves as conclave servants). Universi Dominici Gregis specifically prohibits media such as newspapers, the radio, and television.
13. Before voting in the morning and again before voting in the afternoon, the electors take an oath to obey the rules of the conclave.
14. If no result is obtained after three vote days of balloting, the process is suspended for a maximum of one day for prayer and an address by the senior Cardinal Deacon.
15. After seven further ballots, the process may again be similarly suspended, with the address now being delivered by the senior Cardinal Priest. If, after another seven ballots, no result is achieved, voting is suspended once more, the address being delivered by the senior Cardinal Bishop. After a further seven ballots, there shall be a day of prayer, reflection and dialogue.
16. In the following ballots, only the two names who received the most votes in the last ballot shall be eligible in a runoff election. However, the two people who are being voted on, if Cardinal electors, shall not themselves have the right to vote.
The process of voting comprises three phases: the "pre-scrutiny", the "scrutiny", and the "post-scrutiny."
Pre-scrutiny1. During the pre-scrutiny, the Masters of the Ceremonies prepare ballot papers bearing the words Eligo in Summum Pontificem ("I elect as Supreme Pontiff") and provide at least two to each cardinal elector.
2. As the cardinals begin to write down their votes, the Secretary of the College of Cardinals, the Master of Papal Liturgical Celebrations and the Masters of Ceremonies exit; the junior Cardinal Deacon then closes the door.
3. The junior Cardinal Deacon then draws by lot nine names; the first three become Scrutineers, the second three Infirmarii and the last three Revisers.
4. New Scrutineers, Infirmarii and Revisers are not selected again after the first scrutiny; the same nine cardinals perform the same task for the second scrutiny.
5. After lunch, the election resumes with the oath to obey the rules of the conclave taken anew when the cardinals again assemble in the Sistine Chapel.
6. Nine names are chosen for new scrutineers, infirmarii, and revisers. The third scrutiny then commences, and if necessary, a fourth immediately follows.
Scrutiny1. The scrutiny phase of the election is as follows: The cardinal electors proceed, in order of precedence, to take their completed ballots (which bear only the name of the individual voted for) to the altar, where the Scrutineers stand.
2. Before casting the ballot, each cardinal elector takes a Latin oath, which translates to: "I call as my witness Christ the Lord who will be my judge, that my vote is given to the one who before God I think should be elected."
3. If any cardinal elector is in the Chapel, but cannot proceed to the altar due to infirmity, the last Scrutineer may go to him and take his ballot after the oath is recited.
4. If any cardinal elector is by reason of infirmity confined to his room, the Infirmarii go to their rooms with ballot papers and a box. Any such sick cardinals take the oath and then complete the ballot papers. When the Infirmarii return to the Chapel, the ballots are counted to ensure that their number matches with the number of ill cardinals; thereafter, they are deposited in the appropriate receptacle.
5. This oath is taken by all cardinals as they cast their ballots. If no one is chosen on the first scrutiny, then a second scrutiny immediately follows. A total of four scrutinies are taken each day, two in the morning and two in the afternoon.
6. The oath when casting one's vote is therefore anonymous, since the name of the elector is no longer signed on the ballot with that of the candidate. (Previously, the ballot was also signed by the elector and then folded over to cover the signature of the elector and then sealed to result in a semi-secret ballot.
7. There was no oath taken when actually casting ballots, prior to 1621. Completely secret ballots (at the option of the cardinals present and voting) were sometimes used prior to 1621, but these secret ballots had no oath taken when the vote was actually cast. At some conclaves prior to 1621, the cardinals verbally voted and sometimes stood in groups to facilitate counting the votes cast. The signature of the elector covered by a folded-over part of the ballot paper was added by Gregory XV in 1621, to prevent anyone from casting the deciding vote for himself. Cardinal Pole of England refused to cast the deciding vote for himself in 1549 (and was not elected), but in 1492 Cardinal Borgia (Alexander VI) did cast the deciding vote for himself. Faced by the mortal challenge to the papacy emanating from Protestantism, and fearing schism due to several stormy conclaves in the late 16th and early 17th centuries, Gregory XV established this procedure to prevent any cardinal from casting the deciding vote for himself. Since 1945, a cardinal can again cast the deciding vote for himself, though the 2/3 majority rule has always been continued, except when John Paul II had modified that rule in 1996 (after 33 ballots, a simple majority was sufficient), with the 2/3 majority rule restored in 2007 by Benedict XVI.
8. Once all votes have been cast, the first Scrutineer chosen shakes the container, and the last Scrutineer removes and counts the ballots. If the number of ballots does not correspond to the number of cardinal electors present, the ballots are burnt, unread, and the vote is repeated. If, however, no irregularities are observed, the ballots may be opened and the votes counted. Each ballot is unfolded by the first Scrutineer; all three Scrutineers separately write down the name indicated on the ballot. The last of the Scrutineers reads the name aloud.
Once all of the ballots have been opened, the final post-scrutiny phase begins.
Post-scrutiny1. The Scrutineers add up all of the votes, and the Revisers check the ballots and the names on the Scrutineers' lists to ensure that no error was made. The ballots are then all burnt by the Scrutineers with the assistance of the Secretary of the College and the Masters of Ceremonies.
2. If the first scrutiny held in any given morning or afternoon does not result in an election, the cardinals proceed to the next scrutiny immediately; the papers from both scrutinies are burnt together at the end of the second scrutiny.
3. The colour of the smoke signals the results to the people assembled in St Peter's Square. Dark smoke signals (fumata nera) indicate that the ballot did not result in an election, while white smoke signals (fumata bianca) announce that a new pope was chosen. Originally, damp straw was added to the fire to create dark smoke; beginning in 1963 coloring chemicals have been added, and beginning in 2005 bells ring after a successful election, to augment the white smoke, and especially if the white smoke is not unambiguously white.
Acceptance and proclamation1. Once the election concludes, the Cardinal Dean summons the Secretary of the College of Cardinals and the Master of Papal Liturgical Celebrations into the hall.
2. The Cardinal Dean then asks the pope-elect if he assents to the election, saying in Latin: "Acceptasne electionem de te canonice factam in Summum Pontificem? (Do you accept your canonical election as Supreme Pontiff?)"
3. There is no requirement that the pope-elect do so: he is free to say "non accepto" (I don't accept). In practice, however, any potential pope-elect who intends not to accept will explicitly state this before he has been given a sufficient number of votes to become pope. This has happened in modern times with Giovanni Colombo in October 1978.
4. If he accepts, and is already a bishop, he immediately takes office.
5. If he is not a bishop, however, he must be first consecrated as one before he can assume office. If a priest is elected, the Cardinal Dean consecrates him bishop; if a layman is elected, then the Cardinal Dean first ordains him deacon, then priest, and only then consecrates him as bishop. Only after becoming a bishop does the pope-elect take office.
6. After the newly-elected pope accepts his election, the Cardinal Dean asks him about his papal name, saying in Latin: "Quo nomine vis vocari? (By what name do you wish to be called?)"
7. After the papal name is chosen, the officials are readmitted to the conclave, and the Master of Pontifical Liturgical Ceremonies writes a document recording the acceptance and the new name of the pope.
8. Later, the new pope goes to the "Room of Tears", a small red room next to the Sistine Chapel. The pope dresses by himself, choosing a set of pontifical choir robes (white cassock, rochet and red mozzetta) from three sizes provided. Then, he vests in a gold corded pectoral cross and a red embroidered stole. He wears a white zucchetto on his head.
9. Next, the senior Cardinal Deacon (the Cardinal Protodeacon) appears at the main balcony of the basilica's façade to proclaim the new pope with the Latin phrase (assuming the new Pope was a cardinal):
Annuntio vobis gaudium magnum:
Eminentissimum ac Reverendissimum Dominum,
Sanctae Romanae Ecclesiae Cardinalem [surname],
qui sibi nomen imposuit [papal name].
("I announce to you a great joy:
We have a Pope!
The Most Eminent and Most Reverend Lord,
Cardinal of the Holy Roman Church [surname],
who takes to himself the name [papal name].")
11. The new pope then gives his first apostolic blessing, Urbi et Orbi ("to the City [Rome] and to the World").
Formerly, the pope would later be crowned by the triregnum or Triple Tiara at the Papal Coronation. John Paul I, John Paul II, and Benedict XVI did not want an elaborate coronation, choosing instead to have a simpler papal inauguration ceremony.