If you use (2^n)-1 then you don't have any way to count by 2. n=0 => 0, n=1 -> 1, n=2 => 3.I didn't quite understand but i want it also to do (2^n)-1 for example if it was 1 and the user presser SW 2 it will increment by 2 it will become 3...
You want 2^n where n is the number of the FF that you increment (toggle) starting with n=0 is the lsb. If n=0 then you toggle the lsb and that forces the counter to count by 2^0=1. If you have n=1 then you toggle the FF next to the lsb and that forces the counter to count by 2^1=2. If you were to use n=2 and toggle the next FF up that would force the counter to count by 2^2=4, but you aren't interested in that case.