[mtldr] Add udev rules, use new vid/pid, separate bootloader usb from main system usb.
This commit is contained in:
8
tools/moot/95-coral.rules
Normal file
8
tools/moot/95-coral.rules
Normal file
@@ -0,0 +1,8 @@
|
||||
ACTION!="add|change", GOTO="coral_rules_end"
|
||||
SUBSYSTEM!="usb", GOTO="coral_rules_end"
|
||||
ENV{DEVTYPE}!="usb_device", GOTO="coral_rules_end"
|
||||
|
||||
# ST-LINK/V2
|
||||
ATTRS{idVendor}=="18D1", ATTRS{idProduct}=="A010", MODE="777"
|
||||
|
||||
LABEL="coral_rules_end"
|
||||
8
tools/moot/mtldr.py → tools/moot/mtldr
Normal file → Executable file
8
tools/moot/mtldr.py → tools/moot/mtldr
Normal file → Executable file
@@ -1,3 +1,5 @@
|
||||
#! /usr/bin/env python
|
||||
|
||||
"""
|
||||
Copyright 2016 Google Inc. All Rights Reserved.
|
||||
Author: gkalsi@google.com (Gurjant Kalsi)
|
||||
@@ -67,14 +69,14 @@ class CommandParam:
|
||||
def __init__(self, data_phase_type):
|
||||
self.data_phase_type = data_phase_type
|
||||
|
||||
VENDOR_ID = 0x9999
|
||||
PRODUCT_ID = 0x9999
|
||||
VENDOR_ID = 0x18D1
|
||||
PRODUCT_ID = 0xA010
|
||||
CLASS_VENDOR_SPECIFIC = 0xFF
|
||||
SUBCLASS_MTLDR_DEBUG = 0x01
|
||||
|
||||
# create logger
|
||||
logger = logging.getLogger('mtldr')
|
||||
logger.setLevel(logging.WARN)
|
||||
logger.setLevel(logging.INFO)
|
||||
|
||||
|
||||
class FindByDeviceClass(object):
|
||||
1
tools/moot/requirements.txt
Normal file
1
tools/moot/requirements.txt
Normal file
@@ -0,0 +1 @@
|
||||
pyusb==1.0.0rc1
|
||||
Reference in New Issue
Block a user