Deprecated: Return type of WP_Theme::offsetExists($offset) should either be compatible with ArrayAccess::offsetExists(mixed $offset): bool, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home1/smartva9/public_html/smartvania/wp-includes/class-wp-theme.php on line 554

Deprecated: Return type of WP_Theme::offsetGet($offset) should either be compatible with ArrayAccess::offsetGet(mixed $offset): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home1/smartva9/public_html/smartvania/wp-includes/class-wp-theme.php on line 595

Deprecated: Return type of WP_Theme::offsetSet($offset, $value) should either be compatible with ArrayAccess::offsetSet(mixed $offset, mixed $value): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home1/smartva9/public_html/smartvania/wp-includes/class-wp-theme.php on line 535

Deprecated: Return type of WP_Theme::offsetUnset($offset) should either be compatible with ArrayAccess::offsetUnset(mixed $offset): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home1/smartva9/public_html/smartvania/wp-includes/class-wp-theme.php on line 544

Deprecated: Return type of WP_REST_Request::offsetExists($offset) should either be compatible with ArrayAccess::offsetExists(mixed $offset): bool, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home1/smartva9/public_html/smartvania/wp-includes/rest-api/class-wp-rest-request.php on line 952

Deprecated: Return type of WP_REST_Request::offsetGet($offset) should either be compatible with ArrayAccess::offsetGet(mixed $offset): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home1/smartva9/public_html/smartvania/wp-includes/rest-api/class-wp-rest-request.php on line 972

Deprecated: Return type of WP_REST_Request::offsetSet($offset, $value) should either be compatible with ArrayAccess::offsetSet(mixed $offset, mixed $value): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home1/smartva9/public_html/smartvania/wp-includes/rest-api/class-wp-rest-request.php on line 984

Deprecated: Return type of WP_REST_Request::offsetUnset($offset) should either be compatible with ArrayAccess::offsetUnset(mixed $offset): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home1/smartva9/public_html/smartvania/wp-includes/rest-api/class-wp-rest-request.php on line 995

Deprecated: Return type of WP_Block_List::current() should either be compatible with Iterator::current(): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home1/smartva9/public_html/smartvania/wp-includes/class-wp-block-list.php on line 151

Deprecated: Return type of WP_Block_List::next() should either be compatible with Iterator::next(): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home1/smartva9/public_html/smartvania/wp-includes/class-wp-block-list.php on line 175

Deprecated: Return type of WP_Block_List::key() should either be compatible with Iterator::key(): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home1/smartva9/public_html/smartvania/wp-includes/class-wp-block-list.php on line 164

Deprecated: Return type of WP_Block_List::valid() should either be compatible with Iterator::valid(): bool, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home1/smartva9/public_html/smartvania/wp-includes/class-wp-block-list.php on line 186

Deprecated: Return type of WP_Block_List::rewind() should either be compatible with Iterator::rewind(): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home1/smartva9/public_html/smartvania/wp-includes/class-wp-block-list.php on line 138

Deprecated: Return type of WP_Block_List::offsetExists($index) should either be compatible with ArrayAccess::offsetExists(mixed $offset): bool, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home1/smartva9/public_html/smartvania/wp-includes/class-wp-block-list.php on line 75

Deprecated: Return type of WP_Block_List::offsetGet($index) should either be compatible with ArrayAccess::offsetGet(mixed $offset): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home1/smartva9/public_html/smartvania/wp-includes/class-wp-block-list.php on line 89

Deprecated: Return type of WP_Block_List::offsetSet($index, $value) should either be compatible with ArrayAccess::offsetSet(mixed $offset, mixed $value): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home1/smartva9/public_html/smartvania/wp-includes/class-wp-block-list.php on line 110

Deprecated: Return type of WP_Block_List::offsetUnset($index) should either be compatible with ArrayAccess::offsetUnset(mixed $offset): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home1/smartva9/public_html/smartvania/wp-includes/class-wp-block-list.php on line 127

Deprecated: Return type of WP_Block_List::count() should either be compatible with Countable::count(): int, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home1/smartva9/public_html/smartvania/wp-includes/class-wp-block-list.php on line 199

Deprecated: Return type of Requests_Cookie_Jar::offsetExists($key) should either be compatible with ArrayAccess::offsetExists(mixed $offset): bool, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home1/smartva9/public_html/smartvania/wp-includes/Requests/Cookie/Jar.php on line 63

Deprecated: Return type of Requests_Cookie_Jar::offsetGet($key) should either be compatible with ArrayAccess::offsetGet(mixed $offset): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home1/smartva9/public_html/smartvania/wp-includes/Requests/Cookie/Jar.php on line 73

Deprecated: Return type of Requests_Cookie_Jar::offsetSet($key, $value) should either be compatible with ArrayAccess::offsetSet(mixed $offset, mixed $value): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home1/smartva9/public_html/smartvania/wp-includes/Requests/Cookie/Jar.php on line 89

