Mips count characters in string

Click For Summary
The discussion focuses on how to count characters in a string using MIPS assembly language and display the count in hexadecimal format. Participants emphasize the importance of understanding string termination, character access, and integer storage in memory. They encourage the user to explore MIPS programming examples available online for guidance. While direct assistance in writing the program is not provided, feedback on user-submitted code is welcomed. Overall, the thread serves as a resource for learning MIPS string manipulation and hexadecimal representation.
keo
Messages
1
Reaction score
0
Summary:: Count characterers in a string and display it in hexadecimal

[New user has been reminded to show their work on schoolwork problems]

Hi, how can I do this in MIPS?
Given a string of characters, the program has to count the number of characters in the string, and display it in hexadecimal.
Thank you!
 
Last edited by a moderator:
Physics news on Phys.org
1) Do you know how to count In MIPS?

2) Do you know how to look at each character in a string?

3) Do you know what character marks the end of a string?

4) Do you know about integers and how they are stored in memory?

5) If you look at a stored integer 4-bits at a time you can map it to a hex character.

To help here's a bunch of MIPS programming examples and there are many sites online with further examples. From them, you might methods of counting, accessing string characters, and displaying hex values.

Sadly, though we can't help you write your program, we can critique if you give a version and tell us why it's not working.

https://courses.cs.washington.edu/courses/cse378/03wi/lectures/mips-asm-examples.html
 
Last edited:
Thread 'How do I determine the resistance for RLC low pass filter?'
Hi, I am trying to build a RLC low pass filter that atenuates the frequency below 4500 Hz. However, I have encountered some problem when choosing the correct R to work with. Here is the Circuit Here is the original sound. Here is my code in Matlab function Vout = myFilterCircuit(Vin,h) n_V = length(Vin); f_7 = 4470;; % Undesired frequency h_7 = h; % delta time % These are for the constant and initialization of the variables t_7 = 0:h_7:(n_V-1)*h_7; % This is the independent variable...
Greetings to all, I am writing with a question regarding graph generation in LTSpice. I am using LTSpice XVII and am trying to plot AM-AM and AM-PM characterization for a power amplifier, but I haven't been successful yet, likely due to my lack of practice with this specific analysis. I have been using a square wave input at 8.2 MHz as the voltage waveform for my power amplifier. It is said that for a switching amplifier like Class-D, the AM-AM / AM-PM (amplitude-to-amplitude and...

Similar threads

Replies
10
Views
2K
Replies
12
Views
2K
Replies
2
Views
2K
Replies
7
Views
3K
Replies
24
Views
3K
Replies
2
Views
3K