public static int calculateBlockAcknowledgement(final int segN) {
        final int segmentCount = segN + 1;
        int ack = 0;
        for (int i = 0; i < segmentCount; i++) {
            ack |= 1 << i;
        }
        return ack;
    }
Calculates the block acknowledgement payload.
<p>
This method will set the segO bit to 1
</p>

@param segN number of segments
mesh/src/main/java/no/nordicsemi/android/mesh/control/BlockAcknowledgementMessage.java