Deprecated: Return type of Requests_Cookie_Jar::offsetUnset($key) should either be compatible with ArrayAccess::offsetUnset(mixed $offset): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home1/smartva9/public_html/smartvania/wp-includes/Requests/Cookie/Jar.php on line 102

Deprecated: Return type of Requests_Cookie_Jar::getIterator() should either be compatible with IteratorAggregate::getIterator(): Traversable, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home1/smartva9/public_html/smartvania/wp-includes/Requests/Cookie/Jar.php on line 111

Deprecated: Return type of Requests_Utility_CaseInsensitiveDictionary::offsetExists($key) should either be compatible with ArrayAccess::offsetExists(mixed $offset): bool, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home1/smartva9/public_html/smartvania/wp-includes/Requests/Utility/CaseInsensitiveDictionary.php on line 40

Deprecated: Return type of Requests_Utility_CaseInsensitiveDictionary::offsetGet($key) should either be compatible with ArrayAccess::offsetGet(mixed $offset): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home1/smartva9/public_html/smartvania/wp-includes/Requests/Utility/CaseInsensitiveDictionary.php on line 51

Deprecated: Return type of Requests_Utility_CaseInsensitiveDictionary::offsetSet($key, $value) should either be compatible with ArrayAccess::offsetSet(mixed $offset, mixed $value): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home1/smartva9/public_html/smartvania/wp-includes/Requests/Utility/CaseInsensitiveDictionary.php on line 68

Deprecated: Return type of Requests_Utility_CaseInsensitiveDictionary::offsetUnset($key) should either be compatible with ArrayAccess::offsetUnset(mixed $offset): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home1/smartva9/public_html/smartvania/wp-includes/Requests/Utility/CaseInsensitiveDictionary.php on line 82

Deprecated: Return type of Requests_Utility_CaseInsensitiveDictionary::getIterator() should either be compatible with IteratorAggregate::getIterator(): Traversable, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /home1/smartva9/public_html/smartvania/wp-includes/Requests/Utility/CaseInsensitiveDictionary.php on line 91

Deprecated: trim(): Passing null to parameter #1 ($string) of type string is deprecated in /home1/smartva9/public_html/smartvania/wp-includes/class-wp.php on line 173

Warning: Cannot modify header information - headers already sent by (output started at /home1/smartva9/public_html/smartvania/wp-includes/class-wp-theme.php:9) in /home1/smartva9/public_html/smartvania/wp-includes/rest-api/class-wp-rest-server.php on line 1637

Warning: Cannot modify header information - headers already sent by (output started at /home1/smartva9/public_html/smartvania/wp-includes/class-wp-theme.php:9) in /home1/smartva9/public_html/smartvania/wp-includes/rest-api/class-wp-rest-server.php on line 1637

Warning: Cannot modify header information - headers already sent by (output started at /home1/smartva9/public_html/smartvania/wp-includes/class-wp-theme.php:9) in /home1/smartva9/public_html/smartvania/wp-includes/rest-api/class-wp-rest-server.php on line 1637

Warning: Cannot modify header information - headers already sent by (output started at /home1/smartva9/public_html/smartvania/wp-includes/class-wp-theme.php:9) in /home1/smartva9/public_html/smartvania/wp-includes/rest-api/class-wp-rest-server.php on line 1637

Warning: Cannot modify header information - headers already sent by (output started at /home1/smartva9/public_html/smartvania/wp-includes/class-wp-theme.php:9) in /home1/smartva9/public_html/smartvania/wp-includes/rest-api/class-wp-rest-server.php on line 1637

Warning: Cannot modify header information - headers already sent by (output started at /home1/smartva9/public_html/smartvania/wp-includes/class-wp-theme.php:9) in /home1/smartva9/public_html/smartvania/wp-includes/rest-api/class-wp-rest-server.php on line 1637

Deprecated: ltrim(): Passing null to parameter #1 ($string) of type string is deprecated in /home1/smartva9/public_html/smartvania/wp-includes/wp-db.php on line 3031

Warning: Cannot modify header information - headers already sent by (output started at /home1/smartva9/public_html/smartvania/wp-includes/class-wp-theme.php:9) in /home1/smartva9/public_html/smartvania/wp-includes/rest-api/class-wp-rest-server.php on line 1637

