First Etherboard prototype (Nov 6, 2015): a 1000x1000 pixel canvas whose fee and min-price setters write to each other's storage slots
Historical Significance
Shows the development history of Etherboard, one of the earliest pixel-canvas experiments on Ethereum, through a series of Frontier-era prototypes deployed in the week before the final contract.
Context
Deployed by 0x4f5b350b662fb17ca4ec22116e91dc1417b892bc, the same address that a week later (November 13, 2015, block 536,195) deployed the final Etherboard contract (https://www.ethereumhistory.com/contract/0x350e0ffc780a6a75b44cc52e1ff9092870668945). Three prototypes went up on November 6-7, 2015: 0x242034238b5d9c0001bc06320bb4cfd8d20d8ed4, 0x8d4eac10d68745e2a8c36ab33c5c3961ed4b71be and 0x1776281d0d40108941cb41e604dcafbdc3cd61a1. Taken together, they show the design being iterated onchain.
Key Facts
Description
The first of three Etherboard prototypes, deployed on November 6, 2015 at block 500,761. Every version is a 1000x1000 pixel board. setColor(x, y, color) pays the previous pixel owner the bid minus a 1% fee, then stores (msg.sender, block.number, color, msg.value) for the pixel. A bid has to be at least 110% of the current price and at least the minimum price. setColorRgb(x, y, red, green, blue, alpha) packs the colour as alpha1048576 + red65536 + green*256 + blue, and getRow(y) returns the owners, colours and prices of a whole row. Unlike the final Etherboard, these prototypes store full addresses per pixel rather than compact uint16 owner IDs, and have no batch-paint function. The PixelChanged event is emitted after the pixel is overwritten, so its 'old' owner/colour/price fields actually log the new values. Failed checks emit a Log(sender, message, value) event and return false, without refunding the ETH sent. Bounds messages read 'X must be > 0 and < 1000.' and the minimum price is 50 finney. This version has a bug: setMinPrice writes the feePercent slot and setFeePercent writes the minPrice slot. It was replaced 25 minutes later by 0x8d4eac10d68745e2a8c36ab33c5c3961ed4b71be, which is identical apart from the corrected setters.
Source Verified
Byte-exact on both runtime and creation. Runtime: 2158 bytes (SHA-256 33155235c87a483eaf6d41eb6958c2978dffb21690a084d2eb44e1ab18572e34). Creation: 2215 bytes (SHA-256 0c65344faa6661752e3690492c716541984f8cd5d2632f5fbece8c163cada082), no constructor arguments. Compiled with soljson v0.1.6+commit.d41f8b7c, optimizer ON (200 runs); all 19 builds from v0.1.4-nightly.2015.10.2 through v0.1.7 produce identical output (130 v0.1.x/v0.2.x builds swept). Function names were recovered by brute-forcing the selectors, and the event topics confirm the event signatures. Struct-field and parameter names follow the verified Etherboard source. Source swapped setters reproduced as in the original. Verified on Etherscan.
Heuristic Analysis
The following characteristics were detected through bytecode analysis and may not be accurate.
Frontier Era
The initial release of Ethereum. A bare-bones implementation for technical users.
Bytecode Overview
Verified Source Available
Source verified through compiler archaeology and exact bytecode matching.
View Verification ProofShow source code (Solidity)
// Submitted by EthereumHistory (ethereumhistory.com)
contract Etherboard {
struct Pixel {
address owner;
uint lastChanged;
int color;
uint price;
}
address public owner;
uint constant width = 1000;
uint constant height = 1000;
uint public outbidPercent = 110;
uint public feePercent = 1;
uint public minPrice = 50 finney;
Pixel[1000][1000] public pixels;
event Log(address sender, string message, uint value);
event PixelChanged(uint x, uint y, address oldOwner, int oldColor, uint oldPrice, address newOwner, int newColor, uint newPrice);
function Etherboard () {
owner = msg.sender;
}
function setColorRgb(uint x, uint y, int red, int green, int blue, int alpha) returns (bool success) {
return setColor(x, y, alpha * 1048576 + red * 65536 + green * 256 + blue);
}
function setColor(uint x, uint y, int color) returns (bool success) {
if (x < 0 || x >= width) {
Log(msg.sender, "X must be > 0 and < 1000.", x);
return false;
}
if (y < 0 || y >= height) {
Log(msg.sender, "Y must be > 0 and < 1000.", y);
return false;
}
if (msg.value < minPrice) {
Log(msg.sender, "Minimum pixel price is 50 finney.", msg.value);
return false;
}
if (msg.value * 100 < pixels[x][y].price * outbidPercent) {
Log(msg.sender, "Value must be 10% higher than current pixel price.", pixels[x][y].price * outbidPercent / 100);
return false;
}
var oldPixel = pixels[x][y];
if (oldPixel.owner > 0) {
var fee = msg.value * feePercent / 100;
oldPixel.owner.send(msg.value - fee);
}
pixels[x][y] = Pixel(msg.sender, block.number, color, msg.value);
PixelChanged(x, y, oldPixel.owner, oldPixel.color, oldPixel.price, msg.sender, color, msg.value);
return true;
}
function getRow(uint y) returns (address[1000] owners, int[1000] colors, uint[1000] prices) {
for (uint x = 0; x < width; x++) {
owners[x] = pixels[x][y].owner;
colors[x] = pixels[x][y].color;
prices[x] = pixels[x][y].price;
}
}
function setFeePercent(uint percent) {
if (msg.sender == owner)
minPrice = percent;
}
function setMinPrice(uint price) {
if (msg.sender == owner)
feePercent = price;
}
function setOutbidPercent(uint percent) {
if (msg.sender == owner)
outbidPercent = percent;
}
function empty() {
if (msg.sender == owner)
owner.send(this.balance);
}
}External Links
Related contracts
Etherboard
Same deployerSecond Etherboard prototype (Nov 6, 2015): redeployed 25 minutes after the first with the fee/min-price setter bug fixed
0x8d4eac...4b71beNovember 6, 2015Etherboard
Same deployerThird Etherboard prototype (Nov 7, 2015): adds a public check() helper that refunds failed bids and cuts the minimum price to 10 finney
0x177628...cd61a1November 7, 2015Etherboard
Same deployer1000x1000 pixel canvas on Ethereum - buy, color, and trade pixels on-chain
0x350e0f...668945November 13, 2015