Author Topic: Next bitAsset to go: bitGLD and bitEUR  (Read 4131 times)

0 Members and 1 Guest are viewing this topic.

Offline liondani

  • Hero Member
  • *****
  • Posts: 3737
  • Inch by inch, play by play
    • View Profile
    • My detailed info
  • BitShares: liondani
  • GitHub: liondani
come on guys!  we can manually update the feeds... 

Offline alt

  • Hero Member
  • *****
  • Posts: 2821
    • View Profile
  • BitShares: baozi
have update btsx_feed_auto.py, now support more asset except: "PTS", "PPC", "LTC", "WTI", "SLV"
I don't know how to get WTI and SLV from yahoo.

Offline Method-X

  • Hero Member
  • *****
  • Posts: 1131
  • VIRAL
    • View Profile
    • Learn to code
  • BitShares: methodx
Bit Gold is what Nick Szabo originally set out to create. Once price feeds and market depth are sufficient, his dream will be complete.

Bit Gold -> Bitcoin -> BitGLD

Offline Riverhead

Only 29 bitGLD feeds. How can everyone be so quick to update their client but be so slow on providing a feed?

Offline Methodise

BTS: methodise

Offline amencon

  • Sr. Member
  • ****
  • Posts: 227
    • View Profile
Updated the command btsx_feed_auto.py:

Code: [Select]
./btsx_feed_auto.py USD BTC CNY GLD EUR


 +5% +5% +5%
I've matched my feed script for the same assets, hopefully we can get the needed 51 quickly.

Offline xeroc

  • Board Moderator
  • Hero Member
  • *****
  • Posts: 12922
  • ChainSquad GmbH
    • View Profile
    • ChainSquad GmbH
  • BitShares: xeroc
  • GitHub: xeroc
Code: [Select]
diff --git a/btsxfeed/btsx_feed.py b/btsxfeed/btsx_feed.py
index 6d3a6bf..5dc6eac 100755
--- a/btsxfeed/btsx_feed.py
+++ b/btsxfeed/btsx_feed.py
@@ -42,6 +42,7 @@ def fetch_from_btc38():
     price["CNY"].append(price_cny)
     price["USD"].append(price_cny/rate_usd_cny)
     price["GLD"].append(price_cny/rate_xau_cny)
+    price["EUR"].append(price_cny/rate_usd_cny*rate_usd_eur)
   except:
     print "Warning: unknown error"
     return
@@ -59,16 +60,17 @@ def fetch_from_bter():
     price["CNY"].append(price_cny)
     price["USD"].append(price_cny/rate_usd_cny)
     price["GLD"].append(price_cny/rate_xau_cny)
+    price["EUR"].append(price_cny/rate_usd_cny*rate_usd_eur)
   except:
     print "Warning: unknown error"
     return
 
 def get_rate_from_yahoo():
   global headers
-  global rate_usd_cny, rate_xau_cny
+  global rate_usd_cny, rate_xau_cny, rate_usd_eur
   try:
     url="http://download.finance.yahoo.com/d/quotes.csv"
-    params = {'s':'USDCNY=X,XAUCNY=X','f':'l1','e':'.csv'}
+    params = {'s':'USDCNY=X,XAUCNY=X,USDEUR=X','f':'l1','e':'.csv'}
     responce = requests.get(url=url, headers=headers,params=params)
     pos = posnext = 0
     posnext = responce.text.find("\n", pos)
@@ -78,6 +80,10 @@ def get_rate_from_yahoo():
     posnext = responce.text.find("\n", pos)
     rate_xau_cny = float(responce.text[pos:posnext])
     print "Fetch: rate xau/cny", rate_xau_cny
+    pos = posnext + 1
+    posnext = responce.text.find("\n", pos)
+    rate_usd_eur = float(responce.text[pos:posnext])
+    print "Fetch: rate usd/eur", rate_usd_eur
   except:
     print "Warning: unknown error, try again after 1 seconds"
     time.sleep(1)
@@ -122,6 +128,7 @@ def confirm():
 
 rate_usd_cny = 0.0
 rate_xau_cny = 0.0
+rate_usd_eur = 0.0
 get_rate_from_yahoo()
 
 price = {}
Maybe this helps

quick and durty ... gonna pimp it a little tomorrow ... going from btsx to cny to usd to eur is kind of .... ugly

Offline Riverhead

Added GLD to my feed. Will need to look into the EUR feed which isn't working currently.

Offline cube

  • Hero Member
  • *****
  • Posts: 1404
  • Bit by bit, we will get there!
    • View Profile
  • BitShares: bitcube
Hey delegates,

some people around are eagerly awaiting the bitGLD
https://bitsharestalk.org/index.php?topic=8759.msg114934#msg114934
and the bitEUR
https://bitsharestalk.org/index.php?topic=6406.msg114296#msg114296

Bytemaster and I3 gave a "green light" for the community to freely publish any feeds.


Gold prices declined to their 3-month low this month and many are interested to get some gold.  With the timely introduction of bitGLD, we are entering into an exciting time!  +5%
ID: bitcube
bitcube is a dedicated witness and committe member. Please vote for bitcube.

Offline serejandmyself

  • Sr. Member
  • ****
  • Posts: 358
    • View Profile
Before we get BitGold going, perhaps we should give BitBTC some love? That market is really thin.
Maybe there is a reason people don't use bitBTC? Why put money there if you can have a superior bitUSD?

I think bitBTC is a nice-to-have .. but not worth too much love

why not? i have bitBtc  :)
btsx - bitsharesrussia

Offline speedy

  • Hero Member
  • *****
  • Posts: 1160
    • View Profile
  • BitShares: speedy
Before we get BitGold going, perhaps we should give BitBTC some love? That market is really thin.
Maybe there is a reason people don't use bitBTC? Why put money there if you can have a superior bitUSD?

I think bitBTC is a nice-to-have .. but not worth too much love

For some purposes BitBTC is more appropriate than BitUSD. For example if I just want to day-trade BTSX and dont want to worry about Bitcoin volatility. I keep looking at the BitUSD chart every day, and to make sense of it you have to work out what the current USD price of Bitcon is.

Offline xeroc

  • Board Moderator
  • Hero Member
  • *****
  • Posts: 12922
  • ChainSquad GmbH
    • View Profile
    • ChainSquad GmbH
  • BitShares: xeroc
  • GitHub: xeroc
Before we get BitGold going, perhaps we should give BitBTC some love? That market is really thin.
Maybe there is a reason people don't use bitBTC? Why put money there if you can have a superior bitUSD?

I think bitBTC is a nice-to-have .. but not worth too much love

Offline speedy

  • Hero Member
  • *****
  • Posts: 1160
    • View Profile
  • BitShares: speedy
Before we get BitGold going, perhaps we should give BitBTC some love? That market is really thin.

Offline kisa

  • Sr. Member
  • ****
  • Posts: 240
    • View Profile
bitEUR is important also. then we can trace how bitEUR/bitUSD rate compares to EUR/USD. And some folks from Europe probably prefer bitEUR to bitUSD as a currency. Will be difficult to get market depth at start, as BTSX not trading in EUR terms on exchanges.

bitGLD sounds exciting and probably good marketing tool, but IMHO bridges USD -> bitUSD and EUR -> bitEUR are more important for wider adoption and will be easier to implement worldwide than GLD -> bitGLD...

(wouldn't be EUR/bitEUR market the easiest new product for bitstamp to offer?)
« Last Edit: September 13, 2014, 03:57:51 pm by kisa0145 »

Offline CLains

  • Hero Member
  • *****
  • Posts: 2606
    • View Profile
  • BitShares: clains