예제 #1
0
 def flash_parameter(self, parameter_file):
   with open(parameter_file) as fh:
     data = fh.read()
     buf = rkcrc.make_parameter_image(data)
   assert len(buf) <= PART_BLOCKSIZE
   with io.BytesIO(buf) as fh:
     self.__logger.print_dividor()
     self.__logger.log('\tWriting parameter file %s\n' % (parameter_file))
     self.__flash_image_file(0x00000000, PART_BLOCKSIZE, fh)
예제 #2
0
파일: rktalk.py 프로젝트: BJBSJS/rkflashkit
 def flash_parameter(self, parameter_file):
   with open(parameter_file) as fh:
     data = fh.read()
     buf = rkcrc.make_parameter_image(data)
   assert len(buf) <= PART_BLOCKSIZE
   with io.BytesIO(buf) as fh:
     self.__logger.print_dividor()
     self.__logger.log('\tWriting parameter file %s\n' % (parameter_file))
     self.__flash_image_file(0x00000000, PART_BLOCKSIZE, fh)