A microprogrammable electronic device configured to operate according to instruction cycles (C1, C2, C3, C4), and comprising: • a code memory configured to store - a software/firmware code comprising a number of instructions, and - a reference signature computed based on the instructions of the software/firmware code; • a fetch unit configured to read instructions to be executed (I1, I2, I3, I4) from the code memory; • a decode and execute unit configured to decode and execute the instructions (I1, I2, I3, I4) read by the fetch unit; and • a signature computation unit configured to - compute a signature of the stored software/firmware code on the basis of the instructions (W1, W2, W3, W4) stored on the code memory, - compare the computed signature with the stored reference signature, and - detect a corruption of the stored software/firmware code if the computed signature differs from the stored reference signature; characterized in that: • each instruction cycle (C1, C2, C3, C4) is divided into a first operating phase (C 11, C 21, C 31, C 41) and a second operating phase (C 12, C 22, C 32, C 42); • the fetch unit is configured to read a current instruction to be executed (I1, I2, I3, I4) from the code memory at the first operating phase (C 11, C 21, C 31, C 41) of a current instruction cycle (C1, C2, C3, C4); • the decode and execute unit is configured to decode and execute the read current instruction (I1, I2, I3, I4) at the second operating phase (C 12, C 22, C 32, C 42) of the current instruction cycle (C1, C2, C3, C4); and • the signature computation unit is configured to read the stored instructions (W1, W2, W3, W4) from the code memory at the second operating phases (C 12, C 22, C 32, C 42) of the instruction cycles (C1, C2, C3, C4). • a code memory configured to store - a software/firmware code comprising a number of instructions, and - a reference signature computed based on the instructions of the software/firmware code; - a software/firmware code comprising a number of instructions, and - a reference signature computed based on the instructions of the software/firmware code; • a fetch unit configured to read instructions to be executed (I1, I2, I3, I4) from the code memory; • a decode and execute unit configured to decode and execute the instructions (I1, I2, I3, I4) read by the fetch unit; and • a signature computation unit configured to - compute a signature of the stored software/firmware code on the basis of the instructions (W1, W2, W3, W4) stored on the code memory, - compare the computed signature with the stored reference signature, and - detect a corruption of the stored software/firmware code if the computed signature differs from the stored reference signature; - compute a signature of the stored software/firmware code on the basis of the instructions (W1, W2, W3, W4) stored on the code memory, - compare the computed signature with the stored reference signature, and - detect a corruption of the stored software/firmware code if the computed signature differs from the stored reference signature; • each instruction cycle (C1, C2, C3, C4) is divided into a first operating phase (C 11, C 21, C 31, C 41) and a second operating phase (C 12, C 22, C 32, C 42); • the fetch unit is configured to read a current instruction to be executed (I1, I2, I3, I4) from the code memory at the first operating phase (C 11, C 21, C 31, C 41) of a current instruction cycle (C1, C2, C3, C4); • the decode and execute unit is configured to decode and execute the read current instruction (I1, I2, I3, I4) at the second operating phase (C 12, C 22, C 32, C 42) of the current instruction cycle (C1, C2, C3, C4); and • the signature computation unit is configured to read the stored instructions (W1, W2, W3, W4) from the code memory at the second operating phases (C 12, C 22, C 32, C 42) of the instruction cycles (C1, C2, C3, C4).