Bitcoin Forum
May 30, 2024, 06:34:02 PM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
  Home Help Search Login Register More  
  Show Posts
Pages: « 1 2 [3] 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 »
41  Alternate cryptocurrencies / Altcoin Discussion / Re: First GENUE LTC FPGA on: September 20, 2013, 04:10:27 PM
No, I am doing it for money, so most information are classified till I sell for good reason

Why post it at all at this point?

I am looking to inform community about this project, while keeping sensitive information, which may affect project development if disclosed,  private.
42  Alternate cryptocurrencies / Altcoin Discussion / Re: First GENUE LTC FPGA on: September 20, 2013, 03:30:59 PM
it look very ugly, when complete can you give better look?

It is designed the way it is designed for the same reason an AK47 it is designed the way it is designed.
All three rams are working at max possible speed. And will probably have another iteration, and this is not the only RAM board I have ready.
43  Alternate cryptocurrencies / Altcoin Discussion / Re: First GENUE LTC FPGA on: September 20, 2013, 03:28:35 PM
Well I'll be damned.

Weird stuff.

A google search query of the device ID's ("idVendor=0x1234" "idProduct=0x1010") yields many links to z.download.csdn.net where such information is referenced almost exactly, some kind of chinese internet forum. Apparently this has something to do with "STM32", which is a model of ARM Cortex MCUs. It seems to me the device id's referenced might be the ones of those devices.

Or maybe it's a generic idVendor and idProduct, but those were the only matches I could find.

Otherwise I could not find any correlation between what he posted and anything currently findable by google.

I have to say, it's a mystery. Maybe he does have an fpga miner, but it's single-threaded and does not resolve any of the scrypt fpga-mining issues that makes it so unprofitable so is more or less exactly worthless.

0x1234 was default in the usb stack I used. 0x1010 si for visual, I had many of this boards connected to a linux and I needed a way to quick recognize them in lsusb output.
But all this effort and you didn't notice that it uses a derivation of BFL SC communication protocol.. Smiley
44  Local / Romānă (Romanian) / Re: Bai! on: September 20, 2013, 03:18:12 PM
Cel mai probabil Zephyr e teapa, din cauza ca chipul ala nu are capsula potrivita pentru viteza pe care o pretind.
5Mhs / 1000 W nu este o problema. Dar nu stiu daca se poate obtine 0.2USD / Khs cu FPGA-uri. Ce e drept nu am evaluat generatiile mai vechi de componente. Dar daca merg pe generatii mai vechi, se schimba consumul.
45  Alternate cryptocurrencies / Altcoin Discussion / Re: First GENUE LTC FPGA on: September 20, 2013, 01:01:10 AM

Post the source to test_miner.py, since all it is is a mining client and would not release any confidential information. If it shows legitimate USB or serial port interfacing code of some sort then I'll believe you.

Why not.
But this is last time I will answer such a direct question. The rest is classified. The code is really crappy since it is part of some iteration which was tested long ago:

Quote
import usb.core
import usb.util
import time
from threading import Thread, Event, RLock
import sys
import re
import struct

# find our device
dev = usb.core.find(idVendor=0x1234, idProduct=0x1010)

# was it found?
if dev is None:
    raise ValueError('Device not found')

# set the active configuration. With no arguments, the first
# configuration will be the active one
dev.set_configuration()

run_app = 1

def get_time_str():
   lt = time.localtime(time.time())
   return "%d:%d:%d" %(lt.tm_hour, lt.tm_min, lt.tm_sec)

#######################################################################################      
#######################################################################################      
class   EP2_listener(Thread):
   def   __init__(self):
      Thread.__init__(self)
      self.count = [0, 0]
      self.starttime = time.time()
      self.daemon = True
   def run(self):
      global run_app
      print "[%s]EP2_listener started" % get_time_str()
      while run_app:
         ret = ''
         try:
            ret = dev.read(0x82, 64, 0, 100)
            log_msg = ''.join([chr(x) for x in ret])
            sys.stdout.write(log_msg)
         except Exception as e:
            pass      
         if len(ret) == 0:
            time.sleep(0.01)

############ startez thread #########
listener = EP2_listener()            
listener.start()
#####################################

def wr_dev_ok_err(msg):

   try:
      dev.write(1, msg, 0, 3100)
      tick = time.time()   
      while time.time() < tick + 1.0:
         try:
            ret = dev.read(0x81, 64, 0, 3100)
            retbuf = ''.join([chr(x) for x in ret])
            if re.search("OK", retbuf):
               print retbuf
               return 1
            if re.search("ERR", retbuf):
               print retbuf
               return -1
            if re.search("BUSY", retbuf):
               print retbuf
               return -2
            print "retbuf="+retbuf
         except Exception as e:
            print e
            pass
   except Exception as e:
      print e
      pass
   return 0


