ethereum / aleth

Aleth – Ethereum C++ client, tools and libraries
GNU General Public License v3.0
3.96k stars 2.18k forks source link

Ethereum Light Client support #2479

Open bobsummerwill opened 8 years ago

bobsummerwill commented 8 years ago

I am bringing my SPV light client driven by smartwatch needs carnival to C++ world now, following Samsung's recent announcement that the next Gear smartwatch, the Gear A circular one, will support Native API in addition to the existing super-cobstrained Web API.

So again likely to be armv7 dual core, 1GHz, 4 Gb of flash storage, 512Mb of memory. WiFi and 3G data. http://tizen.org OS. EFL UI.

See https://github.com/ethereum/ethereumjs-lib/issues/106 for the earlier acts in my carnival. Also a lot of chat on Dev grants Skype channel.

bobsummerwill commented 8 years ago

So just wondering if any work whatsoever has been done in cpp-ethereum towards future SPV support?

Or whether anybody has thoughts on what 'shape' such support, might have? How it could fit into the existing codebase.

If, theoretically, I had time available to do this work myself, what would I need to do?

I have the chops...

https://linkedin.com/in/bobsummerwill

... It is the time which is always the issue, but maybe I can find a subcontractor for the heavy lifting, with a Dev grant paying the wages for thst person?

gavofyork commented 8 years ago

first: BlockChain class support BlockHeader-chain only; Trie should support pruning; network should support header-chain downloading and node-querying; later: State & Trie should support partial node availability and async collection; node database should support distancing and dropping of nodes.

bobsummerwill commented 8 years ago

Thanks very much for the guidance.

Time for me to DO. Stay tuned...

bobsummerwill commented 8 years ago

Are there any previous blogs, Wiki articles or similar on Ethereum SPV which I should be aware of other than this one?

https://github.com/ethereum/wiki/wiki/Light-client-protocol

0xc1c4da commented 8 years ago

https://github.com/ethereum/wiki/wiki/Generalized_Merkle_DHT

bobsummerwill commented 8 years ago

Thanks for the link, @jarradh.

bobsummerwill commented 8 years ago

Also found this video from DEVcon-0 ... https://www.youtube.com/watch?v=WD2sRXbmims

bobsummerwill commented 8 years ago

Updated probable specs for forthcoming Gear A smartwatch which is my primary use-case for this functionality:

Exynos 3472 dual-core processor clocked at 1.2 GHz and the Mali-400 MP4 GPU clocked at 450 MHz, 768 MB of RAM, 4GB of on-board storage, and a 250 mAh battery. For connectivity we are looking at Bluetooth 4.1 (Hmmm) as well as a variant with Wi-Fi / Direct (802.11 b/g/n). Built in sensors will have GPS, accelerometer, gyro, barometer and a heart rate sensor that we are used to. As with previous Gear smart watches we will have a Super AMOLED display, but this one will have a resolution of 360×360 pixels.

So faster CPU and more memory. Nice. Gear had been plateau'ed at 1Ghz/512Mb since the Gear 2, launched in April 2014, so it is good to see some Moore's Law happening.

http://www.tizenexperts.com/2015/07/samsung-galaxy-unpacked-2015-announced-next-gear-smart-watch-launch/

bobsummerwill commented 8 years ago

See https://gitter.im/bobsummerwill/ethereum-light-client for chat channel about light client support for Ethereum.

veqtor commented 7 years ago

I would run the light client on an android phone and push updates to the watch from it, most smart watches are built around the idea of minimal-or-no calculations, the smartphone is your server. That being said, what is the progress, if any, on light client mode in cpp-ethereum?

bobsummerwill commented 7 years ago

Nothing happening, @veqtor.

You should check out https://github.com/ethereum/go-ethereum which has working light client support and Android binaries.