Welcome to Dream.In.Code
Getting Help is Easy!

Join 86,263 Programmers. There are 1,902 online right now! Ask your question and get quick answers from Dream.In.Code experts. Join the #1 programming help community on the internet! Registration is fast and FREE... Join Now!

Chat LIVE With a Expert
Powered by LivePerson.com

Register to Make This Box Go Away!

ASSEMBLY LC-3

 
Reply to this topicStart new topic

ASSEMBLY LC-3, NEW TRAP SERVICE ROUTINE

blurr_001
post 29 Apr, 2008 - 07:07 AM
Post #1


New D.I.C Head

*
Joined: 14 Mar, 2008
Posts: 9



i need help doing this i am slightly confused as to how to do this....Please help

Assembly language programming: input and output. The TRAP service routines GETC and IN each collect only a single character of input at a time. However, the TRAP service routines OUT and PUTS, generate one or a string characters of output, respectively. Write an LC-3 assembly language program that collects many characters of input at a time. In other words, write a service routine (GETS) that gets a string of characters from the keyboard, stores the string in a contiguous block of memory, and loads R0 with the memory address of the beginning of the string. The end of the character string is indicated by a newline character, which is generated when the user presses the ENTER key on the keyboard. Your program should not use any TRAP service routines other than HALT. Update the trap vector table to define trapvector x26, and make a home for your GETS subroutine a memory location x0600. Finally, write a program that uses TRAP x26 to make sure it works.
User is offlineProfile CardPM
Go to the top of the page
+Quote Post


Fast ReplyReply to this topicStart new topic
Time is now: 5/16/08 10:22AM

Live Help!

Tutorials

Programming

Web Development

Reference Sheets

Code Snippets

Bye Bye Ads

Free DIC T-Shirt

T-Shirt Example

Related Sites

Monthly Drawing

Thumb Drive

Partners

Top Contributors

Top 10 Kudos This Month