def get_ok():
   tick = time.time()   
   while time.time() < tick + 1.0:
      try:
         ret = dev.read(0x81, 256, 0, 3100)
         retbuf = ''.join([chr(x) for x in ret])
         if re.search("OK", retbuf):
            print "got OK:" + retbuf
            return 1
         if re.search("ERR", retbuf):
            print retbuf
            return -1
         if re.search("BUSY", retbuf):
            print retbuf
            return -2
         print "retbuf="+retbuf
      except Exception as e:
         print e
         pass
   

def wr_dev(msg):

   try:
      dev.write(1, msg, 0, 3100)
      tick = time.time()   
      while time.time() < tick + 1.0:
         try:
            ret = dev.read(0x81, 64, 0, 3100)
            retbuf = ''.join([chr(x) for x in ret])
            if len(retbuf):
               #print "retbuf="+retbuf
               return retbuf
         except Exception as e:
            #print e
            pass
   except Exception as e:
      #print e
      pass
   return 0   

def ask_op(op):
   wr_dev("Z7X,00000000%02x"% (op &0xff))
   retcode = wr_dev("Z7X,0100000200")
   return retcode
   
def memvar_dump(ram_off, len, name):

   wr_dev("Z7X,%08lx05" % ram_off)
   
   ar = []
   for j in xrange(len):
      retcode = ask_op(0x07)
      val = 0
      try:
         val = int(retcode, 16)
      except:
         pass
      ar.append(val)
   return ar   
tick = time.time()
run_once = 1
time.sleep(0.5)
print "GET_ID=%s" % ask_op(1)


########################################################
#### dll result ####
########################################################
#######################################################################################      
#######################################################################################      

def uint32(x):
   return x & 0xffffffffL

