An electronic device, comprising: a housing, wherein the housing has an inner cavity, and the inner cavity has an opening; characterized in that, the electronic device further comprising: a functional module, wherein the functional module is able to protrude outside the inner cavity through the opening and is separated from the housing to enable the functional module independently work as a functional monomer or the functional module is able to be retracted into the inner cavity through the opening; a blocking member, wherein the blocking member is movably disposed in the inner cavity, and the blocking member corresponds to the opening; and a driving assembly, wherein the driving assembly is disposed in the inner cavity, the driving assembly is connected to the blocking member, the driving assembly drives the blocking member to switch between a first state and a second state, the blocking member is away from the opening in the first state, and the blocking member blocks the opening in the second state; wherein in a case that at least a part of the functional module is located in the inner cavity, the blocking member is in the first state, and in a case that the functional module is separated from the housing, the blocking member is in the second state. a housing, wherein the housing has an inner cavity, and the inner cavity has an opening; characterized in that, the electronic device further comprising: a functional module, wherein the functional module is able to protrude outside the inner cavity through the opening and is separated from the housing to enable the functional module independently work as a functional monomer or the functional module is able to be retracted into the inner cavity through the opening; a blocking member, wherein the blocking member is movably disposed in the inner cavity, and the blocking member corresponds to the opening; and a driving assembly, wherein the driving assembly is disposed in the inner cavity, the driving assembly is connected to the blocking member, the driving assembly drives the blocking member to switch between a first state and a second state, the blocking member is away from the opening in the first state, and the blocking member blocks the opening in the second state; wherein in a case that at least a part of the functional module is located in the inner cavity, the blocking member is in the first state, and in a case that the functional module is separated from the housing, the blocking member is in the second state. a functional module, wherein the functional module is able to protrude outside the inner cavity through the opening and is separated from the housing to enable the functional module independently work as a functional monomer or the functional module is able to be retracted into the inner cavity through the opening; a blocking member, wherein the blocking member is movably disposed in the inner cavity, and the blocking member corresponds to the opening; and a driving assembly, wherein the driving assembly is disposed in the inner cavity, the driving assembly is connected to the blocking member, the driving assembly drives the blocking member to switch between a first state and a second state, the blocking member is away from the opening in the first state, and the blocking member blocks the opening in the second state; wherein in a case that at least a part of the functional module is located in the inner cavity, the blocking member is in the first state, and in a case that the functional module is separated from the housing, the blocking member is in the second state.