7 #define MAX_CMD_LIST_LENGTH 50 319 int createPCB(
const char* pcbName,
const char* pcbPriority,
const char* pcbClass);
451 #endif // COMM_LIST_H void helpMCBFreeMem()
Prints the details for freeing an mcb.
int showReadyProcesses(char parameters[][MAX_LENGTH])
showReadyProcesses shows all processes that are ready, in the ready queue (linked list)...
int time(char parameters[][MAX_LENGTH])
void helpSetPriority()
helpSetPriority prints out to console the parameters and usage for –setpriority. ...
int pcbFunc(char parameters[][MAX_LENGTH])
takes in parameters and makes sure its valid then runs what you want to.
cmd_struct_t cmdArray[MAX_CMD_LIST_LENGTH]
int setPriority(char *procName, char *procPrio)
setPriority sets the priority of a particular process
void helpBlockPCB()
helpBlockPCB prints out the parameters and usage for blocking a PCB.
void helpSuspendPCB()
helpSuspendPCB prints the help instructions for the suspendPCB command.
void helpShutdown()
helpShutdown prints the help instructions for set date. Tells the user what the command and arguments...
void helpTime(char parameters[][MAX_LENGTH])
helpTime prints out the help information for time, for time –set and time –get
void helpMCBInitHeap()
prints the all details about the initheap func
int getNumDaysInMonth(int month, int year)
getNumDaysInMonth is a helper function to allow the easy retrieval of days in a month based on the mo...
void helpCreatePCB()
helpCreatePCB prints out the parameters and usage for createPCB.
void setDate(char parameters[][MAX_LENGTH])
setDate sets the system date using the input from the user.
void getDate()
getDate Get the current date from the system.
int helpGetVersion()
helpGetVersion prints the help instructions for version. Tells the user what the command and argument...
int createPCB(const char *pcbName, const char *pcbPriority, const char *pcbClass)
createPCB creates a new PCB and allocates memory for the PCB.
void helpGetTime()
helpGetTime prints the help instructions for get time. Tells the user what the commands and arguments...
void help()
help prints out a list of all possible commands and a brief description of what they do...
int blockPCB(char parameters[][MAX_LENGTH])
blockPCB blocks the specified PCB
void helpSetDate()
helpSetDate prints the help instructions for set date. Tells the user what the command and arguments ...
int resumePCB(char parameters[][MAX_LENGTH])
resumePCB resumes the PCB passed in by the user
void helpVersion()
helpVersion prints the help instructions for using the version command. No arguments are required...
void helpMCBShowAllocated()
Prints details for showing all the allocated memory blocks in the heap.
void helpPcb(char parameters[][MAX_LENGTH])
helpPcb takes in the command to print the help information for. Calls the proper function to print th...
#define MAX_CMD_LIST_LENGTH
int yield()
stops the exection of commhand and executes each process in the ready queue
void helpDeletePCB()
helpDeletePCB prints out the parameters and usage for deleting a PCB.
void helpResumePCB()
helpResumePCB prints out the parameters and usage of the resume pcb command.
int loadr3(char parameters[][MAX_LENGTH])
loads all processes into memory in a suspended ready state at any priority of the users choosing ...
void helpSetTime()
helpSetTime prints the help instructions for set time. Tells the user what the command and arguments ...
void helpShowAllProcesses()
helpShowAllProcesses shows all processes in the system. Takes in no parameters and prints out to the ...
int mcbFunc(char parameters[][MAX_LENGTH])
takes in whatever you are looking for and checks to see if it can be done for mcb ...
int deletePCB(char parameters[][MAX_LENGTH])
deletePCB deletes the PCB requested by the user.
int suspendPCB(char parameters[][MAX_LENGTH])
suspendPCB suspends the pcb passed in by the user
int unblockPCB(char parameters[][MAX_LENGTH])
unblockPCB unblocks the specified PCB.
void helpMCB(char parameters[][MAX_LENGTH])
The command handler for mcb's checking for valid input.
int version(char parameters[][MAX_LENGTH])
version prints out the current version of the operating system. It will print out R1...
void helpLoadR3()
helpLoadR3 prints out the help commands for helpLoadR3 Loads all of the processes from procsr3 ...
void helpGetDate()
helpGetDate prints the help instructions for get date. Tells the user what the command and arguments ...
void helpMCBAllocate()
Prints the details for Allocating an mcb.
void helpMCBIsEmpty()
Prints details for IsEmpty func.
int(* cmdFunc)(char[][MAX_LENGTH])
int date(char parameters[][MAX_LENGTH])
void helpPcbPrint()
helpPcbPrint prints out the commands for PCBs.
int shutdownFunc(char parameters[][MAX_LENGTH])
shutdownFunc shuts down the OS.
void helpShowReadyProcesses()
helpShowReadyProcesses shows the parameters and usage for showing ready PCBs.
void helpShowBlockedProcesses()
helpShowBlockedProcesses shows the parameters and usage for showing the blocked PCBs.
int isEmpty(char parameters[][MAX_LENGTH])
void helpMCBShowFree()
Prints details for showing all the free memory blocks in the heap.
int showAllProcesses(char parameters[][MAX_LENGTH])
showAllProcesses shows all processes in the system.
int helpFunc(char parameters[][MAX_LENGTH])
helpFunc calls the other help functions
void helpMcbPrint()
Prints the help menu for all mcb functions.
void helpUnblockPCB()
helpUnblockPCB prints out the parameters and usage for unblocking a PCB.
void getTime()
getTime this function has the side-effect of printing the current time to the terminal.
int showBlockedProcesses(char parameters[][MAX_LENGTH])
showBlockedProcesses shows all processes that are blocked.
int showPCB(char parameters[][MAX_LENGTH])
showPCB shows the process information for the process requested by the user
void setTime(char parameters[][MAX_LENGTH])
setTime sets the current system time from the users input.
void helpDate(char parameters[][MAX_LENGTH])
helpDate prints out the help information for date, for date –set and date –get