Interpreter to interpret Logo commands and draw canvas
An interpreter is made using p5.js in which the commands of logo language is parsed and executed by drawing on the canvas. The language logo was designed in 1967 for educational purposes, where a turtle moves on canvas based on the commands. Here in the interpreter only a subset of basic logo commands are dealt with. The commands which are implemented are :
- Movement commands like forward, backward, left and right.
- Pen Up and Pen Down Command
- Repeat Command
- Clear Screen Command
- Pen and Screen Color Command (Here color is decided based on rgb color values)
To learn more about Logo visit: https://en.wikipedia.org/wiki/Logo_(programming_language)
HTML, JavaScript, P5.JS
https://www.youtube.com/watch?v=i-k04yzfMpw&t
Contribution => Reimplemented features - forward, backward, left, right, pen up, pen down, repeat after watching the video as mentioned in the reference link. Implemented features - clear screen, pen color and screen color command as a continuation to the work.
Major Learnings => Learnt how to use p5.JS to interpret an input and draw based on that.