# converted to .tcl by html2tcl.tcl set buffer "" append buffer { OpenOCD debugger } set console "" set upload_filename /ram/upload append buffer {
OpenOCD
} append buffer [capture version] append buffer {
 
} set toggle_details [formfetch toggle_details] if {[string length $toggle_details]==0} { set toggle_details 0 } set show_details [load_var show_details] if {[string length $show_details]==0} { set show_details 0 } if {$toggle_details==1} { set show_details [expr 1-$show_details] save_var show_details $show_details } if {[string length $console]!=0} { append buffer { } } append buffer {
 

Program / Verify Flash

} set form_offset [formfetch form_offset] set form_action [formfetch form_action] set form_type [formfetch form_type] set post "" catch {set post $post_data} err if {[string compare $form_offset ""]==0} { set form_offset 0 } if {[string compare $form_type ""]==0} { set form_type "" } append buffer {} set data "" append buffer {
} set action_reset [expr {[string length $form_action]!=0}] set action_flash [expr {[string compare $form_action "Flash"]==0 || [string compare $form_action "Flash and verify"]==0}] set action_verify [expr {[string compare $form_action "Verify"]==0 || [string compare $form_action "Flash and verify"]==0}] if {$action_reset} { append console [encode [capture_catch "reset init"]] } append buffer { } append buffer {} append buffer {} append buffer "" append buffer {
File
Offset
Type
 
 

} if {$action_flash||$action_verify} { catch {writeform form_filecontent $upload_filename} result append console [encode $result] } append buffer "
" if {$action_flash} { append console [encode [capture_catch "halt"]] append buffer "" if {[catch {capture_catch {eval "flash write_image erase $upload_filename $form_offset $form_type"}} result]} { append buffer "Flash write failed
" append console [encode $result] } else { append buffer [encode $result] append buffer "Flash write succeed
" } append buffer "
" } if {$action_verify} { append console [encode [capture_catch "halt"]] append buffer "" if {[catch {capture_catch {eval "verify_image $upload_filename $form_offset $form_type"}} result]} { append buffer "Verify failed
" append console [encode $result] } else { append buffer [encode $result] append buffer "Verify succeed
" } append buffer "
" } append buffer {

} if {$show_details==1} { append buffer < append buffer {td style="background-color:#dddddd;padding-left:5px;padding-right:5px;padding-top:3px;padding-bottom:3px;"} append buffer > } else { append buffer < append buffer {td style="background-image:url('menu_cuts/h_tab_free.png');width:110px;height:29px;background-repeat: no-repeat;background-position:top left;"} append buffer > } append buffer { } if {$show_details==1} { append buffer "Hide details" append buffer
} else { append buffer {
} append buffer "Show details" append buffer {
} } append buffer {
} if {$show_details==1} { append buffer $console } append buffer {} if {$show_details!=1} { append buffer {} } append buffer {
   
 
Documentation
 
OpenOCD Manual

Program and/or verify the flash on your target.

Flash - Halt CPU, automatically erase flash if required and program flash with image.

Flash and verify - Programs the flash and verifies the programmed flash content is correct.

Verify - Halt CPU and verify image in flash or RAM.

Offset - This value is added to the address of the image.
Binary images start at address 0 by default, whereas elf and ihex have addresses encoded into the image.
Typically 0 for elf/ihex and the address to write the image to for binary files.

 
} start_chunked "html" write_chunked $buffer end_chunked