Code Monkey home page Code Monkey logo

duinocoini2c's Introduction

DuinoCoinI2C

This project design to mine Duino-Coin using an Esp8266/Esp32 as a master and Arduino as a slave.

Using the I2C communication to connect all the boards and make a scalable communication between the master and the slaves.

Version

DuinoCoinI2C -> DuinoCoin Version 3.0

Arduino - Slave

All Slaves have the same code and should select the I2C Address automatically.

Library Dependency

Automatic I2C Address

The I2C Address on the Arduino is automatically updated when the board starts, if an Address already exists on the I2C bus the code finds another Address to use.

Tiny - Slave

Tiny Slaves have the same code and the I2C Address is selected by the EEPROM.

Library Dependency

Defines

The code has some defines to make the code smaller and disable some features.

Serial

This enable the Serial Monitor.

#define SERIAL_LOGGER Serial

LED

This enable the led output and makes de led flash when the slave is working.

#define LED LED_BUILTIN

Serial set I2C Address

If the Serial is enable on your mcu, you could send the I2C Address using the Serial Monitor.

ATtiny85 - ATTinyCore

You could use this code to generate a ATtiny85 slave using the http://drazzy.com/package_drazzy.com_index.json boards on the Arduino IDE.

Check the ATTinyCore project for more information.

I2C pinOut

pinOut ATtiny85
SCL PB2
SDA PB0

I2C Address

I2C Address is selected by the EEPROM_ADDRESS (default 0) and the first upload the Address is set by the define.

#define ADDRESS_I2C 1

Esp8266/Esp32 - Master

The master requests the job on the DuinoCoin server and sends the work to the slave (Arduino).

After the job is done, the slave sends back the response to the master (Esp8266/Esp32) and then sends back to the DuinoCoin server.

Library Dependency

Max Client/Slave

The code supports 10 clients and can be changed on the define:

#define CLIENTS 10

Connection Pinouts

Connect the pins of the Esp8266 or Esp32 on the Arduino like the table/images below, use a Logic Level Converter to connect between the ESP and Arduino.

ESP8266 ESP32 Logic Level Converter Arduino
3.3V 3.3V <---> 5V
GND GND <---> GND
SCL D1 (GPIO5) GPIO22 <---> A5
SDA D2 (GPIO4) GPIO21 <---> A4

DuinoCoinI2C

Custom PCB

ericddm shared this amazing pcb!

DuinoCoinI2C


Do you like this project? Please star this project on GitHub!

duinocoini2c's People

Contributors

modfiles avatar rassware avatar ricaun avatar shanisma avatar sys-256 avatar vulpecula-nl avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

duinocoini2c's Issues

error comiling version 2.6

I delete old version, download new.
Load sketch in ArduinoIDE, then start compiling.
Did i do something wrong ?
Show me that output :
`Arduino: 1.8.15 (Windows 10), Board: "FireBeetle-ESP32, 80MHz, 115200"

C:\Users\IVAN\Downloads\DuinoCoinI2C-main\DuinoCoin_Esp_Async_Master\DuinoCoin_Clients.ino: In function 'bool clients_connect(byte)':

DuinoCoin_Clients:82:37: error: no matching function for call to 'WiFiClient::connect(String&, int&)'

if (!clients[i].connect(host, port))

                                 ^

In file included from C:\Users\XXXX\AppData\Local\Arduino15\packages\esp32\hardware\esp32\1.0.6\libraries\WiFi\src/WiFi.h:37:0,

             from C:\Users\XXXX\Downloads\DuinoCoinI2C-main\DuinoCoin_Esp_Async_Master\DuinoCoin_Esp_Async_Master.ino:27:

C:\Users\XXXX\AppData\Local\Arduino15\packages\esp32\hardware\esp32\1.0.6\libraries\WiFi\src/WiFiClient.h:51:9: note: candidate: virtual int WiFiClient::connect(IPAddress, uint16_t)

 int connect(IPAddress ip, uint16_t port);

     ^

C:\Users\XXXX\AppData\Local\Arduino15\packages\esp32\hardware\esp32\1.0.6\libraries\WiFi\src/WiFiClient.h:51:9: note: no known conversion for argument 1 from 'String' to 'IPAddress'

C:\Users\XXXX\AppData\Local\Arduino15\packages\esp32\hardware\esp32\1.0.6\libraries\WiFi\src/WiFiClient.h:52:9: note: candidate: virtual int WiFiClient::connect(IPAddress, uint16_t, int32_t)

 int connect(IPAddress ip, uint16_t port, int32_t timeout);

     ^

C:\Users\XXXX\AppData\Local\Arduino15\packages\esp32\hardware\esp32\1.0.6\libraries\WiFi\src/WiFiClient.h:52:9: note: candidate expects 3 arguments, 2 provided

C:\Users\XXXX\AppData\Local\Arduino15\packages\esp32\hardware\esp32\1.0.6\libraries\WiFi\src/WiFiClient.h:53:9: note: candidate: virtual int WiFiClient::connect(const char*, uint16_t)

 int connect(const char *host, uint16_t port);

     ^

C:\Users\XXXX\AppData\Local\Arduino15\packages\esp32\hardware\esp32\1.0.6\libraries\WiFi\src/WiFiClient.h:53:9: note: no known conversion for argument 1 from 'String' to 'const char*'

C:\Users\XXXX\AppData\Local\Arduino15\packages\esp32\hardware\esp32\1.0.6\libraries\WiFi\src/WiFiClient.h:54:9: note: candidate: virtual int WiFiClient::connect(const char*, uint16_t, int32_t)

 int connect(const char *host, uint16_t port, int32_t timeout);

     ^

C:\Users\XXXX\AppData\Local\Arduino15\packages\esp32\hardware\esp32\1.0.6\libraries\WiFi\src/WiFiClient.h:54:9: note: candidate expects 3 arguments, 2 provided

Multiple libraries were found for "WiFi.h"

Used: C:\Users\XXXX\AppData\Local\Arduino15\packages\esp32\hardware\esp32\1.0.6\libraries\WiFi

Not used: C:\Users\XXXX\Downloads\arduino-1.8.15-windows\arduino-1.8.15\libraries\WiFi

exit status 1

no matching function for call to 'WiFiClient::connect(String&, int&)'`

