Measure the roof so you can get the angle from the roof’s peak. Measure the width of the roof and then divide that by 2. This will give you the run of the roof.
Put the framing square on your first 2-by-4. Put the fat end of your framing square on the measurement on your pitch.
Mark a line on the diagonal so the rafter will fit properly against the ridge board on your house.
Mark a notch on the outside wall edge. This will go to the cap on the wall. Remove half of the thickness from the ridge board.
Place the rafter inside your ridge board. The notch on the wall cap should fit flush. Cut any additional rafters for your roof. Use nails to nail the rafters into place on the wall cap.