Avalon4: Difference between revisions

From Bitcoin Wiki
Jump to navigation Jump to search
Mikeqin (talk | contribs)
Mikeqin (talk | contribs)
Line 125: Line 125:
* '''http://build.canaan-creative.com:8080/~mikeqin/build/'''
* '''http://build.canaan-creative.com:8080/~mikeqin/build/'''


=== [http://downloads.canaan-creative.com/software/avalon4/openwrt/20141112_2245/ 20141112_2245] ===
=== [http://downloads.canaan-creative.com/software/avalon4/openwrt/20141112_2245/ 20141112] ===
* Change default IIC speed from 1M to 400K
* Change default IIC speed from 1M to 400K
* Add a new luci theme for Raspberry Pi
* Add a new luci theme for Raspberry Pi

Revision as of 06:22, 16 November 2014

Pictures

A3222

Package: QFN56-8X8, 0.5mm pitch
Core voltage: 0.65 ~ 0.8V
Chip frequency: 400MHz
Hashrate: 25-30G (Normal,0.75V)
Power usage: 0.45-0.55W/G on ASIC side
VDDIO: 1.5 ~ 2.5V

SPI Example

a real data:
1st:
work n chip1
{576'hc16801619d8d4242e06e5fab25a54bbe222e8b877848c34beea79cd6528caf7e33cde02a983dab158119ce2a1c9fc4eddac8ce296d0fd9da6e18f645087e051a2d547050e8dc86b1, 64'ha, 32'h1, 32'h1, 32'h1} 
work n chip0
{576'h1bed3ba0a2cb45c1d8f8ef6712146495c44192c07145fd6d974bf4bb8f41371d65c90d1e9cb18a17fa77fe7d13cdfd7b0063910762a5f25c06b168ae087e051a895170504ac1d001, 64'h5, 32'h1, 32'h1, 32'h1}

2nd:
work n+1 chip1
{576'h0, 64'hb, 32'h1, 32'h1, 32'h1}
work n+1 chip0
{576'h0, 64'h6, 32'h1, 32'h1, 32'h1}

3rd:
work n+2 chip1
{576'h0, 64'hc, 32'h1, 32'h1, 32'h1}
work n+2 chip0
{576'h0, 64'h7, 32'h1, 32'h1, 32'h1}

then get nonce 32'h1beebba0 for chip0, 32'hc1698161 for chip1;

Avalon4

Each module include 40 A3222 ASICs, the mdoule should be working at 1TH/S and using 700W power.

JTAG Port

PMU

HU

Power & GND

LED

From left to right

ERR/WARN/TXD/RXD/N1/N2/PG1/PG2

Avalon4 CGMiner Under Ubuntu 14.04

Download

Inside your home directory, download Cgminer
git clone https://github.com/Canaan-Creative/cgminer

Compile

cd cgminer
git checkout origin/avalon4 -b avalon4
./autogen.sh --enable-avalon4
make -j 4

Run

sudo ./cgminer --avalon4-fan 60 --avalon4-freq 200 --avalon4-voltage 7125 --lowmem -o http://stratum.pool:3333 -u  work -p pass 
or
sudo ./cgminer --avalon4-fan 60 --avalon4-freq 200 --avalon4-voltage 7125 --lowmem  -o http://stratum.pool:3333 -u  work -p pass --api-allow W:192.168.2,W:192.168.2.1 --api-listen $@ 2>./log

Tweak

  • Led
 Format: ascset|ASCN,led,modularid
 eg: cgminer-api "ascset|0,led,1"
  • Fan
 Format: ascset|ASCN,fan,fanmin[-fanmax]
 eg: cgminer-api "ascset|0,fan,10" or cgminer-api "ascset|0,fan,10-100"


Technical details

  • The auc take 1~2ms betwwen write and read. even the polling delay is 0 (4800 means 1ms)
  • The cgminer each polling takes ~20ms. even the polling delay is 0ms

AUC

Avalon USB2IIC converter, USD VID:PID 29f1:33f2

LED

  • PWR: Power indicator
  • R: AUC response error
  • G: IIC Xfer
  • B: AUC init

AUC Firmware

20141105

  • AUC version: AUC-20141105
  • Code cleanup
  • Improve for firmware burning

20141103

  • AUC version: AUC-20141103
  • Add watchdog
  • Code cleanup

20141027

  • AUC version: AUC-20141027
  • Change Manufacturer to CANAAN

20141019

RPi/703N Firmware

Daily Building

20141112

  • Change default IIC speed from 1M to 400K
  • Add a new luci theme for Raspberry Pi

20141029

  • First version of Avalon4 firmware

MM Firmware

20141111

  • Version: 401411-5965e0f0'
  • Add ntime offset configure from outside
  • Reset globe values when idle
  • Update ChangeLog, README and MM_VERSION

20141109

  • Version: 401410-c6ba5180
  • Big Code cleanup, Update MM protocol.
  • Update timeout value to 90% the theory value.
  • Fix the hashrate couning.
  • Fix watchdog issue. enable watchdog.
  • Remove g_module_id check since we use I2C
  • Move adjust fan in polling package.
  • Update MM idle default fan speed to 10%

20141105

  • Version: 401410-fe698050
  • Disable PULLUP on IIC pins, Now 6 Avalon4-1T works fine with IIC serial connection
  • Sync with cgminer defines on MM protocol
  • Update change log README

20141104

  • Version: 401410-223a1c50
  • Update idle timeout from 5s to 3s
  • Display ID on controller LEDs for debug
  • Fix the automatic module detect
  • Disable watch dog
  • IDLE check when both (new stratum) and (module id) was configured

20141031

  • Fix the front led display
  • Cutoff power after testing

20141030

  • First version of Avalon4 firmware

Daily Building

Design file

Links