support@w4writers.com +44 7743 307695
Mar 16, 2024

Assignment Task

This assessment continues the work started in practical 9. When answering these questions you must use the assembler and ISE project files from the Exam folder on the VLE.

The bug trap`s functionality and accuracy are to be further improved by the addition of a camera. To implement the required bug detection algorithms a number of new software routines are required. Your task is to implement these functions. Where required new instructions and additional hardware may be added to improve processing performance. However, to ensure compatibility with other systems the following restrictions are imposed:

  • The maximum clock speed used by the system is limited to 10MHz.
  • Instruction names and machine code implementations i.e. bit fields used, are restricted to those defined in Appendix A.
  • The functionality and hardware of existing instructions may not be altered e.g. the rotate left, adder/subtractor and bitwise-logic hardware within the ALU may not be changed.
  • Existing schematic symbols e.g. alu.sch etc, may not be altered. However, you may add additional processing elements to the ALU schematic to enable new functionality, but, you may not alter its ports i.e. its interface. To control this new hardware the control logic : decode.vhd, may also be updated. All other schematics must not be modified.
  • New schematics may not use existing Xilinx library arithmetic components, VHDL components, or IP core generated components.
  • The assembler simpleCPUv1d_as.py may not be modified.
  • Only a single macro file: simpleCPUv1d.m4 may be used.
  • Input images are limited to the file : bug24x24.ppm which can be downloaded from the Exam folder on the VLE.
  • Output images are limited to 24×24 pixels in size and must use the PPM or PGM image formats, as defined in each question

If a solution breaks any of these restrictions you will be awarded a zero mark for the questions affected.

You may implement any of the instructions defined in Appendix A. However, you do not need to do so to complete the programming tasks in questions 1, 2 or 4.

There are five undefined instructions that you may add to your system to improve processing performance:

  • XOP1 (undefined)
  • XOP2 (register indirect)
  • XOP3 (register)
  • XOP4 (register indirect)
  • XOP5 (register)

The assembler has already been updated to support these new instructions and may not be altered. The addressing mode of XOP1 is undefined i.e. it can use any addressing mode that is compatible with the assembler. The addressing modes of instructions XOP2 – XOP5 are fixed and can not be changed. The functions performed by each of these instructions can be changed for each question e.g. XOP5 could implement a register addressing mode ADD instruction in one question and a register addressing mode SUB instruction in another. At the end of each question there is a description of the files that you need to submit. These files should be placed in a directory of the same name i.e. Q1, Q2, Q3, or Q4. When complete these directories should be compressed into a single file: SYS1.zip and uploaded through the submission system.

Questions 

Square : write a program to draw a square in the RGB image stored in memory. The position and size of the square is fixed. The top left corner is co-ordinate (4,4), each side is 16 pixels long, alternating in colour between yellow and purple, as shown in figure 1. This image is stored in memory using the packed RGB data type shown in figure 2. For more information on this data type refer to practical 9.

  • Functionality correctly drawing the square.
  • Processing performance how quickly your program performs this task. Marks will be deducted for incorrect or missing RTL descriptions of any new instructions used.
  • Minimizing program size minimising storage i.e. instructions and program data. Image data is not included in this calculation.

2. Encrypt write a program using the base instruction-set to encrypt an RGB image using a simple block cipher i.e. you are not allowed to add new instructions to your system when implementing this solution. 

3. Optimise rewrite your solution for question 2 using new instructions and hardware to improve your solution’s processing performance. Marks are awarded for:

  • Processing performance how quickly your program performs this task. Marks will be deducted for incorrect or missing RTL descriptions of any new instructions used.
  • Minimising program size minimizing storage i.e. instructions and program data. Image data is not included in this calculation.
Recent Post

Order this Assignment now

Total: GBP120

fables template