The company could either (1) pay back the loan (which is unlikely since it is probably out of money), (2) ask the investors to extend the maturity date, (3) convert the loan into the last round of Preferred Stock (if any) at a pre-determined (i.e. last round) price (or price negotiated at the maturity date), or (4) convert the loan into Common Stock at a pre-determined price (or price negotiated at the maturity date). If the company can’t repay the note, then the investors could push the company into bankruptcy.
The typical situation when the maturity date is reached is for the company to talk to its investors and make sure that they don’t do anything drastic, like declaring an “event of default” on the note.
If there is already a series of Preferred Stock outstanding, then allowing the investors to convert at their option into the Preferred Stock is a good alternative, especially if the conversion price is agreeable to both the company and the investors. As a practical matter, I think it is tougher to pre-negotiate a conversion price into common stock.
Sometimes aggressive investors will ask to control the board of directors or other things upon a payment default.