dRonin  adbada4
dRonin firmware
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
px_uploader.uploader Class Reference
Inheritance diagram for px_uploader.uploader:

Public Member Functions

def __init__
 
def close
 
def identify
 
def upload
 
def send_reboot
 

Data Fields

 port
 
 otp
 
 sn
 
 bl_rev
 
 board_type
 
 board_rev
 
 fw_maxsize
 
 otp_id
 
 otp_idtype
 
 otp_vid
 
 otp_pid
 
 otp_coa
 

Static Public Attributes

string INSYNC = b'\x12'
 
string EOC = b'\x20'
 
string OK = b'\x10'
 
string FAILED = b'\x11'
 
string INVALID = b'\x13'
 
string BAD_SILICON_REV = b'\x14'
 
string NOP = b'\x00'
 
string GET_SYNC = b'\x21'
 
string GET_DEVICE = b'\x22'
 
string CHIP_ERASE = b'\x23'
 
string CHIP_VERIFY = b'\x24'
 
string PROG_MULTI = b'\x27'
 
string READ_MULTI = b'\x28'
 
string GET_CRC = b'\x29'
 
string GET_OTP = b'\x2a'
 
string GET_SN = b'\x2b'
 
string GET_CHIP = b'\x2c'
 
string SET_BOOT_DELAY = b'\x2d'
 
string GET_CHIP_DES = b'\x2e'
 
int MAX_DES_LENGTH = 20
 
string REBOOT = b'\x30'
 
string INFO_BL_REV = b'\x01'
 
int BL_REV_MIN = 2
 
int BL_REV_MAX = 5
 
string INFO_BOARD_ID = b'\x02'
 
string INFO_BOARD_REV = b'\x03'
 
string INFO_FLASH_SIZE = b'\x04'
 
int PROG_MULTI_MAX = 252
 
int READ_MULTI_MAX = 252
 
tuple NSH_INIT = bytearray(b'\x0d\x0d\x0d')
 
string NSH_REBOOT_BL = b"reboot -b\n"
 
string NSH_REBOOT = b"reboot\n"
 
tuple MAVLINK_REBOOT_ID1 = bytearray(b'\xfe\x21\x72\xff\x00\x4c\x00\x00\x80\x3f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\xf6\x00\x01\x00\x00\x48\xf0')
 
tuple MAVLINK_REBOOT_ID0 = bytearray(b'\xfe\x21\x45\xff\x00\x4c\x00\x00\x80\x3f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\xf6\x00\x00\x00\x00\xd7\xac')
 

Private Member Functions

def __send
 
def __recv
 
def __recv_int
 
def __getSync
 
def __sync
 
def __trySync
 
def __getInfo
 
def __getOTP
 
def __getSN
 
def __getCHIP
 
def __getCHIPDes
 
def __drawProgressBar
 
def __erase
 
def __program_multi
 
def __verify_multi
 
def __reboot
 
def __split_len
 
def __program
 
def __verify_v2
 
def __verify_v3
 
def __set_boot_delay
 

Detailed Description

Uploads a firmware file to the PX FMU bootloader

Definition at line 140 of file px_uploader.py.

Constructor & Destructor Documentation

def px_uploader.uploader.__init__ (   self,
  portname,
  baudrate 
)

Definition at line 187 of file px_uploader.py.

Member Function Documentation

def px_uploader.uploader.__drawProgressBar (   self,
  label,
  progress,
  maxVal 
)
private

Definition at line 294 of file px_uploader.py.

def px_uploader.uploader.__erase (   self,
  label 
)
private

Definition at line 305 of file px_uploader.py.

def px_uploader.uploader.__getCHIP (   self)
private

Definition at line 280 of file px_uploader.py.

def px_uploader.uploader.__getCHIPDes (   self)
private

Definition at line 286 of file px_uploader.py.

def px_uploader.uploader.__getInfo (   self,
  param 
)
private

Definition at line 257 of file px_uploader.py.

def px_uploader.uploader.__getOTP (   self,
  param 
)
private

Definition at line 264 of file px_uploader.py.

def px_uploader.uploader.__getSN (   self,
  param 
)
private

Definition at line 272 of file px_uploader.py.

def px_uploader.uploader.__getSync (   self)
private

Definition at line 213 of file px_uploader.py.

def px_uploader.uploader.__program (   self,
  label,
  fw 
)
private

Definition at line 378 of file px_uploader.py.

def px_uploader.uploader.__program_multi (   self,
  data 
)
private

Definition at line 330 of file px_uploader.py.

def px_uploader.uploader.__reboot (   self)
private

Definition at line 364 of file px_uploader.py.

def px_uploader.uploader.__recv (   self,
  count = 1 
)
private

Definition at line 201 of file px_uploader.py.

def px_uploader.uploader.__recv_int (   self)
private

Definition at line 208 of file px_uploader.py.

def px_uploader.uploader.__send (   self,
  c 
)
private

Definition at line 197 of file px_uploader.py.

def px_uploader.uploader.__set_boot_delay (   self,
  boot_delay 
)
private

Definition at line 425 of file px_uploader.py.

def px_uploader.uploader.__split_len (   self,
  seq,
  length 
)
private

Definition at line 374 of file px_uploader.py.

def px_uploader.uploader.__sync (   self)
private

Definition at line 227 of file px_uploader.py.

def px_uploader.uploader.__trySync (   self)
private

Definition at line 236 of file px_uploader.py.

def px_uploader.uploader.__verify_multi (   self,
  data 
)
private

Definition at line 344 of file px_uploader.py.

def px_uploader.uploader.__verify_v2 (   self,
  label,
  fw 
)
private

Definition at line 394 of file px_uploader.py.

def px_uploader.uploader.__verify_v3 (   self,
  label,
  fw 
)
private

Definition at line 410 of file px_uploader.py.

def px_uploader.uploader.close (   self)

Definition at line 193 of file px_uploader.py.

def px_uploader.uploader.identify (   self)

Definition at line 432 of file px_uploader.py.

def px_uploader.uploader.send_reboot (   self)

Definition at line 512 of file px_uploader.py.

def px_uploader.uploader.upload (   self,
  fw 
)

Definition at line 447 of file px_uploader.py.

Field Documentation

string px_uploader.uploader.BAD_SILICON_REV = b'\x14'
static

Definition at line 151 of file px_uploader.py.

px_uploader.uploader.bl_rev

Definition at line 437 of file px_uploader.py.

int px_uploader.uploader.BL_REV_MAX = 5
static

Definition at line 173 of file px_uploader.py.

int px_uploader.uploader.BL_REV_MIN = 2
static

Definition at line 172 of file px_uploader.py.

px_uploader.uploader.board_rev

Definition at line 443 of file px_uploader.py.

px_uploader.uploader.board_type

Definition at line 442 of file px_uploader.py.

string px_uploader.uploader.CHIP_ERASE = b'\x23'
static

Definition at line 157 of file px_uploader.py.

string px_uploader.uploader.CHIP_VERIFY = b'\x24'
static

Definition at line 158 of file px_uploader.py.

string px_uploader.uploader.EOC = b'\x20'
static

Definition at line 145 of file px_uploader.py.

string px_uploader.uploader.FAILED = b'\x11'
static

Definition at line 149 of file px_uploader.py.

px_uploader.uploader.fw_maxsize

Definition at line 444 of file px_uploader.py.

string px_uploader.uploader.GET_CHIP = b'\x2c'
static

Definition at line 164 of file px_uploader.py.

string px_uploader.uploader.GET_CHIP_DES = b'\x2e'
static

Definition at line 166 of file px_uploader.py.

string px_uploader.uploader.GET_CRC = b'\x29'
static

Definition at line 161 of file px_uploader.py.

string px_uploader.uploader.GET_DEVICE = b'\x22'
static

