Commit 27fc9f75 authored by Grzegorz Daniluk's avatar Grzegorz Daniluk

sdbfs/gen_flash_image: let the script run also standalone, without the PTS

parent 42a97e15
...@@ -87,22 +87,24 @@ def gen_sdb_image(type, mac, bstr, output=None): ...@@ -87,22 +87,24 @@ def gen_sdb_image(type, mac, bstr, output=None):
print "Generated image (" + sdbfs_img + ") copied to " + output print "Generated image (" + sdbfs_img + ") copied to " + output
########################################################### ###########################################################
#if len(sys.argv) < 3: if __name__ == "__main__":
# print "Wrong syntax" if len(sys.argv) < 3:
# print sys.argv[0] + " <flash/eeprom> <mac> [bitstream]" print "Wrong syntax"
# sys.exit() print sys.argv[0] + " <flash/eeprom> <mac> [bitstream]"
# sys.exit()
#type = sys.argv[1]
#if type != "flash" and type != "eeprom": type = sys.argv[1]
# print "Wrong syntax" if type != "flash" and type != "eeprom":
# print sys.argv[0] + " <flash/eeprom> <mac> [bitstream]" print "Wrong syntax"
# sys.exit() print sys.argv[0] + " <flash/eeprom> <mac> [bitstream]"
# sys.exit()
#mac = check_mac(sys.argv[2])
# #mac = check_mac(sys.argv[2])
#if len(sys.argv) > 3: mac = sys.argv[2]
# bitstream = sys.argv[3]
#else: if len(sys.argv) > 3:
# bitstream = "" bitstream = sys.argv[3]
# else:
#gen_sdb_image(type, mac, bitstream) bitstream = ""
gen_sdb_image(type, mac, bitstream)
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment