Package jmri.jmrix.sprog.update
Class SprogType
java.lang.Object
jmri.jmrix.sprog.update.SprogType
Class to hold SPROG type
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intintstatic final intstatic final intstatic final int -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionintGet the Flash memory block Length for bootloader.static intgetBlockLen(int bootVer) Get the Flash memory block Length for bootloader.doubleReturn the multiplier for scaling the current limit from hardware units to physical units (mA).intbooleanisSprog()Check for any SPROG typebooleanCheck for a SPROG II typeisValidFlashAddress(int addr) Check if an address is one which should be reprogrammed during bootloader operation.toString()toString(int t)
-
Field Details
-
UNKNOWN
- See Also:
-
NO_PROMPT_FOUND
- See Also:
-
NOT_A_SPROG
- See Also:
-
NOT_RECOGNISED
- See Also:
-
TIMEOUT
- See Also:
-
SPROGV4
- See Also:
-
SPROGII
- See Also:
-
SPROGIIUSB
- See Also:
-
SPROGIIv3
- See Also:
-
SPROGIIv4
- See Also:
-
SPROG3
- See Also:
-
SPROGIV
- See Also:
-
SPROG5
- See Also:
-
PISPROGONE
- See Also:
-
NANO
- See Also:
-
PISPROGNANO
- See Also:
-
SNIFFER
- See Also:
-
sprogType
-
-
Constructor Details
-
SprogType
Construct a new SPROG type of a given type.- Parameters:
type- int, one of SprogType.xxx constants
-
-
Method Details
-
isSprog
Check for any SPROG type- Returns:
- true if this object holds a SPROG type
-
isSprogII
Check for a SPROG II type- Returns:
- true if this object holds a SPROG II type
-
getCurrentMultiplier
Return the multiplier for scaling the current limit from hardware units to physical units (mA).- Returns:
- the multiplier for the current limit
-
getBlockLen
Get the Flash memory block Length for bootloader.- Returns:
- blocklen
-
getBlockLen
Get the Flash memory block Length for bootloader.- Parameters:
bootVer- the bootloader version- Returns:
- length in bytes
-
isValidFlashAddress
Check if an address is one which should be reprogrammed during bootloader operation. Checks if address is above the bootloader's address space and below the debug executive's address space.- Parameters:
addr- int- Returns:
- true or false
-
getEraseStart
-
toString
-
toString
- Parameters:
t- Numeric SPROG type- Returns:
- String representation of a SPROG type
-