Documentation for “Zerocat Chipflasher” as of Sun, 24 May 2026 03:24:36 +0200
Repository: git://zerocat.org/zerocat/projects/chipflasher.git
Version: v2.4.0-0-4201e90ae8
Branch: master
Propeller Spin/PASM Compiler 'OpenSpin' (c)2012-2016 Parallax Inc. DBA Parallax Semiconductor.
Version 1.00.78
Compiling...
menu.spin
|-PCB.spin
|-time.spin
|-SPIio.spin
|-SPIclock8.spin
|-SPIflash.spin
|-ASCII.spin
|-blocksizes.spin
|-time.spin
|-ASCII.spin
|-error.spin
|-time.spin
|-connect.spin
|-ASCII.spin
|-linespec.spin
|-blocksizes.spin
|-blocksizes.spin
|-txline.spin
|-ASCII.spin
|-linespec.spin
|-blocksizes.spin
|-FullDuplexSerial.spin
|-ADC.spin
Done.
Program size is 24268 bytes
______________________________________________________________________________
********************************************************* File starts here ***
Zerocat Chipflasher --- Flash free firmware, kick the Management Engine.
Copyright (C) 2020, 2021, 2022, 2024, 2025, 2026 Kai Mertens
File menu.spin --- provide a basic menu
This file is part of Zerocat Chipflasher.
See end of file for terms of use.
******************************************************************************
# Interface Description
Object "menu" Interface:
PUB handshake(baudrate, timeout_sec) :
PUB start(vboard, cfg, baudrate, mode) :
Program: 6063 Longs
Variable: 530 Longs
# Loaded Objects
* PCB
* SPIio
* SPIflash
* time
* ASCII
* error
* connect
* linespec
* blocksizes
* txline
* FullDuplexSerial by Parallax
* Load ADC object to supervise VSPI.
# Constants
## Pins
* LED Pins
* Pins RS232
## Sizes
* Menu Width
* Size of KEYMSG Records
* Size of PROMPT Records
* Blocksize Suspend Trigger during read
* Blocksize Suspend Trigger during write
* Size of stack for RS232 service routine
* Size of stack for rxfile()
* Block Sizes
## Special Characters
* ASCII Characters
* CLIM Characters (Might be changed for debugging purposes.)
* Parallax Terminal Exit Characters
## Bit Definitions
* Status Register Bits, most common, but names vary.
## Modes, Flags, Masks
* FDS Mode
* Line Modes
* SINFO_by_id(), SINFO_by_name() Masks
* Index Mask for doubled buffer size
* Keyreg Initial Value
* Flag Values
## Enumerations
* ENUM REGISTER_type
* ENUM ERRCODE_type
* ENUM JOBCODE_type
* ENUM JOBLEVEL_type
* ENUM VTRACK_type
* ENUM MENU_type
* ENUM REPLY_type
* ENUM KEYID_type
* ENUM BUSPOWER_type
* ENUM BUSY_type
* ENUM SPIPWR_type
* ENUM ADDR_type
* ENUM PAYLOAD_type (Motorola Line Data Mode)
* ENUM RX_type
* ENUM RXHEXD_type
* ENUM RXSREC_type
* ENUM STYPE_type
* ENUM COMMAND_type
* ENUM X_type
* ENUM TXMODE_type
## Timings
* Additional SPI Power Up Pulses
* SPI Power Up/Down Timings (milliseconds)
* SPI WIP Timings (1/10 milliseconds)
* Keypress Timings (milliseconds)
* FDS Stop Timing (milliseconds)
* FDS RX Timing (milliseconds)
# Globals
* Longs for xwrite(), xwrite_AAI() <-> rxfile()
* File and Data transfer
* Global baudrate, set at start
* PCB configuration
* Global chip ID
* RS232 service
* Stack space for rxfile() method
* Job voltages
* Byte buffer linebuf[] -- Holds a full line
* Byte buffer linedat[] -- Holds binary data of a line
* Toggle index for linebuf[]
* Bytes for xwrite(), xwrite_AAI() <-> rxfile()
* Cog ID for rxfile()
* Cog ID for txservice
* PCB version
* Menu configuration
# Functions
________________________________________
PUB handshake(baudrate, timeout_sec) :
Handshake with connect.
__________________________________________
PUB start(vboard, cfg, baudrate, mode) :
Start the menu.
It is stopped by user input: `q'
Load SPI flash page with data:
Many flash chips provide pages of 256 bytes in size to speed up write cycles.
These pages are loaded as fast as possible, sending 32 bits out to SPI at once, if applicable.
The code for this load loop *was buggy for years* :-/
It is now fixed to run as intended, fast and correct.
# Data
* Strings
* Menu Key Messages
* Version String
included from identifier.spin.cfg
******************************************************************************
Terms of Use:
Zerocat Chipflasher is free software: you can redistribute it and/or
modify it under the terms of the GNU General Public License as
published by the Free Software Foundation, either version 3 of the
License, or (at your option) any later version.
Zerocat Chipflasher is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
General Public License for more details.
You should have received a copy of the GNU General Public License along
with Zerocat Chipflasher. If not, see <http://www.gnu.org/licenses/>.
************************************************************** End of File ***