FixedU128

Composite 424 v393

sp_arithmetic::fixed_point::FixedU128

About This Type

Cryptographic signature from one of three schemes: Ed25519, Sr25519, or Ecdsa.

The signature type used in signed extrinsics. Most Bittensor accounts use Sr25519.

Encoding: Variant: 0x00=Ed25519 (64 bytes), 0x01=Sr25519 (64 bytes), 0x02=Ecdsa (65 bytes).

Fields (1)

#NameType
0(unnamed)u128

SCALE Encoding

Rule
1-byte variant selects the signature scheme, followed by the raw signature.
Size
65 or 66 bytes

Examples

Sr25519 signature = Sr25519(0xaabb...)
0x01<64 bytes of signature>
01 Variant 1 = Sr25519
<64 bytes> 64-byte Sr25519 signature

Code Examples

import { TypeRegistry } from "@polkadot/types";

const registry = new TypeRegistry();

// Encode FixedU128
const value = registry.createType("FixedU128", {
  field: 1_000_000_000n
});
console.log("Hex:", value.toHex());

Referenced By (1)

Type Information

Type ID
424
Kind
Composite
Path
sp_arithmetic::fixed_point::FixedU128
Runtime
v393