Definition at line 156 of file px_uploader.py.

string px_uploader.uploader.GET_OTP = b'\x2a'
static

Definition at line 162 of file px_uploader.py.

string px_uploader.uploader.GET_SN = b'\x2b'
static

Definition at line 163 of file px_uploader.py.

string px_uploader.uploader.GET_SYNC = b'\x21'
static

Definition at line 155 of file px_uploader.py.

string px_uploader.uploader.INFO_BL_REV = b'\x01'
static

Definition at line 171 of file px_uploader.py.

string px_uploader.uploader.INFO_BOARD_ID = b'\x02'
static

Definition at line 174 of file px_uploader.py.

string px_uploader.uploader.INFO_BOARD_REV = b'\x03'
static

Definition at line 175 of file px_uploader.py.

string px_uploader.uploader.INFO_FLASH_SIZE = b'\x04'
static

Definition at line 176 of file px_uploader.py.

string px_uploader.uploader.INSYNC = b'\x12'
static

Definition at line 144 of file px_uploader.py.

string px_uploader.uploader.INVALID = b'\x13'
static

Definition at line 150 of file px_uploader.py.

tuple px_uploader.uploader.MAVLINK_REBOOT_ID0 = bytearray(b'\xfe\x21\x45\xff\x00\x4c\x00\x00\x80\x3f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\xf6\x00\x00\x00\x00\xd7\xac')
static

Definition at line 185 of file px_uploader.py.

tuple px_uploader.uploader.MAVLINK_REBOOT_ID1 = bytearray(b'\xfe\x21\x72\xff\x00\x4c\x00\x00\x80\x3f\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\xf6\x00\x01\x00\x00\x48\xf0')
static

Definition at line 184 of file px_uploader.py.

int px_uploader.uploader.MAX_DES_LENGTH = 20
static

Definition at line 167 of file px_uploader.py.

string px_uploader.uploader.NOP = b'\x00'
static

Definition at line 154 of file px_uploader.py.

tuple px_uploader.uploader.NSH_INIT = bytearray(b'\x0d\x0d\x0d')
static

Definition at line 181 of file px_uploader.py.

string px_uploader.uploader.NSH_REBOOT = b"reboot\n"
static

Definition at line 183 of file px_uploader.py.

string px_uploader.uploader.NSH_REBOOT_BL = b"reboot -b\n"
static

Definition at line 182 of file px_uploader.py.

string px_uploader.uploader.OK = b'\x10'
static

Definition at line 148 of file px_uploader.py.

px_uploader.uploader.otp

Definition at line 190 of file px_uploader.py.

px_uploader.uploader.otp_coa

Definition at line 471 of file px_uploader.py.

px_uploader.uploader.otp_id

Definition at line 467 of file px_uploader.py.

px_uploader.uploader.otp_idtype

Definition at line 468 of file px_uploader.py.

px_uploader.uploader.otp_pid

Definition at line 470 of file px_uploader.py.

px_uploader.uploader.otp_vid

Definition at line 469 of file px_uploader.py.

px_uploader.uploader.port

Definition at line 189 of file px_uploader.py.

string px_uploader.uploader.PROG_MULTI = b'\x27'
static

Definition at line 159 of file px_uploader.py.

int px_uploader.uploader.PROG_MULTI_MAX = 252
static

Definition at line 178 of file px_uploader.py.

string px_uploader.uploader.READ_MULTI = b'\x28'
static

Definition at line 160 of file px_uploader.py.

int px_uploader.uploader.READ_MULTI_MAX = 252
static

Definition at line 179 of file px_uploader.py.

string px_uploader.uploader.REBOOT = b'\x30'
static

Definition at line 169 of file px_uploader.py.

string px_uploader.uploader.SET_BOOT_DELAY = b'\x2d'
static

Definition at line 165 of file px_uploader.py.

px_uploader.uploader.sn

Definition at line 191 of file px_uploader.py.


The documentation for this class was generated from the following file: