Start doing TCP networking

This commit is contained in:
2026-04-15 21:38:30 +02:00
parent 258ca9474f
commit d631eb190d
10 changed files with 190 additions and 54 deletions

View File

@@ -7,6 +7,11 @@
#include <block/chain.h>
#include <block/block.h>
// Nets
#define MAX_CONS 32 // Some baseline for now
#define LISTEN_PORT 9393
// Economics
#define DECIMALS 1000000000000ULL
#define DIFFICULTY_ADJUSTMENT_INTERVAL 3840 // Every 3840 blocks (roughly every 4 days with a 90 second block time)
// Max adjustment per is x2. So if blocks are coming in too fast, the difficulty will at most double every 24 hours, and vice versa if they're coming in too slow.