Bläddra i källkod

pblprog: Fix imports

Signed-off-by: Manatsawin Hanmongkolchai <git@whs.in.th>
Manatsawin Hanmongkolchai 5 månader sedan
förälder
incheckning
4cf0b60ecc

+ 3 - 3
python_libs/pblprog/pebble/programmer/__init__.py

@@ -12,9 +12,9 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
-from targets import STM32F4FlashProgrammer, STM32F7FlashProgrammer
-from swd_port import SerialWireDebugPort
-from ftdi_swd import FTDISerialWireDebug
+from .targets import STM32F4FlashProgrammer, STM32F7FlashProgrammer
+from .swd_port import SerialWireDebugPort
+from .ftdi_swd import FTDISerialWireDebug
 
 def get_device(board, reset=True, frequency=None):
     boards = {

+ 2 - 2
python_libs/pblprog/pebble/programmer/__main__.py

@@ -25,11 +25,11 @@ def main(args=None):
         parser.add_argument('--board', action='store', choices=['robert_bb2', 'silk_bb'], required=True,
                             help='Which board is being programmed')
         parser.add_argument('--verbose', action='store_true',
-	                        help='Output lots of debugging info to the console.')
+                            help='Output lots of debugging info to the console.')
 
         args = parser.parse_args()
 
-	logging.basicConfig(level=(logging.DEBUG if args.verbose else logging.INFO))
+    logging.basicConfig(level=(logging.DEBUG if args.verbose else logging.INFO))
 
     flash(args.board, args.hex_files)
 

+ 1 - 1
python_libs/pblprog/pebble/programmer/ftdi_swd.py

@@ -14,7 +14,7 @@
 
 from array import array
 
-from pyftdi.pyftdi.ftdi import Ftdi
+from pyftdi.ftdi import Ftdi
 import usb.util
 
 class FTDISerialWireDebug(object):

+ 1 - 1
python_libs/pblprog/pebble/programmer/targets/stm32f4.py

@@ -12,7 +12,7 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
-from stm32 import STM32FlashProgrammer
+from .stm32 import STM32FlashProgrammer
 
 class STM32F4FlashProgrammer(STM32FlashProgrammer):
     IDCODE = 0x2BA01477

+ 1 - 1
python_libs/pblprog/pebble/programmer/targets/stm32f7.py

@@ -12,7 +12,7 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
-from stm32 import STM32FlashProgrammer
+from .stm32 import STM32FlashProgrammer
 
 class STM32F7FlashProgrammer(STM32FlashProgrammer):
     IDCODE = 0x5BA02477