def bytereverse(x):
   return uint32(( ((x) << 24) | (((x) << Cool & 0x00ff0000) |
         (((x) >> Cool & 0x0000ff00) | ((x) >> 24) ))

def bufreverse(in_buf):
   out_words = []
   for i in range(0, len(in_buf), 4):
      word = struct.unpack('@I', in_buf[i:i+4])[0]
      out_words.append(struct.pack('@I', bytereverse(word)))
   return ''.join(out_words)

#######################################################################################      
host = "127.0.0.1"
http_port = 8337
#host = "mine.pool-x.eu"
#http_port = 8337
#host = "pool1.us.multipool.us"
#http_port = 17777
host = "mining.eu.hypernova.pw"
http_port = 9332
host = "pooledbits.com"
http_port = 8332
user = "xxxx"
password = "x"
#######################################################################################      



import json
import base64

from ctypes import cdll, byref
lib = cdll.LoadLibrary('./scrypt.dll')
#print lib
import ctypes
class Scrypt(object):
   def __init__(self):
      #self.obj = lib.say_hello()
      none = 0
   def scanhash(self, pdata, ptarget, max_nonce, c_long_last_nonce, n):
      return lib.scanhash_scrypt(pdata, ptarget, max_nonce, c_long_last_nonce, n)


scr = Scrypt()
long_polling_path = ''

import time

while 1:
   #try:
   if 1:
      #print "getwork->con_init()"
      import httplib
      conn = httplib.HTTPConnection(host, http_port, True, 10)
      #print "getwork->con_established"
      
      req = json.dumps({"method": "getwork", "params": [], "id": 'json'})
      auth = "Basic " + base64.b64encode(user+ ":" + password)
      headers = {"User-Agent": "lt_miner", "Content-type": "application/json", "Content-Length": len(req), "Authorization": auth}
      #print "getwork->req_sent"
      conn.request("POST", '/', req, headers)
      #print "getwork->req_answered"
      http_response = conn.getresponse()
      buf = http_response.read()
      #print "http_response=%s" % buf
      response = json.loads(buf)
      #print "getwork->got_data"
      if response["error"] != None:
         print "error [%s]" % response["error"]
         sys.exit(1)
      if response["result"]:
            #print("getwork() ok\n")
            work = response['result']   
            #print work
            if long_polling_path == '':
               headers = http_response.getheaders()                                 
               for (key,val) in headers:
                  if key == "x-long-polling":
                     long_polling_path = val
            if long_polling_path != '':
               do_long_poll = True
               
            ######################################################
            stime = time.time()
            last_nonce = ctypes.c_long(0)
            #n = 0
            #data = work['data'].decode('hex')
            data_orig = work['data']
            data_pt_c = work['data'].decode('hex')
            #target = work['target'].decode('hex')
            target_pt_c = work['target'].decode('hex')
            target = work['target']
            #print "data_orig=%s" % data_orig
            #print "target(full, bytereversed)=%s" % target
            print "data=%s." % data_orig[:73]
            # sys.exit(1)
            #res = scr.scanhash(data, target, 0xffff, byref(last_nonce), n )
            
            
            ######################################################
            target_short = 0xffffffff
            if len(target) > 8:
               #target_short = bufreverse(target[56:].decode('hex'))
               target_short = bytereverse(int(target[56:], 16)) ^ 0xffffffff
            target_short = 0xffff0000   #wired diff 1
            #print "target(bit_complemented)=%08lx" % target_short
            data = data_orig.decode('hex')
            data = bufreverse(data)
            #print data.encode('hex')
            
            ram_off = 4262
            wr_dev("Z7X,%08lx05" % ram_off)
            for i in xrange(19):
               word = struct.unpack('@I', data[i*4:i*4+4])[0]
               wr_dev("Z7X,%08lx06" % word)
            wr_dev("Z7X,0000000006")   #### nonce
            wr_dev("Z7X,0000ffff06")   #### range
            wr_dev("Z7X,%08lx06" % target_short)
            wr_dev("Z7X,000000000e")   
            start = time.time()
            tick = time.time() + 1.0
            while 1:
               time.sleep(0.1)
               retcode = wr_dev("Z7X,0000000000")
               if re.search("515151", retcode):
                  time.sleep(0.01)
               else:
                  retcode = wr_dev("Z7X,0000000000")
                  if not re.search("515151", retcode):
                     time.sleep(0.01)
                     delta_time = (time.time() - start) * 1000
                     print "Scanhash took %d ms" % (delta_time),
                     rram = memvar_dump(4281, 1, "nonce")
                     print "/ Approximate speed = %.2f kHash" %((float(rram[0])) / (delta_time))
                     break
               if time.time() > tick:
                  tick = time.time() + 1.0
                  print ".",

            rram = memvar_dump(4281, 1, "nonce")
            nonce = rram[0]
            res = 0
            if nonce < 0x10000:
               res = 1
            ###########################################################################
            nonce_str = "%08lx" %(nonce & 0xffffffff)
            data_new = data_orig[:156] + nonce_str[4:] + data_orig[160:]
            n = nonce - 1   
            res2 = scr.scanhash(data_pt_c, target_pt_c, nonce + 1, byref(last_nonce), n )
            if res != 0 and res2 != 0:
               f = open("succ.txt", "a")
               f.write("----NEW BLOCK----\n")
               f.write("data_orig:\n%s\n" % data_orig)
               f.write("data_new:\n%s\n" % data_new)
               f.write("nonce=%08lx\n" % nonce)
               try:
                  sconn = httplib.HTTPConnection(host, http_port, True, 10)
                  req = json.dumps({"method": "getwork", "params": [data_new], "id": 0})
                  auth = "Basic " + base64.b64encode(user+ ":" + password)
                  headers = {"User-Agent": "lt_miner", "Content-type": "application/json", "Content-Length": len(req), "Authorization": auth}
                  sconn.request("POST", '/', req, headers)
                  response = json.loads(sconn.getresponse().read())
                  if response["error"] != None:
                     print ("Server reported error: %s\n" % response["error"])
                     f.write("Server reported error: %s\n" % response["error"]);
                     time.sleep(1.0)
                  if response["result"]:
                     print "%04x accepted"  % (nonce)
                     f.write("accepted nonce=%04x %s\n"  % (nonce, response["result"]));
                  else:
                     f.write("rejected share [%s]\n" % response["result"]);
                     
               except Exception as e:
                  print("Error while uploading share e=%s\n" % e)
                  f.write("Error while uploading share e=%s\n" % e);
                  time.sleep(1.0)            
               f.write("----END BLOCK----\n\n")
               f.close()

   # except Exception as e:
      # print e
      # sys.exit(1)
   time.sleep(1.0)
46  Local / Romānă (Romanian) / Re: Bai! on: September 20, 2013, 12:41:03 AM
Invidia  Wink ...man tu fa treaba mai departe si loveste piata la timpul potrivit  Cheesy

Merci, merci...

Doar ca ma intreaba toata lumea.. Scuze de deranj!
47  Alternate cryptocurrencies / Altcoin Discussion / Re: First GENUE LTC FPGA on: September 20, 2013, 12:20:21 AM
Basic design means this is iteration 59 sub iteration 7 from major iterations 119, just a post for my old thread, some objective answer. I did expect some stir, but I didn't expect so much or I would have post it long ago, lol..
48  Alternate cryptocurrencies / Altcoin Discussion / Re: First GENUE LTC FPGA on: September 20, 2013, 12:14:56 AM
I said 1$ per Khs
49  Alternate cryptocurrencies / Altcoin Discussion / Re: First GENUE LTC FPGA on: September 19, 2013, 11:55:00 PM
Will you be releasing the vhdl sources? Have you overcome the problem of mass parallelization that is required to get high performance? What is the model/make is your FPGA and how much did it cost?

No, I am doing it for money, so most information are classified till I sell for good reason, eg. I want to keep decent prices on components.
I think I did answers most questions when I told you that you can get such hardware at 1$ - 1.5$ (closer to 1) and less than 0.13 W per Khs.
 I will continue to provide videos as proofs.. Smiley
50  Local / Romānă (Romanian) / Bai! on: September 19, 2013, 11:40:18 PM
Am fost apelat in PM-uri de multe ori. De ce nu arati, de ce nu faci, de ce, de ce...
Am bagat si eu un video cu una din placile mele... am alte patru..
Cum face un stick de ram la 350Mhz 20khs..
Topic-ul vechi de o luna mi-a fost inchis, da?
https://vimeo.com/m/74955720

https://bitcointalk.org/index.php?topic=283977.80

AM REZOLVAT cu topicul, merci!
51  Alternate cryptocurrencies / Altcoin Discussion / Re: First GENUE LTC FPGA on: September 19, 2013, 11:31:45 PM
I do not quite understand why you are being so informal about something that would be so significant? Is this a joke or real?
What dude?
I just shown some basic design on a stick of ram.
Basic means I can multiply frequency by two, add some tricks in memory utilization which means memory utilization will be divided by at least two... that's some basic design..
52  Alternate cryptocurrencies / Altcoin Discussion / First GENUE LTC FPGA on: September 19, 2013, 10:35:34 PM
Hi,
Just my new topic showing my RAM based board doing 22kHash/s at 350 Mhz RAM clock:
https://vimeo.com/m/74955720
53  Alternate cryptocurrencies / Altcoin Discussion / Re: A RAM based fpga LTC miner on: September 19, 2013, 09:14:53 PM
Man, no offense, for 3w you cant count at power plug..
54  Alternate cryptocurrencies / Altcoin Discussion / Re: A RAM based fpga LTC miner on: September 19, 2013, 08:57:46 PM
What kilowat, lol, its about wats, 300 mA on 10 Volts..
55  Alternate cryptocurrencies / Altcoin Discussion / Re: A RAM based fpga LTC miner on: September 19, 2013, 08:19:32 PM
Max hash rate on raw scrypt with external ram is ram_transfer_freq * bus_width / (1024 bits * 2048 rw). With special tricks can go more than double. For example, a ddr3 stick working at 350 mhz will produce raw 22khs, as in this basic design:
 https://vimeo.com/m/74955720
Power consumption is 3W. Costs less than 1.5$/khs.
56  Alternate cryptocurrencies / Altcoin Discussion / A RAM based fpga LTC miner on: August 30, 2013, 12:50:09 AM
Here it is!
More info later

57  Local / Romānă (Romanian) / Re: Rezumat BFL on: July 26, 2013, 09:59:30 PM
Aw, asa faci mereu, dai cu teaser-u“ si fugi.
Stai asa, arunca-ne si noua o firimitura...ce faci acolo, cresti barzauni acum?

barzauni, indeed, nici nu puteai sa zici mai bine.. Smiley
58  Local / Romānă (Romanian) / Re: BFL order on: July 26, 2013, 08:05:18 PM
Super tare. deci vei fi printre primii romani care va avea BFL

Weekend-ul acesta dam drumul si la bitcoinromania.info unde de asemeni vom lansa podcast Bitcoin ROmania.

Esti invitatul nostru pentru primul episod unde cred ca te vei mandri cu noua achizitie, facand un Unboxing & Demo.

Sa il stapanesti sanatos si sa produci cat mai multi betecei:P

Ca o poanta; de lene sa nu scriu drivere pentru placile noi (care nu sunt de vanzare, pentru cine intreaba), am luat drafturile de protocol publicate de Josh (care nu sunt complete) si driveru scris de kano si am facut oleaca de reverse engineering.. Ma conectam cu BAJ-uri fake la pool-urile principale inca de acum cateva luni.. Smiley
Merg mai incet decat aplicatiile mele dar nici nu tin sistemul in 700% load average.
59  Economy / Currency exchange / Re: Please forgive my newbish question on how to obtain BTC on: July 26, 2013, 07:50:03 PM
You may try Bitstamp, best BTC exchange I played with, but only from inside EU. No idea how is it working from outside.
60  Local / Romānă (Romanian) / Re: Valoare bitcoin on: June 30, 2013, 12:03:54 AM
Da, pentru ca mai mult de 51% din Bitcoin e produs in China? Cheesy
Pages: « 1 2 [3] 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 »
Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!