From 8d3fc9f5f9c0593fcae9c451efe6c89c64dcbe84 Mon Sep 17 00:00:00 2001 From: Sebastiano Tronto Date: Tue, 29 Apr 2025 10:08:04 +0200 Subject: Added stop / pause / resume solve to API --- tools/300_solve_small/solve_small.c | 3 ++- tools/301_solve_file/solve_file.c | 3 ++- tools/302_solve_multisol/solve_multisol.c | 3 ++- tools/400_solvetest/solve_test.c | 6 ++++-- 4 files changed, 10 insertions(+), 5 deletions(-) (limited to 'tools') diff --git a/tools/300_solve_small/solve_small.c b/tools/300_solve_small/solve_small.c index dcd47c1..83a712a 100644 --- a/tools/300_solve_small/solve_small.c +++ b/tools/300_solve_small/solve_small.c @@ -37,7 +37,8 @@ void run(void) { continue; } n = nissy_solve(cube, solver, NISSY_NISSFLAG_NORMAL, - 0, 20, 1, -1, 0, size, buf, SOL_BUFFER_LEN, sol, stats); + 0, 20, 1, -1, 0, size, buf, SOL_BUFFER_LEN, sol, stats, + NULL, NULL); if (n == 0) printf("No solution found\n"); else diff --git a/tools/301_solve_file/solve_file.c b/tools/301_solve_file/solve_file.c index d9084fd..be4d1f5 100644 --- a/tools/301_solve_file/solve_file.c +++ b/tools/301_solve_file/solve_file.c @@ -24,7 +24,8 @@ void run(void) { continue; } nsols = nissy_solve(cube, solver, NISSY_NISSFLAG_NORMAL, - 0, 20, 1, -1, 0, size, buf, SOL_BUFFER_LEN, sol, stats); + 0, 20, 1, -1, 0, size, buf, SOL_BUFFER_LEN, sol, stats, + NULL, NULL); if (nsols == 0) printf("No solution found\n"); else diff --git a/tools/302_solve_multisol/solve_multisol.c b/tools/302_solve_multisol/solve_multisol.c index a2896a9..8f04b5f 100644 --- a/tools/302_solve_multisol/solve_multisol.c +++ b/tools/302_solve_multisol/solve_multisol.c @@ -30,7 +30,8 @@ void run(void) { continue; } n = nissy_solve(cube, solver, NISSY_NISSFLAG_NORMAL, - 0, 20, nsol, -1, 0, size, buf, SOL_BUFFER_LEN, sol, stats); + 0, 20, nsol, -1, 0, size, buf, SOL_BUFFER_LEN, sol, stats, + NULL, NULL); if (n == 0) printf("No solution found\n"); else diff --git a/tools/400_solvetest/solve_test.c b/tools/400_solvetest/solve_test.c index 1bfe851..73e6e8e 100644 --- a/tools/400_solvetest/solve_test.c +++ b/tools/400_solvetest/solve_test.c @@ -57,7 +57,8 @@ void run(void) { continue; } n = nissy_solve(cube, solver, NISSY_NISSFLAG_NORMAL, - 0, 20, 1, -1, 0, size, buf, SOL_BUFFER_LEN, sol, stats); + 0, 20, 1, -1, 0, size, buf, SOL_BUFFER_LEN, sol, stats, + NULL, NULL); if (n == 0) { printf("Error: no solution\n"); return; @@ -78,7 +79,8 @@ void run(void) { continue; } n = nissy_solve(cube, solver, NISSY_NISSFLAG_NORMAL, - 0, 20, 100, 0, 0, size, buf, SOL_BUFFER_LEN, sol, stats); + 0, 20, 100, 0, 0, size, buf, SOL_BUFFER_LEN, sol, stats, + NULL, NULL); if (check_all(sol, s[i].solutions)) { printf("All solutions are correct\n"); } else { -- cgit v1.3