It was the Bitcointalk forum that inspired us to create Bitcointalksearch.org - Bitcointalk is an excellent site that should be the default page for anybody dealing in cryptocurrency, since it is a virtual gold-mine of data. However, our experience and user feedback led us create our site; Bitcointalk's search is slow, and difficult to get the results you need, because you need to log in first to find anything useful - furthermore, there are rate limiters for their search functionality.
The aim of our project is to create a faster website that yields more results and faster without having to create an account and eliminate the need to log in - your personal data, therefore, will never be in jeopardy since we are not asking for any of your data and you don't need to provide them to use our site with all of its capabilities.
We created this website with the sole purpose of users being able to search quickly and efficiently in the field of cryptocurrency so they will have access to the latest and most accurate information and thereby assisting the crypto-community at large.
#!/usr/bin/env python
import subprocess
import os
import sys
from subprocess import Popen, PIPE
import fcntl
import time
import glob
tmpfile = '/home/baikal/tmp.bin'
path = '/media/boot/G*.bin'
fwfile = glob.glob(path)
if not fwfile:
print 'No firmware'
sys.exit()
USBDEVFS_RESET= 21780
# enter dfu mode
def enter_dfumode():
subprocess.call('echo 0 > /sys/class/gpio_sw/PA18/data', shell=True)
subprocess.call('echo 0 > /sys/class/gpio_sw/PA10/data', shell=True)
subprocess.call('echo 1 > /sys/class/gpio_sw/PA10/data', shell=True)
def exit_dfumode():
subprocess.call('echo 1 > /sys/class/gpio_sw/PA18/data', shell=True)
subprocess.call('echo 0 > /sys/class/gpio_sw/PA10/data', shell=True)
subprocess.call('echo 1 > /sys/class/gpio_sw/PA10/data', shell=True)
def reset_usb(driver):
try:
lsusb_out = Popen("lsusb | grep -i %s"%driver, shell=True, bufsize=64, stdin=PIPE, stdout=PIPE, close_fds=True).stdout.read().strip().split()
bus = lsusb_out[1]
device = lsusb_out[3][:-1]
f = open("/dev/bus/usb/%s/%s"%(bus, device), 'w', os.O_WRONLY)
fcntl.ioctl(f, USBDEVFS_RESET, 0)
except Exception, msg:
print ""
def update_firmware():
enter_dfumode()
reset_usb("DFU")
print 'Downloading... ' + fwfile[0]
cmd = 'sudo dfu-util -a 0 -d 0483:df11 -s 0x08000000:leave -D ' + fwfile[0]
subprocess.call(cmd, shell=True)
cmd = 'sudo rm -rf ' + path
subprocess.call(cmd, shell=True)
enter_dfumode()
reset_usb("STM32F407")
reset_usb("DFU")
update_firmware()
exit_dfumode()
print "Done"