-
Notifications
You must be signed in to change notification settings - Fork 0
/
workshop.tex
659 lines (460 loc) · 13.4 KB
/
workshop.tex
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
\documentclass{beamer}
\usepackage{graphicx} % Required for inserting images
\usepackage{hyperref}
\usepackage{csquotes}
\usepackage{listings}
\title{Commodore 64 Show and Tell}
\author{Folkert van Verseveld}
\date{October 23rd 2024}
\begin{document}
\maketitle
\begin{frame}
\frametitle{Emulators!}
\begin{itemize}
\item Google `C64 online'
\begin{itemize}
\item \url{https://c64online.com/}
\item \url{https://virtualconsoles.com/online-emulators/c64/}
\end{itemize}
\item \href{https://vice-emu.sourceforge.io/index.html\#download}{Versatile Commodore Emulator}
\end{itemize}
\end{frame}
\begin{frame}
\frametitle{Contents}
\tableofcontents
\end{frame}
\section{Introduction}
\section{Coding environment}
\section{BASIC}
\section{Graphics}
\section{Music}
\section{Conclusions}
%----------------------------------------------
\begin{frame}
\frametitle{Introduction of the Personal Computer}
\begin{itemize}
\item Mini mainframe
\item `Cheap'
\item `User friendly'
\item Real PCs around 1977-1982
\end{itemize}
\end{frame}
%----------------------------------------------
\begin{frame}
\frametitle{First Personal Computers}
\begin{figure}
\includegraphics[width=0.7\linewidth]{images/appleii.jpg}
\end{figure}
\end{frame}
%----------------------------------------------
\begin{frame}
\frametitle{First Personal Computers}
\begin{figure}
\includegraphics[width=0.9\linewidth]{images/trs80.jpg}
\end{figure}
\end{frame}
%----------------------------------------------
\begin{frame}
\frametitle{First Personal Computers}
\begin{figure}
\includegraphics[width=0.75\linewidth]{images/pet.jpg}
\end{figure}
\end{frame}
%----------------------------------------------
\begin{frame}
\frametitle{First Personal Computers}
\begin{figure}
\includegraphics[width=0.85\linewidth]{images/vic20.jpg}
\end{figure}
\end{frame}
%----------------------------------------------
\begin{frame}
\frametitle{First Personal Computers}
\begin{figure}
\includegraphics[width=0.7\linewidth]{images/ibm5150.jpg}
\end{figure}
\end{frame}
%----------------------------------------------
\begin{frame}
\frametitle{First Personal Computers}
\begin{figure}
\includegraphics[width=0.85\linewidth]{images/zxspectrum.jpg}
\end{figure}
\end{frame}
%----------------------------------------------
\begin{frame}
\frametitle{Game Consoles}
\begin{figure}
\includegraphics[width=0.85\linewidth]{images/vcs.jpg}
\end{figure}
\end{frame}
%----------------------------------------------
\begin{frame}
\frametitle{Game Consoles}
\begin{figure}
\includegraphics[width=0.6\linewidth]{images/vectrex.jpg}
\end{figure}
\end{frame}
%----------------------------------------------
\begin{frame}
\frametitle{Game Consoles}
\begin{figure}
\includegraphics[width=0.85\linewidth]{images/nes.jpg}
\end{figure}
\end{frame}
%----------------------------------------------
\begin{frame}
\frametitle{Meet the most Successful PC of all time}
\begin{figure}
\includegraphics[width=0.8\linewidth]{images/desk.jpg}
\end{figure}
\end{frame}
%----------------------------------------------
\begin{frame}
\frametitle{Commodore 64}
The Guinness Book of World Records says:
\begin{displayquote}
the C64 is the best selling single computer model of all time with sales of about 30 million units between 1982 and 1993
\end{displayquote}
\end{frame}
%----------------------------------------------
%\frametitle{The Only Real One - Breadbin}
{
\usebackgroundtemplate{\includegraphics[width=\paperwidth]{images/breadbin.jpg}}
\begin{frame}[plain]
\end{frame}
}
%----------------------------------------------
\begin{frame}
\frametitle{The `C64 slim' - C64C}
\begin{figure}
\includegraphics[width=0.8\linewidth]{images/c64c.jpg}
\end{figure}
\end{frame}
%----------------------------------------------
\begin{frame}
\frametitle{Modern Version (emulator)}
\begin{figure}
\includegraphics[width=0.8\linewidth]{images/boot.png}
\end{figure}
\end{frame}
%----------------------------------------------
\begin{frame}
\frametitle{Who would even use a C64 nowadays?}
Apparently, this garage in Poland still does!
\begin{figure}
\includegraphics[width=0.8\linewidth]{images/c64c_garage.jpg}
\end{figure}
\end{frame}
%----------------------------------------------
\begin{frame}
\frametitle{What can you do on a C64?}
\begin{figure}
\includegraphics[width=0.8\linewidth]{images/performance.png}
\end{figure}
MOS 6510 CPU at 985KHz (PAL), 64KB of RAM
\end{frame}
%----------------------------------------------
{
\usebackgroundtemplate{\includegraphics[width=\paperwidth]{images/bender.jpeg}}
\begin{frame}[plain]
\end{frame}
}
%----------------------------------------------
{
\usebackgroundtemplate{\includegraphics[width=\paperwidth]{images/terminator.jpg}}
\begin{frame}[plain]
\end{frame}
}
%----------------------------------------------
\begin{frame}
\frametitle{Coding environment}
Lets see if we can get this old machine up and running!
\end{frame}
%----------------------------------------------
\begin{frame}
\frametitle{How did we write Programs back then?}
\begin{itemize}
\item No internet (BBS after some time)
\item Literature (magazines, books, \dots)
\item Mouth-to-mouth (meetings, competitions, parties, \dots)
\item `Download' programs from radio to tape!
\end{itemize}
\end{frame}
%----------------------------------------------
\begin{frame}
\frametitle{Personal Computers by Comparison}
\begin{tabular}{|l|l|l|l|l|}
\hline Year & Model & Introd. & Oct. 2024 & Now (ebay) \\ \hline
1977 & PET & \$795 & \$4136 & \$600-\$800 \\
1980 & VIC-20 & \$299.95 & \$1944 & \$60-\$260 \\
1982 & C64 & \$595 & \$1480 & \$50-\$200 \\ \hline
1977 & Apple ][ & \$1296 & \$6743 & \$60-\$250 \\
1981 & IBM PC & \$1565 & \$5428 & \$250-\$800? \\
1982 & ZX Spec. & \pounds 175 & \pounds 606 (\$653) & \$80-\$200 \\ \hline
1977 & VCS & \$199 & \$1035 & \$100-\$300 \\
1982 & Vectrex & \$199 & \$650 & \$400-\$700 \\
1983 & NES & \$179 & \$567 & \$70-\$180 \\ \hline
\end{tabular}
\end{frame}
%----------------------------------------------
\begin{frame}
\frametitle{What about storage?}
\begin{itemize}
\item No hard disk included
\item Too expensive (+\$599/+\$1957)
\item Programs in RAM, firmware in ROM
\item Power loss: program gone!
\end{itemize}
\end{frame}
%----------------------------------------------
\begin{frame}
\frametitle{Tapes}
\begin{figure}
\includegraphics[width=0.9\linewidth]{images/datasette.jpg}
\end{figure}
\end{frame}
%----------------------------------------------
\begin{frame}
\frametitle{Tapes}
\begin{itemize}
\item Sequential magnetic memory
\item 350KB-2000KB
\item Single/Double sides
\item Clumsy
\item Manually seek forward and rewind tape
\item Analog file table
\item `Let's whistle down some games!'
\end{itemize}
\end{frame}
%----------------------------------------------
\begin{frame}
\frametitle{Floppies!}
\begin{figure}
\includegraphics[width=0.85\linewidth]{images/c1541.jpg}
\end{figure}
\end{frame}
%----------------------------------------------
\begin{frame}
\frametitle{Floppies!}
\begin{itemize}
\item Real floppy
\item 5.25 inch, SD, DD
\item Single/Double sides
\item 300 RPM (5 revs/sec)
\item 178KB
\item About 2 blocks/sec (512 bytes/sec)
\end{itemize}
\end{frame}
%----------------------------------------------
\begin{frame}
\frametitle{Graphics - C64}
\begin{figure}
\includegraphics[width=0.5\linewidth]{images/palette.png}
\end{figure}
\end{frame}
%----------------------------------------------
\begin{frame}
\frametitle{Graphics Memory}
\begin{itemize}
\item 320x200 = 64,000
\item Only 65,536 - 64,000 = 1,536 bytes with bitmap
\item How do we solve this?
\end{itemize}
\end{frame}
%----------------------------------------------
\begin{frame}
\frametitle{Graphics Memory}
\begin{itemize}
\item Use 8x8 blocks
\item Text mode
\item Only 40 * 25 = 1,000 bytes
\item With 16 colors just 1,000 / 2 = 500 bytes more
\item 1,500 bytes
\end{itemize}
\end{frame}
%----------------------------------------------
\begin{frame}
\frametitle{PETSCII - Text Mode}
\begin{figure}
\includegraphics[width=0.9\linewidth]{images/gary.png}
\end{figure}
\end{frame}
%----------------------------------------------
\begin{frame}
\frametitle{Standard Bitmap}
\begin{figure}
\includegraphics[width=0.9\linewidth]{images/sbm_tuksu.png}
\end{figure}
\begin{center}
Source: Duce
\end{center}
\end{frame}
%----------------------------------------------
\begin{frame}[fragile]{Simple Graphics Program - BASIC}
\begin{lstlisting}
10 VIC=53248
20 C=PEEK(VIC+32)AND15
30 PRINT"KLEURCODE=",C
40 C=(C+3)AND15
50 POKEVIC+32,C
60 PRINT"KLEURCODE=",C
\end{lstlisting}
\end{frame}
%----------------------------------------------
\begin{frame}[fragile]{Simple Graphics Program - BASIC}
\begin{lstlisting}
10 VIC=53248
20 FORC=0TO15
20 POKEVIC+32,C
40 FORT=1TO128:NEXT
50 NEXTC
\end{lstlisting}
\end{frame}
%----------------------------------------------
\begin{frame}
\frametitle{Audio SID chip}
\begin{itemize}
\item World's first audio synthesizer on chip
\item Analog \emph{and} Digital
\item Designer received different awards
\item 6581 and 8580
\item \href{https://www.youtube.com/watch?v=1UzJUCPkCjo}{Matt Gray: Driller Loader (PWM)}
\item \href{https://www.youtube.com/watch?v=wz36JWHTk-A}{Tim Follin: Ghouls N Ghosts}
\item \href{https://www.youtube.com/watch?v=HdoHpxZJxAI}{Takahashi Tateishi: Mega Man 2 Dr Wily stage 1-2 (NES)}
\item \href{https://www.youtube.com/watch?v=JdmpyXrgnUg}{Jeroen Tel: Robocop 3 BGM1-4}
\item \href{https://www.youtube.com/watch?v=pnIiui46ggY}{Jeroen Tel \& LMan: Modern ringtone}
\end{itemize}
\end{frame}
%----------------------------------------------
\begin{frame}
\frametitle{Audio}
\begin{figure}
\includegraphics[width=0.9\linewidth]{images/adsr.png}
\end{figure}
\begin{tabular}{l|l}
Attack & Press key \\
Decay & Amplitude decays \\
Sustain & Amplitude remains constant \\
Release & `Fade-out' \\
\end{tabular}
\end{frame}
%----------------------------------------------
\begin{frame}
\frametitle{Waveforms}
\begin{figure}
\includegraphics[width=0.75\linewidth]{images/waveforms.png}
\end{figure}
\end{frame}
%----------------------------------------------
\begin{frame}
\frametitle{SID hacking - Arkanoid}
\begin{itemize}
\item Click/pop-bug in 6581
\item 4-bit PCM digital
\item \href{https://www.youtube.com/watch?v=z8kyhQC5XL8}{Martin Galway: it was my first attempt. It sounds like farts}
\item \href{https://www.youtube.com/watch?v=OfYsDQqzhk8}{Jeroen Tel: Turbo Outrun}
\end{itemize}
\begin{figure}
\includegraphics[width=0.9\linewidth]{images/farts.png}
\end{figure}
\end{frame}
%----------------------------------------------
\begin{frame}
\frametitle{Programming Contests}
\begin{itemize}
\item \url{https://www.demoparty.net/}
\item \href{https://xparty.net/}{X} (World's biggest C64 party near Eindhoven, NL)
\begin{itemize}
\item Since 1995
\item Since 2004 once per 2 years
\item This year approx. 450 visitors
\end{itemize}
\item \href{https://www.demoparty.net/revision}{Revision} (largest demoparty in the world!)
\item \dots
\end{itemize}
\end{frame}
%----------------------------------------------
{
\usebackgroundtemplate{\includegraphics[width=\paperwidth]{images/x.jpg}}
\begin{frame}[plain]
\end{frame}
}
%----------------------------------------------
\begin{frame}
\frametitle{Thank you}
Any questions, feedback or suggestions?
\end{frame}
%----------------------------------------------
\begin{frame}
\frametitle{Extra slides}
\end{frame}
%----------------------------------------------
\begin{frame}
\frametitle{CPU and Memory by Comparison}
\begin{tabular}{|l|l|l|l|l|}
\hline Model & RAM (bytes) & CPU & MHz \\ \hline
PET & 8192 & MOS 6502 & 1 \\
VIC-20 & 5120 & MOS 6502 & 1.11 \\
C64 & 65536 & MOS 6510 & 0.985 \\ \hline
Apple ][ & 4096 & MOS 6502 & 1 \\
IBM PC & 16384 & i8086 & 4.04 \\
ZX Spectrum & 16384 & Z80 & 3.5 \\ \hline
VCS & 128 & MOS 6507 & 1.19 \\
Vectrex & 1024 & MC68A09 & 1.5 \\
NES & 2048 & Ricoh 2A03 & 1.6 \\ \hline
\end{tabular}
\end{frame}
%----------------------------------------------
\begin{frame}
\frametitle{Video Hardware by Comparison}
\begin{tabular}{|l|l|l|}
\hline Model & Video & Colors \\
PET & none (CPU) & 1 \\
VIC-20 & VIC & 16 \\
C64 & VIC II & 16 \\
Apple ][ & none (CPU, TTL) & 1 or 4 \\
IBM PC & mono or CGA & 1 or 4 \\
ZX Spec. & none (CPU) & 8 \\ \hline
VCS & TIA & depends \\
Vectrex & VIA & none: brightness \\
NES & Ricoh 2C02 PPU & 52 \\ \hline
\end{tabular}
\end{frame}
%----------------------------------------------
\begin{frame}
\frametitle{Audio Hardware by Comparison}
\begin{tabular}{|l|l|l|l|}
\hline Model & Hardware & Type & Voices \\ \hline
PET & CPU PIO & 1-bit beeper & 0 \\
VIC-20 & VIC I & 8-bit digital & 4 \\
C64 & SID & A/D 8-bit synth. & 3 \\ \hline
Apple ][ & Speaker & 1-bit beeper & 0 \\
IBM PC & Speaker & 1-bit beeper & 0 \\
ZX Spectrum & AY-3-8192 & 8-bit digital & 4 \\ \hline
VCS & TIA & 5-bit digital & 2 \\
Vectrex & AY-3-8192 & 8-bit digital & 4 \\
NES & RP2A03 & 8-bit digital & 5 \\ \hline
\end{tabular}
\end{frame}
%----------------------------------------------
\begin{frame}
\frametitle{MOS 6502}
\begin{itemize}
\item Really cheap and successful
\item 6502, 6507, 6510, ricoh 2a03, \dots
\item PET, VIC-20, C64, VCS, NES, \dots
\item Embedded systems
\end{itemize}
\end{frame}
%----------------------------------------------
\begin{frame}
\frametitle{SID - Techniques}
\begin{itemize}
\item Pulse Width Modulation (PWM) - Driller
\item Ring modulation (ring mod) - Zoids
\item Various techniques - Commando
\end{itemize}
\end{frame}
%----------------------------------------------
\end{document}