Date: 202109
Local time of day: 1801-2400
Location: ZZZ.Tower, US
Flight conditions: IMC
Light: Night
Aircraft: EMB ERJ 170/175 ER/LR
Operator: Air Carrier
Operating under: Part 121
Mission: Passenger
Flight phase: Initial Approach
Aircraft component: FMS/FMC
Component problem: Malfunctioning
Reporter organization: Air Carrier
Reporter function: Captain; Pilot Not Flying
Reporter qualification: Flight Crew Multiengine; Flight Crew Instrument; Flight Crew Air Transport Pilot (ATP)
Human factors: Distraction; Fatigue; Situational Awareness; Workload
Second reporter function: First Officer; Pilot Flying
Anomaly: Aircraft Equipment Problem Less Severe; Deviation - Altitude Excursion From Assigned Altitude; Deviation - Track / Heading All Types; Deviation / Discrepancy - Procedural Clearance; Inflight Event / Encounter CFTT / CFIT; Inflight Event / Encounter Weather / Turbulence
Detector: Automation Aircraft Terrain Warning; Person Flight Crew
When detected: In-flight
Result: Air Traffic Control Issued Advisory / Alert; Flight Crew Became Reoriented; Flight Crew FLC complied w / Automation / Advisory
Contributing factors: Aircraft; Human Factors; Software and Automation
Primary problem: Human Factors

Narrative: A lot going on that culminated into a low altitude caution on approach to Runway XXR. The RNP approach was loaded into the FMS in the normal preflight planning. I did not catch this error and thought it was the RNAV XXR that we were flying during the initial descent and approach; which is the approach we were cleared for. On the base leg prior to the ZZZZZ fix; we noticed the error and the box was not sequencing correctly. I instructed the FO to 'handfly' to make the 90 degree turn to final while I went heads down to get the correct approach in the box. The FO started a turn but also a descent and we received a caution obstacle aural warning from the aircraft. I instructed the FO to immediately correct and to climb to the correct altitude. At that time we also received a query from the control tower for a low altitude alert and we were 800-1000 feet below the minimum vectoring altitude at that point on the arrival. We corrected the altitude error and climbed to be at ZZZZZ1 (FAP) at the correct altitude.   I neglected or misread what approach was actually loaded into the FMS. The turn to  final should have been a turn only and not a descending turn. I was removed from monitoring while heads down reloading the approach so I did not monitor the hand flying properly. It was the end of a long day; and the last 45 minutes of the flight was dodging weather in and around ZZZ. This all happened very quick and was a bit of a wake up call to me how quickly it went from normal to a situation that had the aircraft in a low altitude situation. In hindsight; I should have just asked ATC for a vector to buy time and get reestablished on the approach instead of trying to save the approach and fix it while asking the FO to hand fly. The safest course of action would have been to get a vector.


Second narrative: On the late downwind leg of the approach; of the second leg for the day; after multiple deviations due to weather; the CA & I realized the approach loaded in the box differed to that which was briefed. That is; RNAV GPS instead of RNAV RNP . Although this was recognized; changed & executed just after the IAF; the aircraft did not respond accordingly; and as PF I initiated hand flying to correct the base to final turn; of which we momentarily overshot. Whilst hand flying & commencing a 30 degree turn in the descent at the IF; insufficient back pressure was held & the aircraft lost approximately 700-800 ft before establishing on final. This was immediately recognized and corrective action was taken to reestablish the correct altitude; whilst an aural 'Obstacle' warning was heard & moments later; an ATC advisory was received. The approach was stabilized before 1000 ft; we broke out around 900 ft & landed safely. This event was initially due to a combination of complacency & distraction... where we were dodging multiple cells en route; and failed to amend the previously entered approach in the box (*as loaded prior to departure). We held off amending the box; until we were in range to receive the latest ATIS; and at that time; became busy avoiding weather; and then once closer to the field; there was multiple traffic & very busy ATC communications. To ensure this is not repeated; I will also be thoroughly going over the box during the approach brief; and verify my intentions regarding when I shall be arming the approach & what I then expect to see on the FMS.


Synopsis: Air carrier flight crew reported GPWS alert on approach. Flight Crew corrected flight path and landed without incident.