Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix completely broken ESP8266 miner (ver. 3.33) #1586

Merged
merged 1 commit into from
Dec 3, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion ESP8266_Code/ESP8266_Code.ino
Original file line number Diff line number Diff line change
Expand Up @@ -728,6 +728,7 @@ void loop() {

MiningJob job;
job.parse((char*)client_buffer.c_str());
difficulty = job.difficulty;

Serial.println("Parsed job: " + job.last_block_hash + " " + job.expected_hash_str + " " + String(job.difficulty));

Expand All @@ -741,7 +742,7 @@ void loop() {

String result = "";
if (LED_BLINKING) digitalWrite(LED_BUILTIN, LOW);
for (unsigned int duco_numeric_result = 0; duco_numeric_result < difficulty; duco_numeric_result++) {
for (unsigned int duco_numeric_result = 0; duco_numeric_result < job.difficulty; duco_numeric_result++) {
// Difficulty loop
sha1_ctx = sha1_ctx_base;
duco_numeric_result_str = String(duco_numeric_result);
Expand Down