manual:chapter6:usb:cmd_usbstatus


Synopsis


Get status of the USB driver

Stack Diagram


Input Stack Output Stack
#status
Level 1 Level 1

Legend

Type Command
Parallel list processing Group 1
Affected by flags None

Description


The USBSTATUS command returns the current status of the USB driver. Information is encoded in a byte as follows:

Bit Value Meaning
0 Clear USB cable is connected.
Set USB cable is disconnected.
1 Clear USB driver has not completed its configuration.
Set USB driver has completed its configuration.
2 Clear USB data is not incoming.
Set USB data is incoming.

Compatibility


This command is new in newRPL and does not exist in userRPL.

Usage


The following program

« DO
  UNTIL
    USBSTATUS #3h ==
  END
  "OK"
»

will result in the calculator waiting in a loop for a connection to the PC to be estabilished and

1:                          "OK"
……………………………………………………………………………………

once the connection is done.

Related Commands


USB Communications 8 NEW

Command Short Description
USBSTATUS Get status of the USB driver NEW
USBRECV Receive an object through USB link NEW
USBSEND Send an object through the USB link NEW
USBOFF Disable USB port NEW
USBON Enable USB port NEW
USBAUTORCV Receive an object and execute it NEW
USBARCHIVE Create a backup on a remote machine NEW
USBRESTORE Restore a backup from a remote machine NEW
  • manual/chapter6/usb/cmd_usbstatus.txt
  • Last modified: 2019/11/01 14:17
  • by jojo1973