Arduino Nano not recognized after power on with >6 devices.

As there is no reply I edited that issue:

Describe the bug
When there are more than 6 slave devices the system will not recognize these in 1 out of 10 (or more) power on cycles. The device list is then just empty [ ].
There is a problem with the i2c initialization when such a large number of devices connects.

To Reproduce
Steps to reproduce the behavior:
I use an ESP8266-01S as Master device and 10 Arduino Nano as Slaves.
Use more than 6 Arduinos.
Check the device liste.
If it stays empty reset the Arduinos one by one and all of them should connect after a few seconds.
--Or--
Add a random delay to DoinoCoin_Arduino_Slave.ino before DuinoCoin_setup();

  randomSeed(analogRead(0));
  delay(8000+random(2000,3000)+random(2000,3000));
  DuinoCoin_setup();

The delay must be longer than the time it takes to get wifi and the pool.

Expected behavior
While I had only 6 Nano the rig worked immediately after power on.
When I added 4 additional Nano devices it should all work as with 6 of them.

Arduino (please complete the following information):

  • Arduino IDE Version 2 Beta
  • lates code from this github

Additional context
The wiring is correct. If it works it just works right after the power on, no issue then with the single Arduinos.
I deactivated the pull-up resistors on the Arduinos as they are deactivated by default in this code on the ESP.
The reason is that I use a bidirectional level shifter that already has 10k resistors on each line on each side.

Trouble with Arduino slave

I saw a similar resolved issue to this but I can't figure this one out. When uploading the docs to make my Arduino nano a slave I get this error. "Fatal error Arduino.h no such file or directory .... Include arduino.h"
I'm assuming that's a library I need to add to the ide but I can't find it. I found a file arduino.h in the Arduino download but it's where it was supposed to be in files and I can't upload it as a library on ide so I'm stumped.
Any help appreciated.

need update to revoxhere/duino-coin v2.6

After update from revoxhere/duino-coin to v2.6 stand alone nanos work no problems.
Here is running AVR I2C v2.5.2 and it is a lot of troubles with nodes.

Please do update and add if you can add serial monitor over network.

Feature Request - Ideas

Hello

I would like to suggest some features to improve and makes more easier to setup this proyect for people that loves do this kind of stuffs or people that just want to setup the easier and simplier ways

1.- Web Server (port 80): This feature is for monitoring the rig with some flexibility like to allow change the username of DUCO mining, a buttom to start/re.start/stop (maybe add an automated reboot feature every "X" time, hour) to improve the mining performance. Also allow to visualize all devices on the I2C with their respective adress and status (if they are mining correctly).

2.- Wifi AP mode. This is for the first boot, in stead to define the SSID and password of the wifi network on the main code, have the flexibility to imput at the first boot, you you connect with your phone, enter (or search) your network and then the device will connect to your network. Also define a buttom to reset the values, so if you change SSID, you dont have to load the code again.

3.- A compiled firmware for ESP8266. This is to complie all code and libraries on a .bin file ready to upload to your ESP8266 using a PyFlasher. This will be more easier than using arduino IDE. Also for future updates, you may update wireless your ESP8266 by uploading .bin file. Also you can do a "release" of this compilance.

Would be nice to have those features. Also will help to improve the performace, detect and fix some bugs in the way.
I see the potential of this proyect and im glad to contribute but i dont have programming skills to develop all.

Max slave number

I'm making an AIO board including ESP8266 as master and Atmega328p as slave. I wonder the max number of slave is 10 in README or can be higher? If it's more than 10, it would be better. :)

Flash Size too big on ATMega8 (can't compile/upload)

I have some Atmega8 chips. but i got this error when compiling.

c:/users/felipe rojas verasay/appdata/local/arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/../lib/gcc/avr/7.3.0/../../../../avr/bin/ld.exe: C:\Users\FELIPE~1\AppData\Local\Temp\arduino_build_297722/DuinoCoin_Arduino_Slave.ino.elf section .text' will not fit in region text'
c:/users/felipe rojas verasay/appdata/local/arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/../lib/gcc/avr/7.3.0/../../../../avr/bin/ld.exe: region `text' overflowed by 3684 bytes
collect2.exe: error: ld returned 1 exit status
exit status 1
Error compilando para la tarjeta ATmega8.

TIMEOUT How can I fix this

Hi
whas working fine 2 days ago I have up loaded again and still get this

[0]Connecting to Duino-Coin server... with port 2814
[1]Connecting to Duino-Coin server... with port 2816
[ ]FreeRam: 47184 I2C Connected[ 0 1 ]
[ ]FreeRam: 47184 I2C Connected[ 0 1 ]
[ ]FreeRam: 47184 I2C Connected[ 0 1 ]
[ ]FreeRam: 47184 I2C Connected[ 0 1 ]
[ ]FreeRam: 47184 I2C Connected[ 0 1 ]
[0]2.5
[0]Job Request: ********
[ ]FreeRam: 46512 I2C Connected[ 0 1 ]
[1] --------------- TIMEOUT -------------
[ ]FreeRam: 47592 I2C Connected[ 0 1 ]
[ ]FreeRam: 47592 I2C Connected[ 0 1 ]
[ ]FreeRam: 47592 I2C Connected[ 0 1 ]
[ ]FreeRam: 47592 I2C Connected[ 0 1 ]
[ ]FreeRam: 47592 I2C Connected[ 0 1 ]
[ ]FreeRam: 47592 I2C Connected[ 0 1 ]
[0]Connecting to Duino-Coin server... with port 2813
[1]Connecting to Duino-Coin server... with port 2814
[ ]FreeRam: 47184 I2C Connected[ 0 1 ]
[ ]FreeRam: 47184 I2C Connected[ 0 1 ]
[ ]FreeRam: 47184 I2C Connected[ 0 1 ]
[ ]FreeRam: 47184 I2C Connected[ 0 1 ]
[ ]FreeRam: 47184 I2C Connected[ 0 1 ]
[1]2.5
[1]Job Request: ********
[ ]FreeRam: 47376 I2C Connected[ 0 1 ]
[1]Connecting to Duino-Coin server... with port 2814
[0] --------------- TIMEOUT -------------
[ ]FreeRam: 47376 I2C Connected[ 0 1 ]
[ ]FreeRam: 47376 I2C Connected[ 0 1 ]
[ ]FreeRam: 47376 I2C Connected[ 0 1 ]
[ ]FreeRam: 47376 I2C Connected[ 0 1 ]
[ ]FreeRam: 47376 I2C Connected[ 0 1 ]
[1]2.5
[1]Job Request: *******
[ ]FreeRam: 47592 I2C Connected[ 0 1 ]
[0]Connecting to Duino-Coin server... with port 2816
[1]Connecting to Duino-Coin server... with port 2813
[ ]FreeRam: 47184 I2C Connected[ 0 1 ]
[ ]FreeRam: 47184 I2C Connected[ 0 1 ]

i2c not worked

...........
Connected to WiFi!
Local IP address: 192.168.0.11
[ ]Update beyond-pool-1 50.112.145.154 6000
[ ]FreeRam: 41776 I2C Connected[ ]
[ ]FreeRam: 41776 I2C Connected[ ]
[ ]FreeRam: 41272 I2C Connected[ ]
[ ]FreeRam: 41272 I2C Connected[ ]
[ ]FreeRam: 41272 I2C Connected[ ]
[ ]FreeRam: 41272 I2C Connected[ ]
[ ]FreeRam: 41272 I2C Connected[ ]
[ ]FreeRam: 41272 I2C Connected[ ]
[ ]FreeRam: 41272 I2C Connected[ ]
[ ]FreeRam: 41272 I2C Connected[ ]
[ ]FreeRam: 41272 I2C Connected[ ]
[ ]FreeRam: 41272 I2C Connected[ ]
[ ]FreeRam: 41272 I2C Connected[ ]
[ ]FreeRam: 41272 I2C Connected[ ]
[ ]FreeRam: 41272 I2C Connected[ ]
[ ]FreeRam: 41272 I2C Connected[ ]
[ ]FreeRam: 41272 I2C Connected[ ]
[ ]FreeRam: 41272 I2C Connected[ ]
[ ]FreeRam: 41272 I2C Connected[ ]
[ ]FreeRam: 41272 I2C Connected[ ]
[ ]FreeRam: 41272 I2C Connected[ ]
[ ]FreeRam: 41272 I2C Connected[ ]
[ ]FreeRam: 41272 I2C Connected[ ]
[ ]FreeRam: 41272 I2C Connected[ ]
[ ]FreeRam: 41272 I2C Connected[ ]
[ ]FreeRam: 41488 I2C Connected[ ]
[ ]FreeRam: 41488 I2C Connected[ ]
[ ]FreeRam: 41488 I2C Connected[ ]
[ ]FreeRam: 41488 I2C Connected[ ]
[ ]FreeRam: 41488 I2C Connected[ ]
[ ]FreeRam: 41488 I2C Connected[ ]
[ ]FreeRam: 41488 I2C Connected[ ]
[ ]FreeRam: 41488 I2C Connected[ ]
[ ]FreeRam: 41488 I2C Connected[ ]
[ ]FreeRam: 41488 I2C Connected[ ]

how to fix?

Webserver question

Hi @ricaun,
I have installed & running the last version of your software and it works really well, (I only have some issues wit a NANO that hungs on "BAD jobs" until I restart it by hand, but my question is about the webserver feature.
After installing, I see that the port 80 TCP is opened in the board but I'm unable to access with the browser.
Am I forgetting any configuration to activate this feature?
Also it could be that this is currently under development so, if it's the case, please forgot any of this message.
Thanks again for your work

I cannot upload slave code into my arduino

Dear All,
I am a rookie, and mining duino-coin sounds interesting to me. So, I downloaded the code (Master & Slave), and I uploaded master code into ESP8266 with successfully. But when I tried to upload slave code into my arduino Uno and error message showed as below:


DuinoCoin_Wire:8:10: fatal error: DuinoCoin.h: No such file or directory
#include <DuinoCoin.h> // https://github.com/ricaun/arduino-DuinoCoin
^~~~~~~~~~~~~
compilation terminated.
exit status 1
DuinoCoin.h: No such file or directory


Anyone please knowledge me what I did wrong? Or did I miss any step?

Sincerely,

MudaMuda

No output in Serial Monitor

Hello! I have installed all the libraries, programmed the Arduinos and one Node MCU with an ESP8266 and connected everything according to the wiring diagram. All the sketch uploads were successful. The Arduinos (3) are all blinking. However, when I open the Serial monitor, there is absolutely nothing. Not even the first print from the setup function. I did set the correct baud rate to 115200. The node MCU is not blinking at all. I have been using it previously to mine, so it is working.
Thanks for any help!

Free Ram

Running the rig for sometime will result in Free Ram only appearing in console and it will stop mining
Capture

Connection Failed

Morning,

I have a small 'rig' set up with 4 Arduino Nanos and an ESP8266 which has been running well, I have installed the latest Client and Server yesterday to try to solve my issue but have had no luck.

The ESP8266 connects correctly to the Wi Fi
The ESP8266 correctly identifies the 4 Nano 'slaves' [ ] FreeRam: 41448 I2C Connected [ 0 1 2 3 ]
Then cannot connect with:

Connected to WiFi!
Local IP address xxx.xxx.xxx.xxx
[ ]Update beyond-pool-1 50.112.145.154 6000
[0] Connecting to Duino-Coin server... with port 6000
[0] connection failed

Any ideas?

Thanks

Rig stop mining..

my rig just stop mining last night, tried re uploading code n slave and master but still cannot mine.

09:12:48.335 -> Duino-Coin AVR I2C v2.7
09:12:48.335 -> Address: 1
09:12:48.335 -> Address: 2
09:12:48.335 -> Address: 3
09:12:48.335 -> Address: 4
09:12:48.335 -> Connecting to: AP_WiFi6
09:12:48.849 -> .......
09:12:52.583 -> Connected to WiFi!
09:12:52.583 -> Local IP address: 192.168.10.145
09:12:53.002 -> [ ]Update pulse-pool-4 149.91.88.18 2813
09:12:55.196 -> [0]Connecting to Duino-Coin server... 149.91.88.18 2813
09:12:55.474 -> [1]Connecting to Duino-Coin server... 149.91.88.18 2813
09:12:55.757 -> [2]Connecting to Duino-Coin server... 149.91.88.18 2813
09:12:56.037 -> [3]Connecting to Duino-Coin server... 149.91.88.18 2813
09:12:56.457 -> [0]2.7
09:12:56.551 -> [1]2.7
09:12:56.645 -> [2]2.7
09:12:56.645 -> [ ]FreeRam: 38568 I2C [ 0. 1. 2. 3. ]
09:12:56.690 -> [0]MOTD Request: Daviedz
09:12:56.690 -> [1]Job Request: Daviedz
09:12:56.690 -> [2]Job Request: Daviedz
09:12:57.344 -> [0]Happy mining on PulsePool (4)!
09:12:57.344 -> Pool worker limit: 50
09:12:57.344 -> [0]Job Request: Daviedz
09:12:57.675 -> [3]2.7
09:12:57.675 -> [ ]FreeRam: 38568 I2C [ 0. 1. 2. 3. ]
09:12:57.723 -> [3]Job Request: Daviedz
09:12:58.702 -> [ ]FreeRam: 38568 I2C [ 0. 1. 2. 3. ]
09:12:59.681 -> [ ]FreeRam: 38568 I2C [ 0. 1. 2. 3. ]
09:13:00.672 -> [ ]FreeRam: 38544 I2C [ 0. 1. 2. 3. ]
09:13:01.663 -> [ ]FreeRam: 38544 I2C [ 0. 1. 2. 3. ]
09:13:02.697 -> [ ]FreeRam: 38040 I2C [ 0. 1. 2. 3. ]
09:13:03.676 -> [ ]FreeRam: 38040 I2C [ 0. 1. 2. 3. ]
09:13:04.703 -> [ ]FreeRam: 38040 I2C [ 0. 1. 2. 3. ]
09:13:05.683 -> [ ]FreeRam: 38040 I2C [ 0. 1. 2. 3. ]
09:13:06.664 -> [ ]FreeRam: 38040 I2C [ 0. 1. 2. 3. ]
09:13:07.693 -> [ ]FreeRam: 38424 I2C [ 0. 1 2 3. ]
09:13:08.683 -> [ ]FreeRam: 38808 I2C [ 0 1 2 3 ]
09:13:09.676 -> [ ]FreeRam: 38808 I2C [ 0 1 2 3 ]
09:13:10.666 -> [ ]FreeRam: 38808 I2C [ 0 1 2 3 ]
09:13:11.702 -> [ ]FreeRam: 38808 I2C [ 0 1 2 3 ]
09:13:12.688 -> [ ]FreeRam: 38808 I2C [ 0 1 2 3 ]
09:13:13.675 -> [ ]FreeRam: 38808 I2C [ 0 1 2 3 ]
09:13:14.666 -> [ ]FreeRam: 38840 I2C [ 0 1 2 3 ]
09:13:15.703 -> [ ]FreeRam: 38832 I2C [ 0 1 2 3 ]
09:13:16.694 -> [ ]FreeRam: 38832 I2C [ 0 1 2 3 ]

Random Specified Ports (improvement)

Any possibility to implement the joggling ports like the new feature of the official miners? and maybe an option to ping the server ip+ports if it will response, otherwise will choose on list of specified ports.

Ошибка Arduino IDE

Ошибка при компиляции:
In file included from C:\Users*\Documents\Arduino\libraries\ArduinoJson-6.x\src/ArduinoJson/Polyfills/static_array.hpp:11:0,
from C:\Users*
\Documents\Arduino\libraries\ArduinoJson-6.x\src/ArduinoJson/Numbers/FloatTraits.hpp:14,
from C:\Users*\Documents\Arduino\libraries\ArduinoJson-6.x\src/ArduinoJson/Numbers/parseNumber.hpp:7,
from C:\Users*
\Documents\Arduino\libraries\ArduinoJson-6.x\src/ArduinoJson/Variant/VariantImpl.hpp:10,
from C:\Users*\Documents\Arduino\libraries\ArduinoJson-6.x\src/ArduinoJson.hpp:32,
from C:\Users*
\Documents\Arduino\libraries\ArduinoJson-6.x\src/ArduinoJson.h:9,
from C:\Users*\Desktop\DUCOcoint\DuinoCoinI2C-main\DuinoCoin_Esp_Async_Master\DuinoCoin_Pool.ino:15:
C:\Users*
\Documents\Arduino\libraries\ArduinoJson-6.x\src/ArduinoJson/Polyfills/pgmspace_generic.hpp: In instantiation of 'typename ArduinoJson6183_91::enable_if<ArduinoJson6183_91::is_pointer::value, T>::type ArduinoJson6183_91::pgm_read(const void*) [with T = const __FlashStringHelper*; typename ArduinoJson6183_91::enable_if<ArduinoJson6183_91::is_pointer::value, T>::type = const __FlashStringHelper*]':
C:\Users*\Documents\Arduino\libraries\ArduinoJson-6.x\src/ArduinoJson/Deserialization/DeserializationError.hpp:100:12: required from here
C:\Users*
\Documents\Arduino\libraries\ArduinoJson-6.x\src/ArduinoJson/Polyfills/pgmspace_generic.hpp:14:45: error: 'const void*' is not a pointer-to-object type
return reinterpret_cast(pgm_read_ptr(p));
^
exit status 1
Ошибка компиляции для платы NodeMCU 0.9 (ESP-12 Module).

TIMEOUT

Duino-Coin AVR I2C v2.7.3
Address: 1
Address: 2
Connecting to: ROOter
.......
Connected to WiFi!
Local IP address: 192.168.1.135
[ ]Update svko-pool-1 5.230.69.132 6000
[0]Connecting to Duino-Coin server... 5.230.69.132 6000
[1]Connecting to Duino-Coin server... 5.230.69.132 6000
[0]2.7
[0]MOTD Request: rustamyou
[ ]FreeRam: 38688 I2C [ 0. 1. ]
[1]2.7
[1]Job Request: rustamyou
[0]Welcome to svkopool (1) hosted by revox!
Pool worker limit: 50
[0]Job Request: rustamyou
[1]Job 0a555cdb2cdf1f3fd97eba1d4b80a567da6fb932,c5fcd6d261ec7500c6a0b01f1432f0a28aacc5df,6
[1]Job Receive: 6
[ ]FreeRam: 38984 I2C [ 0. 1. ]
[0]Job ac827c882c69dd914910757762f4abe4edc87a85,e205b192d1d1ad69cc621c13ece071fc5dacaba1,6
[0]Job Receive: 6
[ ]FreeRam: 38536 I2C [ 0. 1. ]
[ ]FreeRam: 38536 I2C [ 0. 1. ]
[1] --------------- TIMEOUT -------------
[ ]FreeRam: 38400 I2C [ 0. 1 ]
[1]Connecting to Duino-Coin server... 5.230.69.132 6000
[0] --------------- TIMEOUT -------------
[1]2.7
[1]Job Request: rustamyou
[ ]FreeRam: 37536 I2C [ 0 1. ]
[1]Job c63f0df481eee1967d23231addc82962fa6e1467,9166b672de117fc0864fec32a462b236cccd2fa7,6
[1]Job Receive: 6
[ ]FreeRam: 38344 I2C [ 0 1. ]
[ ]FreeRam: 38344 I2C [ 0 1. ]
[ ]FreeRam: 38344 I2C [ 0 1. ]
[ ]FreeRam: 38344 I2C [ 0 1. ]
[ ]FreeRam: 38344 I2C [ 0 1. ]
[0]Connecting to Duino-Coin server... 5.230.69.132 6000
[1] --------------- TIMEOUT -------------
[ ]FreeRam: 37936 I2C [ 0. 1 ]
[0]2.7
[0]Job Request: rustamyou
[0]Job 4bd6462f35946b6f7875f203d16e4045129632c6,604db59d9beaa841b874e1ccefc4a47757248c32,6
[0]Job Receive: 6
[ ]FreeRam: 38152 I2C [ 0. 1 ]
[ ]FreeRam: 38152 I2C [ 0. 1 ]
[ ]FreeRam: 38152 I2C [ 0. 1 ]
[ ]FreeRam: 38152 I2C [ 0. 1 ]
[ ]FreeRam: 38152 I2C [ 0. 1 ]

Arduino Nano difficulty too high

On version 2.7.

I have Arduino nano rig with esp8266 all powered via 3.3v.
Difficulty jumps from 6 to 16 and 20% bad shares.
Hasrate per device ~ 198.08 H/s

Side question - do I need level shifter and power nano with 5v or I can leave it as it is, is there any benefit to power it on 5v.

Change server port from 2815 to 2814

Actual port maps to 2815 which is the ESP mining port. But should it not be the port 2814 for AVR mining? The ESP is only the master for the communication. Right?

Not connecting to server

....
23:41:37.008 -> [0]Connecting to Duino-Coin server... with port 2812
23:41:37.055 -> [0]Connection failed.
23:41:37.055 -> [ ]FreeRam: 42000 I2C Connected[ 0 1 2 3 4 ]
23:41:42.052 -> [ ]FreeRam: 41976 I2C Connected[ 0 1 2 3 4 ]
23:41:47.051 -> [ ]FreeRam: 41976 I2C Connected[ 0 1 2 3 4 ]
23:41:52.051 -> [ ]FreeRam: 41976 I2C Connected[ 0 1 2 3 4 ]
23:41:57.053 -> [ ]FreeRam: 41976 I2C Connected[ 0 1 2 3 4 ]
23:42:02.062 -> [ ]FreeRam: 41976 I2C Connected[ 0 1 2 3 4 ]
23:42:07.011 -> [0]Connecting to Duino-Coin server... with port 2812
23:42:07.058 -> [0]Connection failed.
....

ESP32 as Master not working

Hi, I tried using ESP32 as Master but seems like not working (Note: If i use ESP8266 my rig working fine).

I tried connecting 1 Arduino uno but its detects a lot of i2c address

21:13:45.596 -> Duino-Coin AVR I2C v2.7.3
21:13:45.643 -> Address: 1
21:13:47.627 -> Address: 6
21:13:49.705 -> Address: 7
21:13:51.719 -> Address: 11
21:13:53.780 -> Address: 17
21:13:55.797 -> Address: 19
21:13:57.814 -> Address: 21
21:13:59.861 -> Address: 25
21:14:01.885 -> Address: 30
21:14:03.895 -> Address: 31
Anyone can help?

Не получилось запустить код на mega 2560 pro mini

Не получилось запустить код на mega 2560 pro mini. Прошивается и не работает. Есть ли какая особенность при прошивке? Прошиваю скетчем DuinoCoin_Arduino_Slave. Один раз даже прошил. Но ESP не работала с ним. В com в ком порт отладочная информация шла

LED on ATtiny85

Does LED on Attiny85 off by default? I use Attiny as slave and only power LED is on but the other LED is not blinking when mining. How to turn it on?

Error connection i2c

I have error connection as i2c with arduino and esp8266. I have atmega168 at arduino and this board don't watch connection.

wemos d1 mini as slaves?

They're really cheap. I was wondering if the slave code would work on the wmos d1 mini 8266 (clone).

Thanks.

Mega328 have same unique ID

I have 1 ESP8266 and 6 Arduino Nano. But I only get 11-12 Duino Coins per day, and I donot know why.

I find the 6 Arduino Nano print same unique ID after their job has been done.

I donnot know if it is working good.

About the Wiring (Question)

Hello!

Hello! I would like to try this project by connecting several arduino mini boards in parallel, but i'm wondering about the best way to power each board

In schematics says that arduino works with 5v and ESP8266 works with 3.3v
I see that you power arduino on the 5v pin (directly to the chip bypassing all regulators) but with 3.3v That actually works fine? (low voltage means overclock the internal processor).

Another question is if you power ESP8266 via USB, then you are using the wemos D1 mini regulator 5v to 3.3 to power the ESP8266 and all ATMegas chips, so... you are stressing that regulator to its max capacity (with more devices you plug on 3.3v output).

On this case, i'm wondering which is the best way to make the connection optimizer.
Im thinking to use a phone charger 5v 2A to power directly all on 5v (includding the Wemos D1 Mini). As i2c signals on arduino are 5v, and ESP8266 signals are 3.3 (prefered, 5v is also supported). Use a voltage divider resistor 2K and 1K to drop 5v to 3.3 (here i don't know exactly if i sould do on SCL, SDA or both) or maybe use a logic level bidirectional.

The other option is to use a lm2596 module, connect the input to a phone charger 5v/2A or universal charger 12v/2A and regulate the output to 3.3v and power all directly just as the schematic (but on this way it doesnt like as arduino works with 5v).

Please comment wich is the best way to power up many boards. Obviusly we always think in the most simple way and if it works it doesnt matter, but my goal is to learn, understand and do the "correct" way to dont damage any component at long term.

ATMega328 change to difficulty @16

ATMega328 with the optimized duino-coin library do about 215-220 H/s, however the server interpret the device as the arduino mega.

The server interpret 190 H/s arround as a standard arduino with dificulty of @6
But with this code 220H/s server rise to dificulty of @16, affecting the reward (which it pays less) and the performance, less submits.

In the few days the performance of the reward has been drop in about 30-40% when usually i do 80-90 DUCO per day, now i do about 40-50 DUCO per day with the same setup.

image

Should multiple Nano devices establish multiple websocket connections?

1
2
I tested the official AVRMiner and connected multiple devices. The mining speed is almost the same as the official announcement, that is, 2 Nano is about 16-20 coins per day.
And I use I2C, about 8-10 coins per day.
I checked the code of REVOX, and I don't quite understand it. Is it because his code is to establish a connection for each device?
I feel that the server distributes rewards according to the number of connections.
It hasn’t been long since I learned programming. This is one of my thoughts. If it is wrong, please ignore it.

The miner does not work.

The miner does not work.
After the last events on the server. revoxhere corrected something. Although the ESP code works from it. You can check why his code works and yours does not. The miner connects to the server but does not get work

Server Behaviour

Hello,
Let me say first that it's a really great project because it permits to use a master and several slaves without a PC and therefore it's possible to use low powering devices.
However, I'm wondering if could be possible to make the behaviour of the server, (ESP8260/ESP32) to act as a PC client AVR miner. I say this because the miner (for the server) appears like it is, (an ESP8266 I2C v2.4.7) but working on a low level difficulty due that the job is being done by an arduino.
I'm not 100% sure about this, because I'm just starting with Duco but, do you thin that the server could penalyze the miners working this way?

Not related but, only to let you know that arduino pro mini, that runs on 3.3 volts, works great as slave with a Wemos D1 mini as a master, and this can avoid voltage issues when using 5 volts board.

Great Job!

can't connect to server

Describe the bug
updated today after update can't connect to server :

To Reproduce
downloaded code, edit for my network and user, upload

Expected behavior
normal mining

Screenshots

15:56:37.814 -> [1]2.7
15:56:37.814 -> [ ]FreeRam: 177115 I2C [ 0 1 ]
15:56:39.879 -> [0]Connecting to Duino-Coin server... 149.91.88.18 2811
15:56:40.206 -> [1]Connecting to Duino-Coin server... 149.91.88.18 2811
15:56:40.438 -> [ ]FreeRam: 179223 I2C [ 0. 1. ]
15:58:21.376 -> [0]2.7
16:00:01.381 -> [1]2.7
16:00:01.381 -> [ ]FreeRam: 177047 I2C [ 0 1 ]
16:00:03.421 -> [0]Connecting to Duino-Coin server... 149.91.88.18 2811
16:00:03.467 -> [1]Connecting to Duino-Coin server... 149.91.88.18 2811
16:00:03.561 -> [ ]FreeRam: 179007 I2C [ 0. 1. ]
16:01:43.719 -> [0]2.7
16:02:43.115 -> ws[/ws][1] connect
16:02:43.255 -> ws[/ws][1] pong[0]: 
16:03:23.729 -> [1]2.7
16:03:23.729 -> [ ]FreeRam: 175859 I2C [ 0 1 ]
16:03:25.766 -> [0]Connecting to Duino-Coin server... 149.91.88.18 2811
16:03:28.778 -> [0]Connection failed.
16:03:28.872 -> [ ]Update pulse-pool-1 149.91.88.18 1224
16:03:28.872 -> [ ]FreeRam: 175379 I2C [ 0 1 ]
16:03:29.906 -> [ ]FreeRam: 175563 I2C [ 0 1 ]
16:03:30.893 -> [ ]FreeRam: 175559 I2C [ 0 1 ]
16:03:31.877 -> [ ]FreeRam: 175539 I2C [ 0 1 ]
16:03:32.911 -> [ ]FreeRam: 175543 I2C [ 0 1 ]
16:03:33.899 -> [ ]FreeRam: 175543 I2C [ 0 1 ]
16:03:34.887 -> [ ]FreeRam: 175543 I2C [ 0 1 ]
16:03:35.877 -> [ ]FreeRam: 175547 I2C [ 0 1 ]
16:03:36.910 -> [ ]FreeRam: 175539 I2C [ 0 1 ]
16:03:37.898 -> [ ]FreeRam: 175535 I2C [ 0 1 ]
16:03:38.886 -> [ ]FreeRam: 175555 I2C [ 0 1 ]
16:03:39.870 -> [ ]FreeRam: 175555 I2C [ 0 1 ]
16:03:40.891 -> [ ]FreeRam: 175555 I2C [ 0 1 ]
16:03:41.875 -> [ ]FreeRam: 175555 I2C [ 0 1 ]
16:03:42.891 -> [ ]FreeRam: 175555 I2C [ 0 1 ]
16:03:43.880 -> [ ]FreeRam: 175535 I2C [ 0 1 ]
16:03:44.915 -> [ ]FreeRam: 175527 I2C [ 0 1 ]
16:03:45.902 -> [ ]FreeRam: 175551 I2C [ 0 1 ]
16:03:46.889 -> [ ]FreeRam: 175539 I2C [ 0 1 ]
16:03:47.923 -> [ ]FreeRam: 175555 I2C [ 0 1 ]
16:03:48.897 -> [ ]FreeRam: 175555 I2C [ 0 1 ]
16:03:49.883 -> [ ]FreeRam: 175555 I2C [ 0 1 ]
16:03:50.917 -> [ ]FreeRam: 175555 I2C [ 0 1 ]
16:03:51.905 -> [ ]FreeRam: 175555 I2C [ 0 1 ]
16:03:52.881 -> [ ]FreeRam: 175555 I2C [ 0 1 ]
16:03:55.749 -> [0]Connecting to Duino-Coin server... 149.91.88.18 1224
16:03:55.843 -> [1]Connecting to Duino-Coin server... 149.91.88.18 1224
16:03:55.936 -> [ ]FreeRam: 177719 I2C [ 0. 1. ]
16:03:56.966 -> [ ]FreeRam: 178463 I2C [ 0. 1. ]
16:05:36.989 -> [0]2.7
16:07:16.961 -> [1]2.7
16:07:16.961 -> [ ]FreeRam: 175779 I2C [ 0 1 ]
16:07:19.029 -> [0]Connecting to Duino-Coin server... 149.91.88.18 1224
16:07:19.075 -> [1]Connecting to Duino-Coin server... 149.91.88.18 1224
16:07:19.167 -> [ ]FreeRam: 177899 I2C [ 0. 1. ]
16:08:59.261 -> [0]2.7
16:10:39.251 -> [1]2.7
16:10:39.251 -> [ ]FreeRam: 175751 I2C [ 0 1 ]
16:10:41.273 -> [0]Connecting to Duino-Coin server... 149.91.88.18 1224
16:10:41.367 -> [1]Connecting to Duino-Coin server... 149.91.88.18 1224
16:10:41.461 -> [ ]FreeRam: 177863 I2C [ 0. 1. ]
16:10:42.432 -> [ ]FreeRam: 177907 I2C [ 0. 1. ]
16:12:22.488 -> [0]2.7
16:14:02.472 -> [1]2.7
16:14:02.472 -> [ ]FreeRam: 175743 I2C [ 0 1 ]
16:14:04.488 -> [0]Connecting to Duino-Coin server... 149.91.88.18 1224
16:14:04.535 -> [1]Connecting to Duino-Coin server... 149.91.88.18 1224
16:14:04.628 -> [ ]FreeRam: 177935 I2C [ 0. 1. ]
16:15:45.038 -> [1]2.7
16:15:45.038 -> [ ]FreeRam: 175487 I2C [ 0. 1 ]
16:15:47.061 -> [0]Connecting to Duino-Coin server... 149.91.88.18 1224
16:15:47.249 -> [1]Connecting to Duino-Coin server... 149.91.88.18 1224
16:15:47.437 -> [ ]FreeRam: 178259 I2C [ 0. 1. ]
16:15:48.423 -> [ ]FreeRam: 178667 I2C [ 0. 1. ]
16:17:28.665 -> [0]2.7
16:19:08.654 -> [1]2.7
16:19:08.654 -> [ ]FreeRam: 175775 I2C [ 0 1 ]
16:19:10.663 -> [0]Connecting to Duino-Coin server... 149.91.88.18 1224
16:19:10.756 -> [1]Connecting to Duino-Coin server... 149.91.88.18 1224
16:19:10.849 -> [ ]FreeRam: 177883 I2C [ 0. 1. ]
16:19:11.855 -> [ ]FreeRam: 177931 I2C [ 0. 1. ]
16:20:52.414 -> [0]2.7
16:22:32.414 -> [1]2.7
16:22:32.414 -> [ ]FreeRam: 175743 I2C [ 0 1 ]
16:22:34.435 -> [0]Connecting to Duino-Coin server... 149.91.88.18 1224
16:22:34.575 -> [1]Connecting to Duino-Coin server... 149.91.88.18 1224
16:22:34.622 -> [ ]FreeRam: 177907 I2C [ 0. 1. ]
16:24:14.645 -> [0]2.7
16:25:54.657 -> [1]2.7
16:25:54.657 -> [ ]FreeRam: 175775 I2C [ 0 1 ]
16:25:56.679 -> [0]Connecting to Duino-Coin server... 149.91.88.18 1224
16:25:56.914 -> [1]Connecting to Duino-Coin server... 149.91.88.18 1224
16:25:57.008 -> [ ]FreeRam: 177907 I2C [ 0. 1. ]
16:27:37.727 -> [0]2.7
16:29:17.725 -> [1]2.7
16:29:17.725 -> [ ]FreeRam: 175759 I2C [ 0 1 ]
16:29:19.750 -> [0]Connecting to Duino-Coin server... 149.91.88.18 1224
16:29:19.796 -> [1]Connecting to Duino-Coin server... 149.91.88.18 1224
16:29:19.937 -> [ ]FreeRam: 177899 I2C [ 0. 1. ]
16:29:20.924 -> [ ]FreeRam: 177895 I2C [ 0. 1. ]
16:31:01.101 -> [0]2.7
16:32:41.091 -> [1]2.7
16:32:41.091 -> [ ]FreeRam: 175759 I2C [ 0 1 ]
16:32:43.115 -> [0]Connecting to Duino-Coin server... 149.91.88.18 1224
16:32:43.207 -> [1]Connecting to Duino-Coin server... 149.91.88.18 1224
16:32:43.300 -> [ ]FreeRam: 177911 I2C [ 0. 1. ]
16:34:23.728 -> [1]2.7
16:34:23.728 -> [ ]FreeRam: 175475 I2C [ 0. 1 ]
16:34:25.750 -> [0]Connecting to Duino-Coin server... 149.91.88.18 1224
16:34:25.797 -> [1]Connecting to Duino-Coin server... 149.91.88.18 1224
16:34:25.938 -> [ ]FreeRam: 176483 I2C [ 0. 1. ]
16:34:26.927 -> [ ]FreeRam: 178283 I2C [ 0. 1. ]```

**Arduino (please complete the following information):**
Arduino IDE 1.8.15
ESP32

ESP8266 as Slave

Is this possible? Hope can add this feature for this i2c setup...

Question i2c other devices support

This is not actually a feature request but maybe could help to test some issues:

The scheme of this project is to use an ESP8266 or ESP32 as host master to connect arduinos to the server.
The issue is related that when you connect large ammounts of devices on the same i2c bus, they become in slow share frequency.
For example:
If you connect 3 devices, they do aprox 5000 shares per hour
When you connect 30 devices, they do aprox 2300 shares per hour

I would like to explore some alternatives about use a more powerfull host and do some testing.
Im wondering if i could use a raspberry pi 3-4 as a host, and use the i2c to comunicate with arduinos. The scheme should be the same, the only diference is how to run the code on a terminal.

Not related only a raspberry pi, but other ARM boards on linux based with i2c support, such orange pi, banana pi, etc.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.