A method for locking and unlocking at least two doors of a locker, the method comprising:
- a step of receiving, by a control module of a locker, a signal comprising at least one digital key, wherein the locker comprises:
- at least two compartments each defining an internal space for receiving an object;
- at least one compartment separator arranged between two compartments and which could be positioned;
- in a first position, so as to separate the respective internal spaces defined by these compartments, or
- in a second position, so as to assemble the respective internal spaces defined by these compartments;
- at least two doors, each door forming access to a separate compartment from the outside of the locker, each door comprising an electronic lock and being capable of closing one of said internal spaces;
- and
- the control module linked to the electronic locks via a datalink, the electronic locks being capable of locking and unlocking the door according to the value of an instruction received by the electronic locks via the first datalink, the control module comprising,
- a sensor capable of receiving said signal comprising at least one digital key;
- and
- an electronic recognition component comprising a memory and a processor capable of authenticating said at least one received digital key,
- the sensor being capable of transmitting the signal to the electronic recognition component, the authentication of said at least one received digital key by the electronic recognition component triggering the generation of an instruction signal for the locking or unlocking of the door, characterized in that,
- the control module is configured to determine if the at least one compartment separator is positioned in the first or in the second position, and transmit the result of this determination to the electronic recognition component and in that,
- the electronic recognition component is capable, when it is determined that said at least one compartment separator is positioned in the second position, to transmit, following the authentication of said at least one digital key, said instruction signal to all electronic locks associated with the doors which form access to the compartments arranged on either side of said at least one compartment separator, for the locking or unlocking of said doors;
- a step of authenticating said at least one received digital key by the electronic recognition component;
- a step of determining, by the control module, if the at least one compartment separator is positioned in the first or in the second position;
- a step of transmitting, by the control module, the result of this determination to the electronic recognition component;
- and
- when it is determined that said at least one compartment separator is positioned in the second position, a step of generating by the electronic recognition component, following the authentication of said at least one digital key, an instruction signal for all the electronic locks associated with the doors, which form access to the compartments arranged on either side of said at least one compartment separator, for the locking or unlocking of said doors.