feat(c-miner): port miner pipeline to modular C implementation
This commit is contained in:
32
config.h
Normal file
32
config.h
Normal file
@@ -0,0 +1,32 @@
|
||||
#ifndef CONFIG_H
|
||||
#define CONFIG_H
|
||||
|
||||
#include <stdbool.h>
|
||||
#include <stdint.h>
|
||||
|
||||
typedef struct {
|
||||
char rpc_user[128];
|
||||
char rpc_password[128];
|
||||
char rpc_host[128];
|
||||
int rpc_port;
|
||||
|
||||
char wallet_address[128];
|
||||
|
||||
double difficulty_factor;
|
||||
char nonce_mode[16];
|
||||
int timestamp_update_interval;
|
||||
uint32_t batch;
|
||||
char coinbase_message[128];
|
||||
char extranonce1[128];
|
||||
char extranonce2[128];
|
||||
|
||||
int num_processors;
|
||||
int check_interval;
|
||||
} MinerConfig;
|
||||
|
||||
void config_set_defaults(MinerConfig *cfg);
|
||||
bool config_load(const char *path, MinerConfig *cfg);
|
||||
bool config_validate(const MinerConfig *cfg);
|
||||
void config_print(const MinerConfig *cfg);
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user