Lbcontrol

From ElphelWiki
Jump to: navigation, search

Description on russian lbcontrol_Ru

In System Programmer for programm lens control board CPU

Using:

for the 313 camera

 lbcontrol [opts]
   -wf file       write file to flash
   -rf file       read flash and write to file
   -we file       write file to EEPROM
   -re file       read EEPROM and write to file
   -e             erase chip
   -RE addr       read single byte from EEPROM
   -WE addr byte  write single byte to EEPROM
   -rl            read lock bits
   -wl byte       write lock bits (0xFF - not lock programming and reading(by default); 0xFE - programming disable, reading enable; 0xFC - programming disable, reading disable)
   -rc            read calibration byte
   -rs            read signature
   -ruh           read fuse high byte
   -wuh byte      write fuse high byte
   -rul           read fuse low byte
   -wul byte      write fuse low byte
   -h             this help

for the 333 camera

 lbcontrol [opts]
   --debug <num> or -d <num>    set debug level to <num>. <num>=1..5
   --wf file                    write file to flash
   --rf file                    read flash and write to file
   --we file                    write file to EEPROM
   --re file                    read EEPROM and write to file
   --erase or -e                erase chip
   --RE addr                    read single byte from EEPROM
   --WE addr --byte byte        write single byte to EEPROM
   --rl                         read lock bits
   --wl byte                    write lock bits (0xFF - not lock programming and reading(by default); 0xFE - programming disable, reading enable; 0xFC - programming disable, reading disable)
   --rc                         read calibration byte
   --rs                         read signature
   --ruh                        read fuse high byte
   --wuh byte                   write fuse high byte
   --rul                        read fuse low byte
   --wul byte                   write fuse low byte
   --help or -h                 this help


Limitations:

 Support only ATtiny26
 Only page programming mode support
 Not support segment addressing and more then 64K flash programming
 Read flash image only in Intel HEX format
 Read EEPROM image only in binary format, first 128 bytes programmed into EEPROM
 In the flash image support only step-by-step increase address, without hole.

The variable LINEBUF_SIZE describe size of buffer for string reading flash image, size of EEPROM. Default value is 128 bytes.