Warning: Cannot modify header information - headers already sent by (output started at /home1/smartva9/public_html/smartvania/wp-includes/class-wp-theme.php:9) in /home1/smartva9/public_html/smartvania/wp-includes/rest-api/class-wp-rest-server.php on line 1637
{"id":1513,"date":"2017-01-23T04:04:01","date_gmt":"2017-01-23T04:04:01","guid":{"rendered":"http:\/\/smartvania.com\/?p=1513"},"modified":"2017-01-23T04:06:46","modified_gmt":"2017-01-23T04:06:46","slug":"mips-questions","status":"publish","type":"post","link":"https:\/\/smartvania.com\/mips-questions\/","title":{"rendered":"MIPS questions"},"content":{"rendered":"

\nHi Amell,<\/p>\n

I just watched the entire series of MIPS tutorial that you have uploaded on your YT channel. First of all, thanks for that! It was awesome \ud83d\ude42<\/p>\n

Secondly, I have a few questions. As I am completely new to MIPS, I have received some tasks to do (from school) and do not know how they should be configured. Do you mind looking over them and give me some hints?<\/p>\n

For analyze.asm:
\nChange the program so that only every third character is printed. The program must still stop after “Z”.<\/p>\n

For hexmain.asm:
\nYou will now write a small subroutine, that converts numbers in the range 0 through 15 into a printable ASCII-coded character: ‘0’ through ‘9’, or ‘A’ through ‘F’, depending on the number. For numbers not in the range 0 through 15, some bits will be ignored. In file hexmain.asm, add an assembly-language subroutine with the following specification. Name: The subroutine must be called hexasc. Parameter: One, in register $a0. The 4 least significant bits specify a number, from 0 through 15. All other bits in register $a0 can have any value and must be ignored. Return value: The 7 least significant bits in register $v0 must be an ASCII code as described below. All other bits must be zero when your function returns. Required action: The function must convert input values 0 through 9 into the ASCII codes for digits ‘0’ through ‘9’, respectively. Input values 10 through 15 must be converted to the ASCII codes for letters ‘A’ through ‘F’, respectively. <\/p>\n

Thanks in advance!<\/p>\n

Best regards,
\nA.
\n01\/3\/17\n<\/p><\/blockquote>\n

# hexmain.asm<\/p>\n

# Written
\n2015-09-04
\n by F Lundevall<\/p>\n

# Copyright abandonded
\n– this file is
\nin the public domain.<\/p>\n

.text<\/p>\n

main:<\/p>\n

li
\n$a0,3
\n # change this to test different values<\/p>\n

jal hexasc #
\ncall hexasc<\/p>\n

nop # delay
\n slot filler (just in case)<\/p>\n

move
\n$a0,$v0
\n # copy return value to argument register<\/p>\n

li
\n$v0,11
\n # syscall with v0 =
\n11 will print
\nout<\/p>\n

syscall # one
\n byte from a0 to the Run I\/O window<\/p>\n

stop: j stop # stop after one run<\/p>\n

nop # delay
\n slot filler (just in case)<\/p>\n

# You can write your own code for hexasc here<\/p>\n

#<\/p>\n

hexasc:<\/p>\n

andi
\n$a0,
\n$a0,
\n0xF # remove all bits except the
\n4 lsb.<\/p>\n

addi
\n$v0,
\n$0,
\n0x30<\/p>\n

addi
\n$t0,
\n$0,
\n0x9<\/p>\n

ble
\n$a0,
\n$t0,
\n converter<\/p>\n

nop<\/p>\n

addi
\n$v0,
\n$v0,
\n0x7<\/p>\n

converter:<\/p>\n

add
\n$v0,
\n$a0,
\n$v0<\/p>\n

jr
\n$ra<\/p>\n

nop<\/p>\n

-Amell<\/p>\n","protected":false},"excerpt":{"rendered":"

Hi Amell, I just watched the entire series of MIPS tutorial that you have uploaded on your YT channel. First of all, thanks for that! It was awesome \ud83d\ude42 Secondly, I have a few questions. As I am completely new to MIPS, I have received some tasks to do (from school) and do not know […]<\/p>\n","protected":false},"author":1,"featured_media":1098,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[26],"tags":[],"jetpack_featured_media_url":"https:\/\/smartvania.com\/wp-content\/uploads\/2016\/03\/LTSK-copy.png","_links":{"self":[{"href":"https:\/\/smartvania.com\/wp-json\/wp\/v2\/posts\/1513"}],"collection":[{"href":"https:\/\/smartvania.com\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/smartvania.com\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/smartvania.com\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/smartvania.com\/wp-json\/wp\/v2\/comments?post=1513"}],"version-history":[{"count":2,"href":"https:\/\/smartvania.com\/wp-json\/wp\/v2\/posts\/1513\/revisions"}],"predecessor-version":[{"id":1515,"href":"https:\/\/smartvania.com\/wp-json\/wp\/v2\/posts\/1513\/revisions\/1515"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/smartvania.com\/wp-json\/wp\/v2\/media\/1098"}],"wp:attachment":[{"href":"https:\/\/smartvania.com\/wp-json\/wp\/v2\/media?parent=1513"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/smartvania.com\/wp-json\/wp\/v2\/categories?post=1513"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/smartvania.com\/wp-json\/wp\/v2\/tags?post=1513"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}