Bitcoin Forum
May 23, 2018, 10:17:31 AM *
News: Latest stable version of Bitcoin Core: 0.16.0  [Torrent]. (New!)
 
   Home   Help Search Donate Login Register  
Pages: [1]
  Print  
Author Topic: deepbit.net bitcoin mining status page generator :: AutoIt and Dropbox  (Read 2772 times)
Eremite
Newbie
*
Offline Offline

Activity: 4
Merit: 0


View Profile
July 28, 2012, 10:21:20 AM
 #1

I have a simple AutoIt script that generates a flat HTML file for checking on your status at deepbit.net without having to log in.  I prefer not having to type my password in on public computers, plus if you have people helping you mine, they can see their status without having to log into your account.

Source is below, no precompiled executables.

The AutoIt Code:  http://pastebin.com/W2Yw4jNv
The CSS Code: http://pastebin.com/9QHTNu84
The Table-Sorting Javascript: http://pastebin.com/UNmPaniW
miner.gif file: http://wastelot.tk/dl/stats/miner.gif

This will generate a flat HTML page with a sortable table.
Here's a sample: http://wastelot.tk/dl/stats/miners.htm
Sample's not live, just shows the layout.

Needs to be compiled with AutoIt : http://www.autoitscript.com/site/
-edit- to fix the URL.  Link to the download page was shown as suspicious. Cheesy

  • Edit the .au3 file's settings at the very top with your output file, deepbit.net email address, and JSON API key.
  • Change the update/refresh delays if you want.
  • Compile with AutoIt and leave it running. Cheesy

I put the .exe in a dropbox folder, then have it output to a 'stats' folder within that folder.  I put the sorttable.js, miner.gif and miners.css files in there.  Then, I make the 'stats' folder public, so I can load the page via Dropbox to see how my miners are doing without having to log into DeepBit.  It's fine by itself or you can stick it in an iframe tag to include in a normal website.

Originally, this was for having people donate CPU cycles to fund a game server and we gave in-game rewards based on the amount of shares they had submitted.

If you like the script, please  DONATE via bitcoin: 1LWz9cn4XtRCQgfdAVfsuTcsh4EhgM564K    I like money.
Also posted here: http://wastelot.tk/tenement/viewtopic.php?id=37
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction. Advertise here.
John (John K.)
Global Troll-buster and
Legendary
*
Offline Offline

Activity: 1218
Merit: 1063


Will read PM's. Have more time lately


View Profile
July 28, 2012, 11:47:14 AM
 #2

Moved to Project Development.  Smiley

My BTC Tip Jar: 1Pgvfy19uwtYe5o9dg3zZsAjgCPt3XZqz9 , GPG ID: B3AAEEB0 ,OTC ID: johnthedong
Escrow service is available on a case by case basis! (PM Me to verify I'm the escrow!)

rjk
Sr. Member
****
Offline Offline

Activity: 448
Merit: 250


1ngldh


View Profile
July 28, 2012, 04:17:51 PM
 #3

Smart man, providing the source and no executable. Wish all the noobs with an app would do the same.

Mining Rig Extraordinaire - the Trenton BPX6806 18-slot PCIe backplane [PICS] Dead project is dead, all hail the coming of the mighty ASIC!
nimda
Hero Member
*****
Offline Offline

Activity: 784
Merit: 1000


0xFB0D8D1534241423


View Profile
July 28, 2012, 05:55:45 PM
 #4

Thank you for reminding me why I use AutoHotkey.

I recommend asking me for a signature from my GPG key before doing a trade. I will NEVER deny such a request.
Eremite
Newbie
*
Offline Offline

Activity: 4
Merit: 0


View Profile
July 28, 2012, 07:24:18 PM
 #5

Thank you for reminding me why I use AutoHotkey.
I haven't tried AHK scripting before, Does AutoHotkey have a way of parsing JSON output?  This script is kindof a clusterf*** since instead of a proper json parser, I'm using Regex string replacement.  Another thing that bothered me originally was the way I got the JSON string since you apparently can't assign text from an online file to a variable directly.  At least I couldn't figure it out.

I made a PHP-only version that's much cleaner, simpler and faster.  I'll release that one also once I get it modified where you can just edit some variables.
nimda
Hero Member
*****
Offline Offline

Activity: 784
Merit: 1000


0xFB0D8D1534241423


View Profile
July 28, 2012, 07:59:49 PM
 #6

Thank you for reminding me why I use AutoHotkey.
I haven't tried AHK scripting before, Does AutoHotkey have a way of parsing JSON output?
There are multiple open-source libraries for AHK_L which parse JSON, including LSON. If you ever try AHK, make sure you download AutoHotkey_L, because it has tons of features the old AHK doesn't.
Quote
you apparently can't assign text from an online file to a variable directly.  At least I couldn't figure it out.
In AutoHotkey_L, one would use a one line HTTPRequest through COM; I don't know how easy COM is in AU3.
Quote
I made a PHP-only version that's much cleaner, simpler and faster.  I'll release that one also once I get it modified where you can just edit some variables.
Who doesn't love PHP?

I recommend asking me for a signature from my GPG key before doing a trade. I will NEVER deny such a request.
LuaKT
Member
**
Offline Offline

Activity: 72
Merit: 10



View Profile
July 29, 2012, 03:01:11 PM
 #7

Here is a Javascript version.

The API key is stored as a cookie so nothing is held by the server.
Unfortunately Deepbit doesn't support jsonp so a PHP proxy has to be used to call the API.

Index: http://pastebin.com/KLBUTWKX
Javascript: http://pastebin.com/CnxkrHbq
Jquery Cookie Plugin: http://pastebin.com/g0VH7Ssy
PHP Proxy: http://pastebin.com/qeKU9u9G

There is a demo up over at http://btcfree.net/deepbit
Pages: [1]
  Print  
 
Jump to:  

Sponsored by , a Bitcoin-accepting VPN.
Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!