From 913f2f796a6431c91987ef96400d9a685814ee80 Mon Sep 17 00:00:00 2001 From: Debayan Sutradhar Date: Sat, 25 Jan 2025 16:41:36 +0530 Subject: [PATCH] improve docs, rename art to images --- README.md | 2 +- docs/display.md | 18 +++++++++--------- examples/{art => images}/blank.txt | 0 examples/{art => images}/hello.txt | 0 examples/{art => images}/india.txt | 0 examples/{art => images}/namaste.txt | 0 examples/{art => images}/umbrella.txt | 0 shilpi.py | 4 ++-- 8 files changed, 12 insertions(+), 12 deletions(-) rename examples/{art => images}/blank.txt (100%) rename examples/{art => images}/hello.txt (100%) rename examples/{art => images}/india.txt (100%) rename examples/{art => images}/namaste.txt (100%) rename examples/{art => images}/umbrella.txt (100%) diff --git a/README.md b/README.md index 7951f1d..c1e46a1 100644 --- a/README.md +++ b/README.md @@ -2,7 +2,7 @@ # Sutra-1 / সুত্র-1 / सूत्र-1 -*Simple 10-bit CPU from scratch* +*10-bit CPU and Assembler* Sutra-1 Main Screenshot diff --git a/docs/display.md b/docs/display.md index 3701cc1..98ba8d6 100644 --- a/docs/display.md +++ b/docs/display.md @@ -29,32 +29,32 @@ I have included a simple companion program that can generate program to print so python shilpi.py -t 'namaste world' ``` -This generates an output assembly file with the name `art.S` which can then be compiled by rochoyita +This generates an output assembly file with the name `display-image.S` which can then be compiled by rochoyita ``` -python rochoyita.py art.S +python rochoyita.py display-image.S ``` -This will generate an output file `art.hex` that can then be loaded to memory in our `main` circuit inside Logisim Evolution +This will generate an output file `display-image.hex` that can then be loaded to memory in our `main` circuit inside Logisim Evolution Shilpi text mode screenshot ### Image mode -We can also provide it a 64x32 1-bit image formatted with pixel ON as '#' and OFF as '.'. A blank template is provided in `examples/art/blank.txt` +We can also provide it a 64x32 1-bit image formatted with pixel ON as '#' and OFF as '.'. A blank template is provided in `examples/images/blank.txt` -I have also included some 1-bit images in `examples/art` that can be parsed by shilpi and rendered on Sutra-1 +I have also included some 1-bit images in `examples/images` that can be parsed by shilpi and rendered on Sutra-1 ```shell -python shilpi.py examples/art/india.txt +python shilpi.py examples/images/india.txt ``` -This generates an output assembly file with the name `art.S` which can then be compiled by rochoyita +This generates an output assembly file with the name `display-image.S` which can then be compiled by rochoyita ```shell -python rochoyita.py art.S +python rochoyita.py display-image.S ``` -This will generate an output file `art.hex` that can then be loaded to memory in our `main` circuit inside Logisim Evolution +This will generate an output file `display-image.hex` that can then be loaded to memory in our `main` circuit inside Logisim Evolution Shilpi image mode screenshot \ No newline at end of file diff --git a/examples/art/blank.txt b/examples/images/blank.txt similarity index 100% rename from examples/art/blank.txt rename to examples/images/blank.txt diff --git a/examples/art/hello.txt b/examples/images/hello.txt similarity index 100% rename from examples/art/hello.txt rename to examples/images/hello.txt diff --git a/examples/art/india.txt b/examples/images/india.txt similarity index 100% rename from examples/art/india.txt rename to examples/images/india.txt diff --git a/examples/art/namaste.txt b/examples/images/namaste.txt similarity index 100% rename from examples/art/namaste.txt rename to examples/images/namaste.txt diff --git a/examples/art/umbrella.txt b/examples/images/umbrella.txt similarity index 100% rename from examples/art/umbrella.txt rename to examples/images/umbrella.txt diff --git a/shilpi.py b/shilpi.py index dcc7c45..f037e68 100644 --- a/shilpi.py +++ b/shilpi.py @@ -474,12 +474,12 @@ def generate_art_from_text(text): if args.text: art = generate_art_from_text(args.input) - output_file_name = args.output if args.output else 'art.S' + output_file_name = args.output if args.output else 'display-image.S' print(art) else: input_file_name = args.input - output_file_name = args.output if args.output else f'{Path.cwd()}{os.sep}art.S' + output_file_name = args.output if args.output else f'{Path.cwd()}{os.sep}display-image.S' with open(input_file_name, 'r') as f: # art = f.readlines()