Difference between revisions of "83Plus:Software:usb8x/Error Codes"
From WikiTI
m (errMSDFailedCmd added) |
(Added hexadecimal values to the list, because I'm tired of having to translate them all the time. Who uses decimal, anyway? ;)) |
||
(5 intermediate revisions by 3 users not shown) | |||
Line 1: | Line 1: | ||
− | Error codes may be returned via both the [[ | + | Error codes may be returned via both the [[83Plus:Software:usb8x/Asm_Interface|assembly language interface]] and the [[83Plus:Software:usb8x/BASIC_Interface|BASIC interface]]. In the BASIC interface, the error code is returned in the first element of the return list. In the assembly language interface, an error is generally indicated by a return with the carry flag set. The error code can then be read via [[83Plus:Software:usb8x/Asm_Interface/GetErrorCode|GetErrorCode]]. Error code equates are located in [http://usb8x.cvs.sourceforge.net/*checkout*/usb8x/usb8x/usb8x.inc usb8x.inc]. |
== Error Codes == | == Error Codes == | ||
{| border="1" cellpadding="2" cellspacing="0" | {| border="1" cellpadding="2" cellspacing="0" | ||
− | !Error # !! Name !! Info | + | !Error # !! Hex !! Name !! Info |
|- | |- | ||
− | |0 || OK || No error | + | |0 || 00h || OK || No error occurred |
|- | |- | ||
− | |1 || Port82 || The previous command failed or did not terminate. This generally happens during initialization. | + | |1 || 01h || Port82 || The previous command failed or did not terminate. This generally happens during initialization. |
|- | |- | ||
− | |2 || Port91Bit2 || An error condition was detected | + | |2 || 02h || Port91Bit2 || An error condition was detected on an input pipe (Stall) |
|- | |- | ||
− | |3 || Port91Bit4 || An error condition was detected | + | |3 || 03h || Port91Bit4 || An error condition was detected on an input pipe (NAK) |
|- | |- | ||
− | |4 || Port4C || Port 4C did not hold the expected value. This generally happens during initialization. | + | |4 || 04h || Port4C || Port 4C did not hold the expected value. This generally happens during initialization. |
|- | |- | ||
− | |5 || Port4D || Port 4D did not hold the expected value. This generally happens during initialization. | + | |5 || 05h || Port4D || Port 4D did not hold the expected value. This generally happens during initialization. |
|- | |- | ||
− | |6 || Port3A || Port 3A did not hold the expected value. This generally happens during initialization. | + | |6 || 06h || Port3A || Port 3A did not hold the expected value. This generally happens during initialization. |
|- | |- | ||
− | |7 || Port81 || Port 81 did not hold the expected value. This generally happens during initialization. | + | |7 || 07h || Port81 || Port 81 did not hold the expected value. This generally happens during initialization. |
|- | |- | ||
− | |8 || Port8C || The frame counter did not start. This often indicates low batteries. | + | |8 || 08h || Port8C || The frame counter did not start. This often indicates low batteries. |
|- | |- | ||
− | |9 || Port8F || Port 8F did not hold the expected value. This generally happens during initialization. | + | |9 || 09h || Port8F || Port 8F did not hold the expected value. This generally happens during initialization. |
|- | |- | ||
− | |10 || EPIndex || A non | + | |10 || 0Ah || EPIndex || A non-existent entry point was called. Be sure to check for the minimum required version of usb8x before calling entry points. |
|- | |- | ||
− | |11 || EPGetDes || An unsupported descriptor was requested from [[ | + | |11 || 0Bh || EPGetDes || An unsupported descriptor was requested from [[83Plus:Software:usb8x/Asm_Interface/ReadDescriptor|ReadDescriptor]]. |
|- | |- | ||
− | |12 || NoDevice || No Device is connected. You'll get this error if you plug in a mini B cable instead of mini A. | + | |12 || 0Ch || NoDevice || No Device is connected. You'll get this error if you plug in a mini-B cable instead of mini-A. |
|- | |- | ||
− | |13 || FindDescriptor || An error | + | |13 || 0Dh || FindDescriptor || An error occurred in [[83Plus:Software:usb8x/Asm_Interface/FindDescriptor|FindDescriptor]]. This error may occasionally improperly be listed a sub error code, because AutoSetup generates a FindDescriptor error during normal operation. |
|- | |- | ||
− | |14 || BadClass || The attached device does not have the required class | + | |14 || 0Eh || BadClass || The attached device does not have the required class (i.e. a keyboard is connected when [[83Plus:Software:usb8x/Asm_Interface/MouseInit|MouseInit]] is called). |
|- | |- | ||
− | |15 || Timeout || A timeout | + | |15 || 0Fh || Timeout || A timeout occurred while waiting for data. This currently is only returned by [[83Plus:Software:usb8x/BASIC_Interface/MouseDo|MouseDo]]. |
|- | |- | ||
− | |16 || BadID || The attached device does not have the required vendor or device ID. | + | |16 || 10h || BadID || The attached device does not have the required vendor or device ID. |
|- | |- | ||
− | |17 || ReadDescriptor || An error | + | |17 || 11h || ReadDescriptor || An error occurred in [[83Plus:Software:usb8x/Asm_Interface/ReadDescriptor|ReadDescriptor]]. Check sub error code for additional information. |
|- | |- | ||
− | |18 || Init || An error | + | |18 || 12h || Init || An error occurred during initialization. Check sub error code for more information. |
|- | |- | ||
− | |19 || AutoSetup || An error | + | |19 || 13h || AutoSetup || An error occurred during [[83Plus:Software:usb8x/Asm_Interface/AutoSetup|AutoSetup]]. Check sub error code for more information. |
|- | |- | ||
− | |20 || Demo || An error | + | |20 || 14h || Demo || An error occurred in demo code. This should not be returned via either of the programming interfaces. |
|- | |- | ||
− | |21 || FindPipe || An error | + | |21 || 15h || FindPipe || An error occurred in [[83Plus:Software:usb8x/Asm_Interface/FindPipe|FindPipe]]. |
|- | |- | ||
− | |22 || Stub || Returned by stub routines (not current used). | + | |22 || 16h || Stub || Returned by stub routines (not current used). |
|- | |- | ||
− | |23 || GetMaxPacketSize || An error | + | |23 || 17h || GetMaxPacketSize || An error occurred while trying to determine the maximum supported packet size. |
|- | |- | ||
− | |24 || SetAddress || An error | + | |24 || 18h || SetAddress || An error occurred while trying to set the device address |
|- | |- | ||
− | |25 || SendCmd || There was a problem sending mass storage I/O commands | + | |25 || 19h || SendCmd || There was a problem sending mass storage I/O commands |
|- | |- | ||
− | |26 || LargeSect || Bytes-per-sector is larger than 512 (not supported) | + | |26 || 1Ah || LargeSect || Bytes-per-sector is larger than 512 (not supported) |
|- | |- | ||
− | |27 || NoParts || There were no FAT16 partitions found on the connected mass storage device | + | |27 || 1Bh || NoParts || There were no FAT16 partitions found on the connected mass storage device |
|- | |- | ||
− | |28 || NoMoreMemory || The previous function failed because there is no more free memory (this is a very bad thing) | + | |28 || 1Ch || NoMoreMemory || The previous function failed because there is no more free memory (this is a very bad thing) |
|- | |- | ||
− | |29 || InvalidPartition || The FAT16 partition found is invalid because it does not contain 0AA55h | + | |29 || 1Dh || InvalidPartition || The FAT16 partition found is invalid because it does not contain 0AA55h |
|- | |- | ||
− | |30 || NotFile || The path passed to a function is to a directory or volume label, not a file | + | |30 || 1Eh || NotFile || The path passed to a function is to a directory or volume label, not a file |
|- | |- | ||
− | |31 || NotValidPath || The path passed to a function is completely invalid | + | |31 || 1Fh || NotValidPath || The path passed to a function is completely invalid |
|- | |- | ||
− | |32 || CorruptFile || A file is corrupted or otherwise not as expected | + | |32 || 20h || CorruptFile || A file is corrupted or otherwise not as expected |
|- | |- | ||
− | |33 || NotFound || File or directory was not found | + | |33 || 21h || NotFound || File or directory was not found |
|- | |- | ||
− | |34 || DuplicateFound || Duplicate calculator variable was found and not overwritten | + | |34 || 22h || DuplicateFound || Duplicate calculator variable was found and not overwritten |
|- | |- | ||
− | |35 || NotEnoughMem || There was not enough memory to create the new calculator variable | + | |35 || 23h || NotEnoughMem || There was not enough memory to create the new calculator variable |
|- | |- | ||
− | |36 || AlreadyExists || An 8x* file of the same name already exists in the current directory | + | |36 || 24h || AlreadyExists || An 8x* file of the same name already exists in the current directory |
|- | |- | ||
− | |37 || StrNotFound || String variable from BASIC OpenLib/ExecLib function was not found | + | |37 || 25h || StrNotFound || String variable from BASIC OpenLib/ExecLib function was not found |
|- | |- | ||
− | |38 || VarEmpty || Variable was empty and transfer was not completed (this is a bad thing; delete new, incomplete file) | + | |38 || 26h || VarEmpty || Variable was empty and transfer was not completed (this is a bad thing; delete new, incomplete file) |
|- | |- | ||
− | |39 || NoParts32 || FAT32 partitions were found, but none were FAT16 (make sure you reformat your drive as FAT16) | + | |39 || 27h || NoParts32 || FAT32 partitions were found, but none were FAT16 (make sure you reformat your drive as FAT16) |
|- | |- | ||
− | |40 || NoData || There was no data to report. Returned by [[ | + | |40 || 28h || NoData || There was no data to report. Returned by [[83Plus:Software:usb8x/BASIC_Interface/KBDGetKey|KBDGetKey]] |
|- | |- | ||
− | |41 || Version || A pre-2.30 version of | + | |41 || 29h || Version || A pre-2.30 version of TI-OS is loaded on the calculator. |
|- | |- | ||
− | |42 || BadCmd || A requested command failed. Returned by Vernier driver. | + | |42 || 2Ah || BadCmd || A requested command failed. Returned by Vernier driver. |
|- | |- | ||
− | |43 || FeatureDisabled || The feature/driver you tried to call is not compiled into the user's binary. | + | |43 || 2Bh || FeatureDisabled || The feature/driver you tried to call is not compiled into the user's binary. |
|- | |- | ||
− | |44 || FailedCmd || Mass storage command sent successfully and failed to execute. This is bad. | + | |44 || 2Ch || FailedCmd || Mass storage command sent successfully and failed to execute. This is bad. |
+ | |- | ||
+ | |45 || 2Dh || CmdTimeout || Mass storage command timed out (no response from device at all) | ||
+ | |- | ||
+ | |46 || 2Eh || CmdRefused || All communication attempts were refused (drive has STALLed) | ||
|} | |} | ||
Be aware that the error codes listed on this page are in decimal, while the error codes displayed in USBInfo are in hexadecimal. | Be aware that the error codes listed on this page are in decimal, while the error codes displayed in USBInfo are in hexadecimal. |
Latest revision as of 19:44, 30 August 2010
Error codes may be returned via both the assembly language interface and the BASIC interface. In the BASIC interface, the error code is returned in the first element of the return list. In the assembly language interface, an error is generally indicated by a return with the carry flag set. The error code can then be read via GetErrorCode. Error code equates are located in usb8x.inc.
Error Codes
Error # | Hex | Name | Info |
---|---|---|---|
0 | 00h | OK | No error occurred |
1 | 01h | Port82 | The previous command failed or did not terminate. This generally happens during initialization. |
2 | 02h | Port91Bit2 | An error condition was detected on an input pipe (Stall) |
3 | 03h | Port91Bit4 | An error condition was detected on an input pipe (NAK) |
4 | 04h | Port4C | Port 4C did not hold the expected value. This generally happens during initialization. |
5 | 05h | Port4D | Port 4D did not hold the expected value. This generally happens during initialization. |
6 | 06h | Port3A | Port 3A did not hold the expected value. This generally happens during initialization. |
7 | 07h | Port81 | Port 81 did not hold the expected value. This generally happens during initialization. |
8 | 08h | Port8C | The frame counter did not start. This often indicates low batteries. |
9 | 09h | Port8F | Port 8F did not hold the expected value. This generally happens during initialization. |
10 | 0Ah | EPIndex | A non-existent entry point was called. Be sure to check for the minimum required version of usb8x before calling entry points. |
11 | 0Bh | EPGetDes | An unsupported descriptor was requested from ReadDescriptor. |
12 | 0Ch | NoDevice | No Device is connected. You'll get this error if you plug in a mini-B cable instead of mini-A. |
13 | 0Dh | FindDescriptor | An error occurred in FindDescriptor. This error may occasionally improperly be listed a sub error code, because AutoSetup generates a FindDescriptor error during normal operation. |
14 | 0Eh | BadClass | The attached device does not have the required class (i.e. a keyboard is connected when MouseInit is called). |
15 | 0Fh | Timeout | A timeout occurred while waiting for data. This currently is only returned by MouseDo. |
16 | 10h | BadID | The attached device does not have the required vendor or device ID. |
17 | 11h | ReadDescriptor | An error occurred in ReadDescriptor. Check sub error code for additional information. |
18 | 12h | Init | An error occurred during initialization. Check sub error code for more information. |
19 | 13h | AutoSetup | An error occurred during AutoSetup. Check sub error code for more information. |
20 | 14h | Demo | An error occurred in demo code. This should not be returned via either of the programming interfaces. |
21 | 15h | FindPipe | An error occurred in FindPipe. |
22 | 16h | Stub | Returned by stub routines (not current used). |
23 | 17h | GetMaxPacketSize | An error occurred while trying to determine the maximum supported packet size. |
24 | 18h | SetAddress | An error occurred while trying to set the device address |
25 | 19h | SendCmd | There was a problem sending mass storage I/O commands |
26 | 1Ah | LargeSect | Bytes-per-sector is larger than 512 (not supported) |
27 | 1Bh | NoParts | There were no FAT16 partitions found on the connected mass storage device |
28 | 1Ch | NoMoreMemory | The previous function failed because there is no more free memory (this is a very bad thing) |
29 | 1Dh | InvalidPartition | The FAT16 partition found is invalid because it does not contain 0AA55h |
30 | 1Eh | NotFile | The path passed to a function is to a directory or volume label, not a file |
31 | 1Fh | NotValidPath | The path passed to a function is completely invalid |
32 | 20h | CorruptFile | A file is corrupted or otherwise not as expected |
33 | 21h | NotFound | File or directory was not found |
34 | 22h | DuplicateFound | Duplicate calculator variable was found and not overwritten |
35 | 23h | NotEnoughMem | There was not enough memory to create the new calculator variable |
36 | 24h | AlreadyExists | An 8x* file of the same name already exists in the current directory |
37 | 25h | StrNotFound | String variable from BASIC OpenLib/ExecLib function was not found |
38 | 26h | VarEmpty | Variable was empty and transfer was not completed (this is a bad thing; delete new, incomplete file) |
39 | 27h | NoParts32 | FAT32 partitions were found, but none were FAT16 (make sure you reformat your drive as FAT16) |
40 | 28h | NoData | There was no data to report. Returned by KBDGetKey |
41 | 29h | Version | A pre-2.30 version of TI-OS is loaded on the calculator. |
42 | 2Ah | BadCmd | A requested command failed. Returned by Vernier driver. |
43 | 2Bh | FeatureDisabled | The feature/driver you tried to call is not compiled into the user's binary. |
44 | 2Ch | FailedCmd | Mass storage command sent successfully and failed to execute. This is bad. |
45 | 2Dh | CmdTimeout | Mass storage command timed out (no response from device at all) |
46 | 2Eh | CmdRefused | All communication attempts were refused (drive has STALLed) |
Be aware that the error codes listed on this page are in decimal, while the error codes displayed in USBInfo are in hexadecimal.