RTEMS Logo

RTEMS 4.10.2 On-Line Library


RTEMS Specific Commands sema - display information about semaphores

PREV UP NEXT Bookshelf RTEMS Shell User's Guide

5.2.11: sema - display information about semaphores

SYNOPSYS:

sema [id [id ... ] ]

DESCRIPTION:

When invoked with no arguments, this command prints information on the set of Classic API Semaphores currently active in the system.

If invoked with a set of objects ids as arguments, then just those objects are included in the information printed.

EXIT STATUS:

This command returns 0 on success and non-zero if an error is encountered.

NOTES:

NONE

EXAMPLES:

The following is an example of how to use sema:

SHLL [/] $ sema
  ID       NAME   ATTR        PRICEIL CURR_CNT HOLDID
------------------------------------------------------------------------------
1a010001   LBIO   PR:BI:IN      0        1     00000000
1a010002   TRmi   PR:BI:IN      0        1     00000000
1a010003   LBI00  PR:BI:IN      0        1     00000000
1a010004   TRia   PR:BI:IN      0        1     00000000
1a010005   TRoa   PR:BI:IN      0        1     00000000
1a010006   TRxa   <assoc.c: BAD NAME>   0    0 09010001
1a010007   LBI01  PR:BI:IN      0        1     00000000
1a010008   LBI02  PR:BI:IN      0        1     00000000

CONFIGURATION:

This command is included in the default shell command set. When building a custom command set, define CONFIGURE_SHELL_COMMAND_SEMA to have this command included.

This command can be excluded from the shell command set by defining CONFIGURE_SHELL_NO_COMMAND_SEMA when all shell commands have been configured.

PROGRAMMING INFORMATION:

The sema is implemented by a C language function which has the following prototype:

int rtems_shell_rtems_main_sema(
  int    argc,
  char **argv
);

The configuration structure for the sema has the following prototype:

extern rtems_shell_cmd_t rtems_shell_SEMA_Command;


PREV UP NEXT Bookshelf RTEMS Shell User's Guide

Copyright © 1988-2008 OAR Corporation