|
|
@@ -20,6 +20,7 @@ use lazy_static::lazy_static;
|
|
|
|
|
|
use crate::{consensus::Float10, util::time::Timestamp};
|
|
|
|
|
|
+
|
|
|
lazy_static! {
|
|
|
/// Genesis hash for the mainnet chain
|
|
|
pub static ref MAINNET_GENESIS_HASH_BYTES: blake3::Hash = blake3::hash(b"darkfi_mainnet");
|
|
|
@@ -27,10 +28,10 @@ lazy_static! {
|
|
|
// NOTE: On initial network bootstrap, genesis timestamp should be equal to boostrap timestamp.
|
|
|
// On network restart only change bootstrap timestamp to schedule when nodes become active.
|
|
|
/// Genesis timestamp for the mainnet chain
|
|
|
- pub static ref MAINNET_GENESIS_TIMESTAMP: Timestamp = Timestamp(1650887115);
|
|
|
+ pub static ref MAINNET_GENESIS_TIMESTAMP: Timestamp = Timestamp(1773025405);
|
|
|
|
|
|
/// Bootstrap timestamp for the mainnet chain
|
|
|
- pub static ref MAINNET_BOOTSTRAP_TIMESTAMP: Timestamp = Timestamp(1650887115);
|
|
|
+ pub static ref MAINNET_BOOTSTRAP_TIMESTAMP: Timestamp = Timestamp(1773025405);
|
|
|
|
|
|
/// Total sum of initial staking coins for the mainnet chain
|
|
|
pub static ref MAINNET_INITIAL_DISTRIBUTION: u64 = 1000;
|
|
|
@@ -39,10 +40,10 @@ lazy_static! {
|
|
|
pub static ref TESTNET_GENESIS_HASH_BYTES: blake3::Hash = blake3::hash(b"darkfi_testnet");
|
|
|
|
|
|
/// Genesis timestamp for the testnet chain
|
|
|
- pub static ref TESTNET_GENESIS_TIMESTAMP: Timestamp = Timestamp(1672785000);
|
|
|
+ pub static ref TESTNET_GENESIS_TIMESTAMP: Timestamp = Timestamp(1673039000);
|
|
|
|
|
|
/// Bootstrap timestamp for the testnet chain
|
|
|
- pub static ref TESTNET_BOOTSTRAP_TIMESTAMP: Timestamp = Timestamp(1672785000);
|
|
|
+ pub static ref TESTNET_BOOTSTRAP_TIMESTAMP: Timestamp = Timestamp(1673039000);
|
|
|
|
|
|
/// Total sum of initial staking coins for the testnet chain
|
|
|
pub static ref TESTNET_INITIAL_DISTRIBUTION: u64 = 1000;
|
|
|
@@ -61,12 +62,17 @@ lazy_static! {
|
|
|
|
|
|
|
|
|
// Consensus parameters
|
|
|
- pub static ref DT: Float10 = Float10::try_from("0.1").unwrap();
|
|
|
+
|
|
|
pub static ref TI: Float10 = FLOAT10_ONE.clone();
|
|
|
pub static ref TD: Float10 = FLOAT10_ONE.clone();
|
|
|
+ //pid parameters
|
|
|
+ //pub static ref KP: Float10 = Float10::from_str_native("-0.8").unwrap().with_precision(RADIX_BITS).value();
|
|
|
+ //pub static ref KI: Float10 = Float10::from_str_native("0.6").unwrap().with_precision(RADIX_BITS).value();
|
|
|
+ //pub static ref KD: Float10 = Float10::from_str_native("0.8").unwrap().with_precision(RADIX_BITS).value();
|
|
|
+ // pid discrete parameters
|
|
|
+ pub static ref KP: Float10 = Float10::from_str_native("0.5").unwrap().with_precision(RADIX_BITS).value();
|
|
|
+ pub static ref KI: Float10 = Float10::from_str_native("0.8").unwrap().with_precision(RADIX_BITS).value();
|
|
|
|
|
|
- pub static ref KP: Float10 = Float10::from_str_native("-0.8").unwrap().with_precision(RADIX_BITS).value();
|
|
|
- pub static ref KI: Float10 = Float10::from_str_native("0.6").unwrap().with_precision(RADIX_BITS).value();
|
|
|
pub static ref KD: Float10 = Float10::from_str_native("0.8").unwrap().with_precision(RADIX_BITS).value();
|
|
|
pub static ref PID_OUT_STEP: Float10 = Float10::from_str_native("0.1").unwrap().with_precision(RADIX_BITS).value();
|
|
|
pub static ref MAX_DER: Float10 = Float10::from_str_native("0.1").unwrap().with_precision(RADIX_BITS).value();
|