Skip to content

About

Temperature Converter โ€“ COA Project (MIPS Assembly) A MIPS Assembly Language program that converts temperatures between Celsius and Fahrenheit using arithmetic instructions and system calls. Demonstrates low-level programming, floating-point operations, and branching logic in CPU-level architecture. ๐Ÿ’ป Tech Stack: MIPS Assembly, SPIM Simulator

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

ย 

History

4 Commits

Folders and files

NameName
Last commit message
Last commit date
ย 
ย 
ย 
ย 

Repository files navigation

๐ŸŒก๏ธ Temperature Converter in MIPS Assembly

Course: Computer Organization and Architecture (SWE-212L) Semester: 3rdโ€ƒ|โ€ƒBatch: 2023Fโ€ƒ|โ€ƒSection: F University: Sir Syed University of Engineering & Technology (SSUET) Department: Software Engineering


๐Ÿ‘จโ€๐Ÿ’ป Team Members

Name Role
Syed Azan Amir Implementation & Debugging
Muhammad Safwan Testing & Documentation
Shaheer Abbassi Flowchart & Logic Design
Muhammad Tariq Algorithm Design & Report

๐ŸŽฏ Objective

The goal of this project is to create a Temperature Conversion Program in MIPS Assembly Language that converts temperatures between Celsius (ยฐC) and Fahrenheit (ยฐF).

It demonstrates how basic arithmetic, branching, and user input are handled at the assembly level, showcasing the connection between software logic and computer architecture.


โš™๏ธ Problem Statement

Temperature conversion between Celsius and Fahrenheit is a frequent requirement in daily life, science, and engineering. Manual calculations are error-prone, so an automated converter in assembly language provides both accuracy and educational value.


๐Ÿ’ก Solution

This MIPS Assembly program:

  1. Prompts the user to select conversion type:

    • 1 โ†’ Celsius to Fahrenheit
    • 2 โ†’ Fahrenheit to Celsius
  2. Takes a numeric input (temperature value).

  3. Performs the required conversion using formulas below.

  4. Displays the result in the selected scale.

๐Ÿ”น Conversion Formulas

Celsius โ†’ Fahrenheit:  F = (C ร— 9/5) + 32
Fahrenheit โ†’ Celsius:  C = (F โˆ’ 32) ร— 5/9

๐Ÿงฉ Methodology

๐Ÿ”ธ Step 1: User Interaction

Prompt user for conversion type and input value.

๐Ÿ”ธ Step 2: Arithmetic Operation

Perform the correct formula based on user choice using floating-point registers.

๐Ÿ”ธ Step 3: Output

Display result with an appropriate label (ยฐC or ยฐF).


๐Ÿ“Š Flowchart

Screenshot_2025-01-16-07-13-52-04_40deb401b9ffe8e1df2f1cc5ba480b12


๐Ÿงฎ MIPS Code

image image image image

๐Ÿง  Results

image

โœ… Successfully converts between Celsius and Fahrenheit โœ… Accurate results verified with sample inputs โœ… Demonstrates MIPS arithmetic, branching, and system calls โœ… Floating-point calculations handled using FPU


๐Ÿ”ฌ Applications

Field Use Case
Scientific Research Quick temperature conversion in lab experiments
Engineering Conversion for thermal, energy, and material studies
Meteorology Temperature reporting in different scales
Embedded Systems Integration into temperature-sensing microcontrollers
Education Teaching tool for understanding assembly-level arithmetic

๐Ÿ”ฎ Future Enhancements

  • Add Kelvin conversion support
  • Implement error handling for invalid input
  • Include graphical/text-based UI for better user interaction
  • Extend program for embedded temperature sensors

๐Ÿ Conclusion

The Temperature Converter in MIPS Assembly demonstrates how low-level instructions handle arithmetic, I/O, and branching. It bridges the gap between software logic and computer architecture, helping students understand how processors execute even simple programs.

The project successfully fulfills its goal and can be extended for real-time embedded applications in the future.


๐Ÿ“š References

  1. MIPS Assembly Language Programming โ€” Robert L. Britton
  2. MIPS Architecture Reference Manual
  3. Online resources: Stack Overflow, MIPS forums, and educational blogs

๐Ÿงพ License

This project was developed as part of COA Lab (SWE-212L) at Sir Syed University of Engineering & Technology (SSUET). ยฉ 2025 โ€“ Team 2023F-BSE-F. All rights reserved.

About

Temperature Converter โ€“ COA Project (MIPS Assembly) A MIPS Assembly Language program that converts temperatures between Celsius and Fahrenheit using arithmetic instructions and system calls. Demonstrates low-level programming, floating-point operations, and branching logic in CPU-level architecture. ๐Ÿ’ป Tech Stack: MIPS Assembly, SPIM Simulator

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages