This document describes a summer internship project called "Graphical Interpreter: Buddhuram Dumbo in Action" conducted at IIT Bombay. The project involved developing a graphical interpreter application to allow students to input C code and observe how it is executed step-by-step. Key components of the application included a parser to tokenize the input code, graphical interface functions to generate animations, and modules to handle I/O, memory representation, and error handling. The goal was to help students better understand basic computer architecture concepts through interactive experimentation with code execution.
Remote interpreter API model for supporting computer programming adaptive lea...TELKOMNIKA JOURNAL
Despite the adoption of Learning Management Systems (LMS) has been continuously growing in the last decade few, if any, scholars addressed the lack of the interactivity in online learning systems. The requirement for an interactive learning model has been increasingly prominent as content providers realize the importance of personalization of content suits to learners’ learning progress. This paper demonstrates the adoption of adaptive learning into existing LMS engine to overcome the limitation of either systems plugins or server specification pertinent to students’ psychomotor abilities in computer programming learning. In this regard, the psychomotor is understood as the ability of students to write the program code as correctly as expected. In this study, a web API model that works to run an interpreter based-program code remotely was developed. The web API model can be utilized by LMS so it becomes the solution to the problem. The structure of the web API model has been adapted to the needs of the learning assessment. The implementation of the developed API web model is done in Python and PHP programming languages. The performance test was done by submitting 10 to 100 program codes simultaneously indicated no significant difference to the required resources (CPU usage and memory usage) to run the program code. Furthermore, for response time, the average time needed to run Python and PHP program code is also no significant difference. The average of CPU usage required by the web API to run a Python program code is 0.2058% with 0.5973 seconds as a response time. Meanwhile, to run the PHP program code, the average CPU usage required is 0.8074% with 0.3110 seconds response time. It can be concluded that the web API performance does not overburden the server.
Remote interpreter API model for supporting computer programming adaptive lea...TELKOMNIKA JOURNAL
Despite the adoption of Learning Management Systems (LMS) has been continuously growing in the last decade few, if any, scholars addressed the lack of the interactivity in online learning systems. The requirement for an interactive learning model has been increasingly prominent as content providers realize the importance of personalization of content suits to learners’ learning progress. This paper demonstrates the adoption of adaptive learning into existing LMS engine to overcome the limitation of either systems plugins or server specification pertinent to students’ psychomotor abilities in computer programming learning. In this regard, the psychomotor is understood as the ability of students to write the program code as correctly as expected. In this study, a web API model that works to run an interpreter based-program code remotely was developed. The web API model can be utilized by LMS so it becomes the solution to the problem. The structure of the web API model has been adapted to the needs of the learning assessment. The implementation of the developed API web model is done in Python and PHP programming languages. The performance test was done by submitting 10 to 100 program codes simultaneously indicated no significant difference to the required resources (CPU usage and memory usage) to run the program code. Furthermore, for response time, the average time needed to run Python and PHP program code is also no significant difference. The average of CPU usage required by the web API to run a Python program code is 0.2058% with 0.5973 seconds as a response time. Meanwhile, to run the PHP program code, the average CPU usage required is 0.8074% with 0.3110 seconds response time. It can be concluded that the web API performance does not overburden the server.
With the availability of code editors, program writing becomes very easy. The Available code editors are
for writing sequential programs. These editors are unable to perform preprocessing on source code that is
required for parallel lexical analysis. In this paper we present a smart editor which automatically
performs preprocessing while writing a program. By the use of this editor substantial amount of time can
be saved in lexical analysis process.
Interactive Electronic Technical Manuals, JSG 0852:2001 is India's defense standard. Code and Pixels is the pioneer in designing IETMs
Code and Pixels is Pioneer in designing and developing of IETMs. Code and pixels is the only company in Hyderabad having strong R&D team exclusively for IETM
Hello guys ,
As a passionate learner of c programming language, I have done my one month training in Learning advance features of C from "infomatics" center through very experienced teachers and for the fulfillment of my training i have submit this report .
Happy Reading
With the availability of code editors, program writing becomes very easy. The Available code editors are
for writing sequential programs. These editors are unable to perform preprocessing on source code that is
required for parallel lexical analysis. In this paper we present a smart editor which automatically
performs preprocessing while writing a program. By the use of this editor substantial amount of time can
be saved in lexical analysis process.
Interactive Electronic Technical Manuals, JSG 0852:2001 is India's defense standard. Code and Pixels is the pioneer in designing IETMs
Code and Pixels is Pioneer in designing and developing of IETMs. Code and pixels is the only company in Hyderabad having strong R&D team exclusively for IETM
Hello guys ,
As a passionate learner of c programming language, I have done my one month training in Learning advance features of C from "infomatics" center through very experienced teachers and for the fulfillment of my training i have submit this report .
Happy Reading
With the development of digital technologies in recent decades, there has been drastic change in the mode of communication and usages of digital accessories in our today lives . Development nowadays is full of compromises. Engineers are compelled to pick between either assembling the equivalent application on numerous occasions for different working frameworks, or to acknowledge a most reduced shared element arrangement that exchanges local speed and exactness for compactness. The main aim of the research paper is to analyze design, build and test mentors' view apps. In this application the mentor connects with the mentee. Mentor solves the problem of the mentee. In this application mentor and mentee , mentee and mentor both are connected with each other. Software has been developed as an interactive and collaborative learning aid. Flutter is an open source. SDK for making elite, high-devotion versatile applications for iOS and Android. Significant features of flutter are - Just-in-time compilation is a way of executing computer code that involves compilation during execution of a program at run time rather than prior to execution. The application is very easy to use. That tool could benefit students in general. The application does require internet connection. Each user will have their own database for profiles.
Hi There, This Synopsis report is Implemented by Umang Saxena,Sakshi Sharma and Ronit Shrivastava of IT Branch,SVVV Indore.This will help for those students who wants to make a good and effective report regarding to any topic.
Thank you
Warm regards
The application of computer aided learning to learn basic concepts of branchi...ijma
This paper reviews how to create an application based on Computer Aided Learning (CAL), which is the
use of computers to deliver instructional materials and involve students / learners are active. This CAL
application consists of 5 multimedia modules. Module 1 contains the basic concepts of data processing.
Module 2 discusses the concept of flowcharts. Module 3 contains the testing applications using a flowchart.
Module 4 contains the concept of nested selection. While the tutorial module 5 contains the concept of
arrays and study case practice . To support this, CAL application is made as attractive as possible, by
combining multimedia files, such as image files, sound files, and video files. With the CAL is equipped with
modules of algorithms, students are expected to take computer courses, especially in STMIK STIKOM
Surabaya can improve learning outcomes at the course logic algorithms.
Exploiting Artificial Intelligence for Empowering Researchers and Faculty, In...Dr. Vinod Kumar Kanvaria
Exploiting Artificial Intelligence for Empowering Researchers and Faculty,
International FDP on Fundamentals of Research in Social Sciences
at Integral University, Lucknow, 06.06.2024
By Dr. Vinod Kumar Kanvaria
Executive Directors Chat Leveraging AI for Diversity, Equity, and InclusionTechSoup
Let’s explore the intersection of technology and equity in the final session of our DEI series. Discover how AI tools, like ChatGPT, can be used to support and enhance your nonprofit's DEI initiatives. Participants will gain insights into practical AI applications and get tips for leveraging technology to advance their DEI goals.
Unit 8 - Information and Communication Technology (Paper I).pdfThiyagu K
This slides describes the basic concepts of ICT, basics of Email, Emerging Technology and Digital Initiatives in Education. This presentations aligns with the UGC Paper I syllabus.
Normal Labour/ Stages of Labour/ Mechanism of LabourWasim Ak
Normal labor is also termed spontaneous labor, defined as the natural physiological process through which the fetus, placenta, and membranes are expelled from the uterus through the birth canal at term (37 to 42 weeks
Safalta Digital marketing institute in Noida, provide complete applications that encompass a huge range of virtual advertising and marketing additives, which includes search engine optimization, virtual communication advertising, pay-per-click on marketing, content material advertising, internet analytics, and greater. These university courses are designed for students who possess a comprehensive understanding of virtual marketing strategies and attributes.Safalta Digital Marketing Institute in Noida is a first choice for young individuals or students who are looking to start their careers in the field of digital advertising. The institute gives specialized courses designed and certification.
for beginners, providing thorough training in areas such as SEO, digital communication marketing, and PPC training in Noida. After finishing the program, students receive the certifications recognised by top different universitie, setting a strong foundation for a successful career in digital marketing.
Biological screening of herbal drugs: Introduction and Need for
Phyto-Pharmacological Screening, New Strategies for evaluating
Natural Products, In vitro evaluation techniques for Antioxidants, Antimicrobial and Anticancer drugs. In vivo evaluation techniques
for Anti-inflammatory, Antiulcer, Anticancer, Wound healing, Antidiabetic, Hepatoprotective, Cardio protective, Diuretics and
Antifertility, Toxicity studies as per OECD guidelines
Synthetic Fiber Construction in lab .pptxPavel ( NSTU)
Synthetic fiber production is a fascinating and complex field that blends chemistry, engineering, and environmental science. By understanding these aspects, students can gain a comprehensive view of synthetic fiber production, its impact on society and the environment, and the potential for future innovations. Synthetic fibers play a crucial role in modern society, impacting various aspects of daily life, industry, and the environment. ynthetic fibers are integral to modern life, offering a range of benefits from cost-effectiveness and versatility to innovative applications and performance characteristics. While they pose environmental challenges, ongoing research and development aim to create more sustainable and eco-friendly alternatives. Understanding the importance of synthetic fibers helps in appreciating their role in the economy, industry, and daily life, while also emphasizing the need for sustainable practices and innovation.
Model Attribute Check Company Auto PropertyCeline George
In Odoo, the multi-company feature allows you to manage multiple companies within a single Odoo database instance. Each company can have its own configurations while still sharing common resources such as products, customers, and suppliers.
Francesca Gottschalk - How can education support child empowerment.pptxEduSkills OECD
Francesca Gottschalk from the OECD’s Centre for Educational Research and Innovation presents at the Ask an Expert Webinar: How can education support child empowerment?
June 3, 2024 Anti-Semitism Letter Sent to MIT President Kornbluth and MIT Cor...Levi Shapiro
Letter from the Congress of the United States regarding Anti-Semitism sent June 3rd to MIT President Sally Kornbluth, MIT Corp Chair, Mark Gorenberg
Dear Dr. Kornbluth and Mr. Gorenberg,
The US House of Representatives is deeply concerned by ongoing and pervasive acts of antisemitic
harassment and intimidation at the Massachusetts Institute of Technology (MIT). Failing to act decisively to ensure a safe learning environment for all students would be a grave dereliction of your responsibilities as President of MIT and Chair of the MIT Corporation.
This Congress will not stand idly by and allow an environment hostile to Jewish students to persist. The House believes that your institution is in violation of Title VI of the Civil Rights Act, and the inability or
unwillingness to rectify this violation through action requires accountability.
Postsecondary education is a unique opportunity for students to learn and have their ideas and beliefs challenged. However, universities receiving hundreds of millions of federal funds annually have denied
students that opportunity and have been hijacked to become venues for the promotion of terrorism, antisemitic harassment and intimidation, unlawful encampments, and in some cases, assaults and riots.
The House of Representatives will not countenance the use of federal funds to indoctrinate students into hateful, antisemitic, anti-American supporters of terrorism. Investigations into campus antisemitism by the Committee on Education and the Workforce and the Committee on Ways and Means have been expanded into a Congress-wide probe across all relevant jurisdictions to address this national crisis. The undersigned Committees will conduct oversight into the use of federal funds at MIT and its learning environment under authorities granted to each Committee.
• The Committee on Education and the Workforce has been investigating your institution since December 7, 2023. The Committee has broad jurisdiction over postsecondary education, including its compliance with Title VI of the Civil Rights Act, campus safety concerns over disruptions to the learning environment, and the awarding of federal student aid under the Higher Education Act.
• The Committee on Oversight and Accountability is investigating the sources of funding and other support flowing to groups espousing pro-Hamas propaganda and engaged in antisemitic harassment and intimidation of students. The Committee on Oversight and Accountability is the principal oversight committee of the US House of Representatives and has broad authority to investigate “any matter” at “any time” under House Rule X.
• The Committee on Ways and Means has been investigating several universities since November 15, 2023, when the Committee held a hearing entitled From Ivory Towers to Dark Corners: Investigating the Nexus Between Antisemitism, Tax-Exempt Universities, and Terror Financing. The Committee followed the hearing with letters to those institutions on January 10, 202
1. Graphical Interpreter
Buddhuram Dumbo in Action
Summer Internship-2013
Under the Guidance of
Dr. D. B. Phatak
Mr. Avinash Awate
Department of Computer Science and Engineering,
Indian Institute of Technology-Bombay,
Mumbai
2. Graphical Interpreter Summer Internship 2013, IIT-Bombay
Acknowledgement
Summer Project is a golden opportunity for learning and self development . We
consider ourself very lucky and honoured to have so many wonderful people who
lead me through in the completion of this project.
It has been a great experience while undertaking project “GRAPHICAL
INTERPRETER: BUDDHURAM DUMBO IN ACTION” because it gave us an
opportunity to learn, add value and enrich my knowledge.
We are whole heartedly thankful to Dr. D. B. Phatak for organizing the
Summer Internship at IIT-Bombay as a part of Ekalavya Summer Internship
Programme 2013 and giving us an unique opportunity to explore knowledge and
develop industry level skills.
We take this opportunity to express our profound gratitude and deep regards
to Mr. Avinash Awate, the Program Director and our mentor for this project for his
guidance, monitoring and constant encouragement throughout the Internship.
We also take the opportunity to express a deep sense of gratitude to Mr.
Rajanikant Jangir and Mr. Mayank Paliwal for their support, guidance and
information at all the stages of the Internship.
We are obliged to staff members of CSE department of IIT-Bombay for their
constant support and co-operation during the Internship.
2
4. Graphical Interpreter Summer Internship 2013, IIT-Bombay
EKSHIKSHA
ekShiksha is an initiative to provide free education to school children all through
India. ekShiksha means an unique education which should be provided
throughout the country. It is an education program which mainly focuses with the
aim “Every child deserves to be an Einstein”.
The project is mainly conceptualised by the ideologies of various people starting
from the Plato, a great mathematician to Salman Khan of the Khan academy who
solely emphasised that children should never be stressed to learn, instead should
be left free to prepare themselves to grasp as much knowledge as they can.
The ekShiksha program targets the rural school students, where language
becomes an obstruction for their conceptual growth. This program facilitates
these students to gain knowledge in various Indian languages.
This program is headed by Mr. Avinash Awate with his team. This program is
initiated by IIT-Bombay to work for enhancement of the education throughout
India. Our project is a part of this noble program which helps in the development
of the future citizens of our country.
“Every child deserves an opportunity to be an Einstein “
4
5. Graphical Interpreter Summer Internship 2013, IIT-Bombay
1. INTRODUCTION
1.1 PURPOSE
In a large number of educational institutions, programming languages are taught without giving
the student an adequate appreciation of the way in which the languages are executed on the
machine. Even though students learn to write code well, they lack the basic knowledge of
computer architecture.
In order to become better programmers, every programmer must have an overall
understanding of the machine’s internals and how programming instructions are executed in the
machine to produce the desired results. Experimentation / interaction leads to a much fuller
understanding and retention of any subject. In this project, an application
“Graphical Interpreter: Buddhuram Dumbo In Action” is to be developed to allow
students to feed commands and observe how they get executed inside the machine.
1.2 THE SCOPE OF THE GRAPHICAL INTERPRETER
The student can feed a single declaration and observe a memory location getting labeled.
The student can feed an initialization statement to see the memory location being ‘filled’.
The student can feed simple instructions and observe the effect on memory/registers.
The student can feed input/output instructions and observe the effect on the terminal.
The student can (optionally) manipulate the disk using disk I/O functions.
The student can store his own set of instruction and replay them.
The student can load illustrative sample sets and see the effect.
The student can also run relatively complex programs.
We will not attempt a full fledged interpreter in this phase. We may leave out certain
functionality depending on the available programming bandwidth.
The graphical interpreter (along with the developer names) will be published on the ekshiksha
portal.
5
1.3 OBJECTIVES
The Graphical Interpreter is intended as an educational tool that helps students better
understand basic computer architecture. The application is intended to initially execute C
commands. The architecture of the system is intended to be neutral in order for the application
to be extensible. The application is intended to be a stand-alone application that will function
without the use of a server. It is also intended as a cross platform tool that can be run over a
variety of platforms.
7. Graphical Interpreter Summer Internship 2013, IIT-Bombay
The application “Graphical Interpreter: Buddhuram Dumbo in Action” executes in
following manner:
1. User inputs C code in following two ways:
a. Selects a file which has C code stored in it.
b. Writes instructions manually using text editor.
2. The C code from the file or which the user has entered can be viewed in the view panel.
3. The user clicks the execute button.
4. The C code is then sent to the Parser which tokenizes the code and calls the appropriate
7
graphical interface functions.
5. The graphical interface functions generate intermediate codes.
6. Intermediate codes are pushed in the queue.
7. As the user clicks the play button, intermediate code is executed and graphics
animations is played.
8. The user has two options; either to execute intermediate code step-by-step or all at
once.
9. The application enquires the user whether to execute next C code or to terminate the
application.
8. Graphical Interpreter Summer Internship 2013, IIT-Bombay
8
2.1 FRAMEWORK MODULE
The Framework of Graphical Interpreter is made in java language by importing java
libraries:
javax.swing.*
java.awt.*
The graphical interpreter ‘executes’ a given code segment statement by statement.
There are two options for specifying input. The student can store his own code
segments and review their execution. Finally the student can write his own statement
and observe the machine execute the code.
This GUI (Graphical User Interface) application has following functionalities:
Open File Operation:
Used to select a file which user wants to use as input and displays the contents
of it in Text Editor Panel for execution.
The file is selected and saved using JFileChooser.
9. Graphical Interpreter Summer Internship 2013, IIT-Bombay
9
Save File Operation:
Used to save the C instructions entered by user manually.
10. Graphical Interpreter Summer Internship 2013, IIT-Bombay
10
Help Menu:
Provides Online help and user manual for using this application.
Animation Control
o Play : Plays the animation.
o Pause : Pauses the animation.
o Stop: Stops the animation.
o Execute: Executes the code segments step-by-step.
Explanation and Error Displays
o Gives information about the current instruction being executed and its
memory location labeling.
o Displays errors if the current instruction has errors like syntax errors,
division by zero etc.
Variables Panel
o Display Values of each variable.
11. Graphical Interpreter Summer Internship 2013, IIT-Bombay
JAVA CLASSES IN FRAMEWORK MODULE
There are four classes in GUI:
1). FrameWorkGIBDIA : This is the main class of graphical user interface. User can able to
open the file using file browser and contents of file are are displayed on the screen. This
class shows the buttons for controlling the animation of dumbo. It also provides the
flexibility of typing the instructions manually through keyboard and execution of them.
2). EditorPanel: EditorPanel class is responsible for text area where the source code is shown
on the user interface. Text area has undoable listener. It supports all cut, copy, and paste
operations
3). DynamicList: When a user clicks execute button DynamicList class convert the text area
into ArrayList make the code get ready for execution.
4). DisplayMessages: Displays all the error messages occurred while executing the instant
instruction or Error Display area on user interface.
Error may be graphics module error, parser errors like syntax, semantic, etc.... It
also show the explanation for the instruction that is being executed.
5). MiniParser: The Miniparser orders the given text before sending it to the parser. It
separates the input text into C language statements. It also puts brackets and other key
words into separate statements.
6). CommandList: CommandList stores the graphical instructructions to be executed. The
push method is used by the parser to insert commands. The pop command is used by the
framework to remove the first instruction in the queue.
11
13. Graphical Interpreter Summer Internship 2013, IIT-Bombay
13
2.2 Parser Module
Parser is the second module of our project called by framework. It takes a raw C statement
and converts it into intermediate commands easily understood by the graphical module.
While doing so , the parser should keep in mind that the order of intermediate commands
generated is in accordance with the precedence and associativity defined in the C language.
DUMMY PARSER
To simulate the behaviour of a parser we have written a dummy parser, where intermediate
commands are manually written. The constructor of the dummy parser class takes file name as
the input. It has the following functions:-
(1) boolean parse (String Cstatement, int lineno);
Framework calls this parse function with the C statement and the line number as argument.
The parse function has two switch statements. First switch is for the filename and the second
switch is for line number. Inside this, all the intermediate commands for that particular line is
coded.
The function returns true or false based on whether that C statement is properly compiled
without any errors or not.
14. Graphical Interpreter Summer Internship 2013, IIT-Bombay
2.3 Graphics Module
The Graphics part of Graphical Interpreter is made in LIBGDX , Blender and java
libraries.
Libgdx is a Java game development framework that provides a unified API that works across
all supported platforms.
The framework provides an environment for rapid prototyping and fast iterations. Instead of
deploying to Android/iOS/JavaScript after each code change, you can run and debug your
game on the desktop, natively. Desktop JVM features like code hot swapping reduce your
iteration times considerably.
14
FEATURES:
The exceptional features of the Libgdx API motivated us to use it. The major
features of the API are
Libgdx provides a single API to obtain crossplatform feature. It provides the
capability to run the application on various platforms .They are
a. Windows
b. Linux
c. Max OS X
d. Android (+1.5)
e. iOS
f. Java Applet (requires JVM to be installed)
g. Javascript/WebGL
Libgdx provides strong API for the graphics operations. It supports both 2d and 3D
graphics. The functions of the API are built on the concepts of object oriented
programming. The major advantage is its handling of the 3d objects which enables
us to do many graphics operations with already predefined methods.
Libgdx also allows us to use various utilities like Texture packer, bitmap font
generator, GDX setup UI and many more. This allows us to work with the API for
dynamic production of instances and their rendering.
Libgdx also has libraries for mathematics, physics, file input and output handling
and many other utitlities.
15. Graphical Interpreter Summer Internship 2013, IIT-Bombay
15
BASIC STRUCTURE:
The basic structure of the Libgdx program consists of five major methods. They are as
follows:
Create ()-This is used to create the graphic objects and all the declarations are handled
by this method.
Render ()-This is the major method which is used to obtain the graphics onto the screen.
The render is the infinite recursive method which is continuously plots the graphics
defined in the program.
Dispose ()-This method is used to dispose the assets continuously on the screen to
obtain the effect of graphics
Resume ()-This is used to resume the paused graphics.
Pause ()-This is used to pause the graphic operations.
Resize ()-This is used to obtain the resize property of the graphic window.
Example code
package com.test.myfirsttriangle;
import com.badlogic.gdx.ApplicationListener;
public class MyFirstTriangle implements ApplicationListener {
@Override
public void create() {
// TODO Auto-generated method stub
}
@Override
public void dispose() {
// TODO Auto-generated method stub
}
@Override
public void pause() {
// TODO Auto-generated method stub
}
@Override
public void render() {
// TODO Auto-generated method stub
}
@Override
public void resize(int width, int height) {
// TODO Auto-generated method stub
}
@Override
public void resume(){ }
16. Graphical Interpreter Summer Internship 2013, IIT-Bombay
Blender is a free and open-source 3D computer graphics software product used for creating
animated films, visual effects, art, 3D printed models, interactive 3D applications and video
games. Blender is a dominant open-source product with a range of features comparable to mid-to
high-range commercial, proprietary software.
The default blender screen is fixed with the camera, lamp and the basic primitive mesh i.e the
cube.
16
FEATURES:
Blender has a relatively small installation size, of about 70 megabytes for builds and 115
megabytes for official releases. Official versions of the software are released for Linux, Mac
OS X, Microsoft Windows, and FreeBSD in both 32 and 64 bits. This software contains
features that are characteristic to the high end 3D software. Some of the features that make
blender one of the most popular among all the Animation software are:
Support of a huge variety of geometric primitives like Bezier curves, meshes etc.
17. Graphical Interpreter Summer Internship 2013, IIT-Bombay
Internal render engine with scanline ray tracing, indirect lighting, and ambient
occlusion that can export in a wide variety of formats.
A pathtracer render engine called Cycles.
Keyframed animation tools including inverse kinematics, armature (skeletal), hook,
curve and lattice-based deformations, shape keys (morphing), non-linear animation,
constraints, and vertex weighting.
Modifiers to apply non-destructive effects.
Python scripting for tool creation and prototyping, game logic, importing and/or
exporting from other formats, task automation and custom tools.
The Blender Game Engine
Procedural and node-based textures, as well as texture painting, projective painting,
vertex painting, weight painting and dynamic painting.
17
Camera and object tracking.
Excellent user Interface
BASIC BLENDER FEATURE CREATION:
Blender is flexible and easily adaptable software for animations. Every function in blender has
a shortcut making it easy for usage. It is provided with contextual menus for more logical and
streamlined operations. There are also imparting certain features like colors, themes, widgets
etc.
Blender has two major modes of working. They are:
1) Object Mode: In this mode we can create our 3D objects by inserting and modifying the
already provided set of objects. The operations on the complete objects can be performed in the
object mode.
2) Edit Mode: In this mode we can edit or modify the selected object or any part of the selected
object. The edit mode is used for performing various operations on the attributes of the object
like size, location, alignment etc.
The major advantage of blender is the 3d model that is made can be exported into different
formats. To embed the model made in blender into our gaming platform Libgdx we export it
into the Wave front format (.obj) and import it as a model into our application on the Libgdx
platform.
18. Graphical Interpreter Summer Internship 2013, IIT-Bombay
THE GRAPHICS WINDOW:
The graphics window is the graphical output that the user can see. It contains the graphical
objects depicting the hardware used for executing the basic “C” instructions. The graphics
window mainly contains the blender models imported into Libgdx code of the application.
The main components in the window are:
1) The Room: The room depicts the hardware of the workspace where the memory and
registers operations take place.
2) The Boxes: The boxes which are on to the left side of the room depict the memory locations
in the computer. Each box depicts a single memory location .The variable and value of the
variable is stored in the memory in this case the box. The memory locations are infinite in
number to enable large variable declarations.
3) The Windows: The windows which are to the right of the room depict the registers of the
computer. The values of the variables which are involved in the operations are taken from the
memory i.e the box and put into the registers “R1” and “R2” for evaluation. The result is put in
a special window named accumulator “ACC”. The result is then taken back and stored into the
memory boxes.
4) The Display: The display board is hung from the ceiling of the roof. This board indicates the
present statement that is being executed. This enables the dumbo to pick up the values and
perform operations on them.
18
19. Graphical Interpreter Summer Internship 2013, IIT-Bombay
5)The Dumbo: The dumbo is the important part of the execution as it depicts the control flow
of instructions and the procedure of how these instructions are performed. The dumbo picks the
values from display, puts it in memory or registers and manipulates the position and value
according to the evaluation of the instructions given.
6) The Label: The values appearing on the box and the register are dynamically generated
which depict the variable name and its value. The label is generated according to the execution
of the given instructions.
These objects included in the graphics are given animation to give a sense of execution through
the graphical interface commands.
When the user types the instruction ” int a=2;”, the instruction is displayed on the
screen and the following scenario takes place.
o The current instruction is displayed on display screen.
o A free memory box is selected and it is labeled as “a”.
19
20. Graphical Interpreter Summer Internship 2013, IIT-Bombay
o The dumbo opens the memory box “ a ” and puts “ 2 ” into it.
Similar operation takes place when user inputs “int b=3;” and “int c”;.
20
21. Graphical Interpreter Summer Internship 2013, IIT-Bombay
When the user enters “c=a+b;” the following scenario takes place:
o The dumbo picks the value of variable “a” from memory box “a” and puts it into
21
register R1.
o The dumbo picks the value of variable “b” from memory box “b” and puts it
into register R2.
o Appropriate mathematical operation is performed and result is stored in
accumulator. Here, addition is being performed.
25. Graphical Interpreter Summer Internship 2013, IIT-Bombay
JAVA CLASSES IN GRAPHICS MODULE
Package graphics:
Dumbo Class: Main graphics class.
Public void create() : default Libgdx method for
initialization of graphical components.
Public void loading() : loads assets in program
Public void render() : it’s a game loop(called by Libgdx
as many times as possible) and contains dynamic handling
of graphical objects.
Public void show_text(int type, int value, String text) :
displays the operand and value of variables as text in
box, registers, accumulator .
Public void box_close(int boxno) : close the box with
given box number.
Public void box_open(int boxno) : opens the box with given
box number.
Public void labelBox(String label, int boxNo) : labels the
given box with label.
Public void look_to_default() : sets the camera at default
position.
Public void look_to_memory_wall(int boxNo) : sets the
camera to look at given box.
Public void look_to_register_wall() : sets the camera to
look at register wall.
Public void movedumbo(int init_pos_type,int
final_pos_type,int final_pos) : moves the dumbo from
initial to final position.
Private void movedumbo() : called by render method to move
the dumbo(for internal use).
Private void rotate_dumbo() : to rotate the dumbo while
moving(for internal use).
Public void dispose() : releases all the resources while
exiting.
25
26. Graphical Interpreter Summer Internship 2013, IIT-Bombay
Public Boolean needsGL20() : returns true if openGL 2.0 is
needed.
Public void pause() : called when pause button is pressed
and saves the program state.
Public void resume() : resumes from saved program state.
Public void displaycmd(String string) : displays the given
string on screen.
DesktopGraphic Class: Main class which instantiates dumbo graphics class and Framework
class.
main(): main class called by jvm.
DisplayMessages Class: Displays messages in the framework.
DisplayLine(): display the current highlighted line.
FrameWorkGIBDIA Class: Main class of framework. And controls all execution of
commands.
startFramework():start loading all panel and its
26
listeners.
showGUI(): shows all defined GUI components.
28. Graphical Interpreter Summer Internship 2013, IIT-Bombay
3 INTERFACING MODULES:
3.1 INTERFACING BETWEEN FRAME WORK MODULE AND
28
PARSER MODULE:
3.1.1 JAVA NATIVE INTERFACE
The Java Native Interface (JNI) is a programming framework that enables Java code running in
a Java Virtual Machine (JVM) to call, and to be called by, native applications (programs
specific to a hardware and operating system platform) and libraries written in other languages
such as C, C++ and assembly.
Although there may be several reasons that one would want to use native code, two common
justifications are code reuse and performance.
Code Reusability. Sometimes, the benefits of using Java at a level do not outweigh the
overwhelming task of re-implementing currently tested and debugged C/ C++ code. Given
large amounts of proven C/C++ code, it may be more cost-effective to incorporate its
functionality into a Java program, rather than to port (re-implement/test/debug) the C/C++
functionality in Java.
Performance. Given that Java is interpreted (more or less), one would assume that compiled
native code would perform much better. It may be useful to "hand-code" native methods where
speed is critical.
29. Graphical Interpreter Summer Internship 2013, IIT-Bombay
3.2 INTERFACING BETWEEN PARSER MODULE AND
29
GRAPHICS MODULE
1. The C code is sent to the parser which tokenizes the code and calls the appropriate
graphical interface functions.
2. The graphical interface functions generate intermediate codes.
3. Intermediate codes are pushed in the queue
4. As the user clicks the play button intermediate code executes and graphics
animations is played.
JAVA CLASSES IN PARSER-GRAPHICS INTERFACING
MODULE (GRAPHICAL VIRTUAL MACHINE)
1. Accumulator Class : Stores the results of the arithmetic and logical operations.
getBoolean(): return boolean of the result.
getValue(): returns value of the accumulator.
2. Box Class : A Memory Block, which has specified address and value in it.
getValue(int n): returns the value in the box.
createBox(Command comm): allocates a memory block.
storeOperation(Operand op1,Operand op2): stores the values of
operands in backend and shows visual of this operation.
3. GraphicalInterpreter Class : Hard coded file.
Cache Class: Stores intermediate results of expression evaluation. Built on stack data structure.
getValue(int n): returns the value at that index.
4. Command Class: We have four types of commands label, store , display, operation. It has
methods to create and execute commands.
#setCommandtype setters and getters for commandtype, qualifiers,
operators, type, and identifier name.
executecommand() throws IOException: executes the command and
throws exception if it is not valid.
5. IndexQualifier Class: Tells whether index is expression, literal or identifier. It is used for array
values assignments.
30. Graphical Interpreter Summer Internship 2013, IIT-Bombay
6. InterfaceClass Class: Which implements graphicalinterface.
createLabelCommand(String identifier, int type,Qualifier
qualifier): creates and returns the label command with the
given arguments.
createStoreCommand(Operand lhs, Operand rhs): crates and returns
the store command with the given arguments.
createOperaionCommand(int operator, Operand operand1,Operand
operand2): crates and returns the operation command with the
given arguments.
createDisplayCommand(String codeLine,int lineno): creates a and
returns a display command with the given arguments.
30
7. Memory Class: Memory allocation tracker.
getBoxInstance(int box_num): returns the box instance for the
given box number.
doRegisterBox(String identifier): assigns the box number.
getLabel(int boxno): returns identifier name of the specified
memory location.
getQualifier(String identifier): returns the qualifier for the
given idenfier.
getType(String identifier): returns the data type of the
identifier.
getValue(String identifier): returns value of the identifier.
8. Operand Class: We will have information of operand source.
getters and setters for value type and box number.
9. Qualifier Class: Will have additional information about identifier, like whether it’s an array, or
pointer or array of pointers variable.
getDimensions(): returns array dimensions.
getQualifier_type(): returns qualifier type.
31. Graphical Interpreter Summer Internship 2013, IIT-Bombay
10. Register Class: One block memory location mimics register in hardware.
performOperation(int operator,Operand op1,Operand op2): performs
the operation on the given arguments.
ACTIVITY CLASS DIAGRAM : GRAPHICAL INTERFACE
31
32. Graphical Interpreter Summer Internship 2013, IIT-Bombay
FUTURE SCOPE
The Graphical Interpreter can visualize the basic “C “instructions. This is the first
version of the application which mainly focuses on the basics of programming language. The
application is built with a flexible architecture that can be extended to implement any further
developments. These developments lead to build a complete application which deals with the
complex concepts of the language.
It is built to work with “C” language but can be used for various other programming languages
by just changing the parser module of the existing Graphical interpreter application.
The application forms a major platform for the inquisitive students to learn the programming
language from the fundamentals by browsing the already existing files or the by entering the
code directly. This paves an easy way for students to develop interest in various programming
languages and work towards it.
The graphical interpreter is also a teaching aid for teachers, which helps them in imparting the
conceptual knowledge of the language and also develop interest among the students who lack
understanding skills. It becomes a mode of analyzing the student’s interest and his way of
problem solving in the language.
32
33. Graphical Interpreter Summer Internship 2013, IIT-Bombay
CHALLANGES
• Generating the in intermediate code
• Re-sizable panels
• Dynamic text generation
• Implementing the whole project in android platform
• Integrating all the modules
33
34. Graphical Interpreter Summer Internship 2013, IIT-Bombay
CONCLUSION
Our project “GRAPHICAL INTERPRETER-BUDDHURAM DUMBO IN ACTION” is a part
of the ekShiksha program. The project mainly works for enriching the knowledge among
students who enter into the huge world of computers and become an integral part of that world.
The project is a little trail to uplift the process of understanding the language internal
execution with the help of graphics. The graphics help us to give the proper order of execution
in gaining complete overview of the underlying control of execution of the language. The
application also involves modules to enhance the application. Thus, the application makes an
important place in the basic understanding of programming language which enables it a good
tool both for teachers and students.
34
35. Graphical Interpreter Summer Internship 2013, IIT-Bombay
Team Members
Abhishek Prasad- IIIrd year, Computer Science and Engineering,
S. V. National Institute of Technology, Surat
Aditya Ravichandran- IIIrd year, Computer Science and Engineering,
The LNM Institute of Information Technology, Jaipur.
Ankur Bhardwaj- IIIrd year, Information Technology,
National Institute of Technology, Suratkal
Ashwani Kumar- IIIrd year, Computer Science and Engineering,
V. National Institute of Technology, Nagpur
Basav Singh- IIIrd year, Information Technology,
National Institute of Technology, Suratkal
Divya Shree- IIIrd year, Computer Science and Engineering,
Sri Mata Vaishno Devi University, Katra, Jammu
K.S.G.P.Harshita- IIIrd year, Computer Science and Engineering,
GVP College of Engineering for Women, Vizag.
Naveen Kumar Chittipolu- IIIrd year, Computer Science and
Engineering, RGU - IIIT, Basar, AP
Shiva Kumar Kanneboina- IIIrd year, Computer Science and
Engineering, RGU - IIIT, Basar, AP
Shobhit Srivastava- IIIrd year, Computer Science and Engineering,
National Institute of Technology, Goa
Srivatsan Kumar- IIIrd year, Computer Science and Engineering,
Coimbatore Institute of Technology, Coimbatore.
35
36. Graphical Interpreter Summer Internship 2013, IIT-Bombay
BIBLIOGRAPHY
36
Study material provided by mentor
Mr. Avinash awate
Google search engine
http://libgdx.badlogicgames.com
steigert | Android Development: libgdx
code.google.com/p/libgdx/
https://github.com/libgdx/libgdx
blog.xoppa.com/basic-3d-using-libgdx
Blender Basics - Introduction for Beginners | Blender Cookie
www.blender.org