Daniel Russel, Washington’s former top diplomat for Asia, said Pyongyang’s aim appeared to be to convince the United States and the rest of the world of the need to accept North Korea as a nuclear-armed state.

That seems to be very reasonable.   Clearly it works as a defensive weapon. 
The US and its allies including Canada are punishing the North Korean people clearly with no effect. Insanity to repeat the same action again and again.
North Korea, nuclear armed and thus safe. North Korea without sanctions, its people fed.