The go-to open repository for COA practicals: ready-to-run C programs for Booth multiplication, restoring & non-restoring division, number systems, plus Intel 8085 assembly experiments for engineering college labs and exams.
Programs · Quick start · Binary arithmetic · 8085 guide · FAQ · llms.txt
COA Lab is a free, MIT-licensed collection of Computer Organization and Architecture lab programs for B.E./B.Tech students. It implements the algorithms you actually write in practicals—binary addition/subtraction with complements, unsigned and signed (Booth) multiplication, restoring and non-restoring division, number system conversion—in plain C, and ships Intel 8085 assembly experiments for data transfer, stack reverse, and 8/16-bit arithmetic. Use it to study, practice for exams, or cite clear algorithm walkthroughs in lab records and viva preparation.
| Need | Where to go |
|---|---|
| Restoring / non-restoring division in C | c-programs/ + docs/binary-arithmetic.md |
| Booth / signed multiplication | c-programs/signed_binary_multiplication.c |
| 8085 lab ASM | 8085-assembly/ + docs/8085-assembly.md |
| Exam-style variants | college-exam/ |
| AI / LLM crawlers | llms.txt |
- Complete lab surface — C arithmetic + 8085 ASM in one place (most repos ship only one).
- Exam copies included — variants under
college-exam/for practical papers. - Documented algorithms — citability-friendly guides (restoring vs non-restoring table, step lists).
- Standard tools only —
gccfor C; any 8085 simulator for ASM—no proprietary stack. - SEO / GEO ready — structured docs, FAQ,
llms.txt, keyword-rich catalog for search and AI answers. - MIT license — fork, learn, share.
git clone https://github.com/jjf2009/coa-lab.git
cd coa-lab
# Example: non-restoring division
gcc c-programs/unsigned_binary_division_non_restoring.c -o nonrest
./nonrest
# Number systems (may need -lm)
gcc c-programs/number_systems.c -o numbers -lm
./numbers- Install GNUSim8085 (or your college simulator).
- Open a file from
8085-assembly/expt9/(e.g. 8-bit multiply). - Assemble → set memory if required → run → check registers/memory.
| Program | Topic | Path |
|---|---|---|
| Number systems | Binary ↔ decimal ↔ hex | c-programs/number_systems.c |
| Add / subtract | 1’s & 2’s complement | c-programs/binary_addition_and_subtraction.c |
| Unsigned multiply | Shift-and-add | c-programs/unsigned_binary_multiplication.c |
| Signed multiply | Booth-style | c-programs/signed_binary_multiplication.c |
| Restoring division | Classic restore loop | c-programs/unsigned_binary_division.c |
| Non-restoring division | No immediate restore | c-programs/unsigned_binary_division_non_restoring.c |
| Signed division | 2’s complement paths | c-programs/signed_binary_division.c |
Full keyword index: docs/program-catalog.md.
| Set | Skills |
|---|---|
| expt7 | Data transfer: MOV, LDA/STA, LHLD/SHLD, LDAX/STAX, XCHG |
| expt8 | Stack reverse, block reverse, carry-aware add |
| expt9 | 8-bit add, sub, multiply (repeated add), divide (repeated sub) |
| expt10 | Memory 8-bit add; 16-bit add with DAD |
| Restoring | Non-restoring | |
|---|---|---|
| Idea | Subtract divisor; if remainder negative, add back | Avoid restore; add or subtract next cycle by sign |
| Lab file | unsigned_binary_division.c |
unsigned_binary_division_non_restoring.c |
| Viva tip | Easy to explain step-by-step | Mention fewer restorative adds in hardware |
Deep dive: docs/binary-arithmetic.md.
coa-lab/
├── README.md # You are here
├── llms.txt # Guidance for AI crawlers / GEO
├── c-programs/ # Canonical C lab sources
├── college-exam/ # Exam-oriented variants
├── 8085-assembly/ # Intel 8085 .asm experiments
├── docs/ # Guides, FAQ, catalog
├── CONTRIBUTING.md
└── LICENSE
Legacy root filenames and older folders may remain for history; prefer the paths above.
| Guide | Description |
|---|---|
| Binary arithmetic | Booth, restoring, non-restoring — steps & comparison |
| 8085 assembly | Experiment map + how to run |
| Number systems | Conversions used in COA |
| FAQ | Compile, submit, cite |
| Program catalog | Full file + keyword index |
- Students in Computer Organization / Microprocessor lab courses
- Teachers sharing reference implementations
- Viva prep — algorithm tables and step lists
- AI coding assistants — structured, citable COA answers via
llms.txtand docs
Improvements welcome: clearer comments, more lab programs, better docs. See CONTRIBUTING.md.
# Never commit binaries or editor backups
gcc c-programs/your_program.c -o /tmp/test && /tmp/testIf this repo helps your lab report, notes, or tool:
COA Lab — Computer Organization & Architecture lab programs.
https://github.com/jjf2009/coa-lab
Topics: computer-organization · computer-architecture · coa · 8085 · booth-algorithm · restoring-division · non-restoring-division · binary-arithmetic · microprocessor · engineering-lab
Star this repo if it saved your COA lab night — it helps other students find the right programs.