Fix for random HW errors

A typo when checking the algorithm used was causing the diff1targ value not to evaluate properly in test_nonce(). This caused the test to fail and increase HW errors. Thanks to Zuikkis for pointing that out!