Logic Machines 10
From BenningtonWiki
Monday, Thursday 10am - noon
Dickinson 238
After 30 years of dinking around with electronics it still amazes me that all computers, from the cheapest alarm clocks to the massive clusters at Google, are built from the same handful of ridiculously simple logic circuits. It's like if physics really were just protons, neutrons and electrons. The amazing thing is that it all started about seventy years ago when a twenty-one-year-old graduate student discovered a way to do these logic operations with electricity. He was thinking about telephones, but the mathematicians jumped on the discovery and combined the circuits in ways that added and remembered and became electronic computers. The history of Computing can be traced by following the increasing complexity of these circuits, layer upon layer, invention on invention. This course will follow this progression as a hands-on historical introduction to Computing. You’ll study boolean logic, learn electronics and build digital circuits, from simple logic gates to complex arithmetic units and digital memory, and perhaps ending with designing and building a custom microprocessor. The course is project-based, no pre-requisites.
Contents |
Class List
- Zack Franklin
- Benny Goldmintz
- Kjersti Jacobson
- Amelia Kaufmann
- Tambu Kudze
- Evan Marsh
- Preston Mendell
- Matt Nunes
- Ang Traficante
- Alexa Villaume
- Tim Voice
- Devin!
Outline
1. Class intro. Basic electricity
- Outline - to midterm
- Personal intros - pictures
- Take apart flashlight
- How many computers do you own?
- Electronic devices? Microprocessors inside each one? ... block diagram. "automotive microcontrollers"
2. Frankencircuit
- Assignment review: Container acquired?
- Electronics review: fundamentals. Power source, power sink.
- Take apart another flashlight.
- Power supplies. Sources of power. Light the light bulb from the flashlight.
- Wiring. Micrograbbers, alligator clips, braided wire, solid wire, extension cords, etc.
- Switches. Pushbuttons, knife switches, toggle switches, mercury switches.
- Frankencircuit. Light up a chain of LEDs.
- LEDs http://www.oksolar.com/led/led_color_chart.htm
3. Circuit fine points
- Move things into 238?
- Measure voltages at different points.
- Diagram the Frankencircuit.
- Symbols for the elements of the circuit. Power source: battery in-circuit, power plane. Wiring to components, wire joins, crossings.
- Right angles, scale, grid alignment.
- View samples.
- Review schematics that didn't get finished last class.
- Review schematic basics.
- Smaller circuit projects.
- Scare up more voltmeters, enough for one at each table.
- Basic circuit to light an LED from the 6V battery. Use voltmeters to find the right resistor. Resistor tour.
- Parallel, series. Diagram them. Power plane.
- Everyone invents a circuit with micrograbbers, LEDs, resistors, battery, combination of switches. Draw schematic for it (on separate paper, name on it). Pass it to around. Everyone builds everyone's circuits.
- Rules for using the classroom.
- Key in envelope by my office. Can take materials out. Checkout list for voltmeters, other largish items -- but better to use them in the classroom.
- Review schematics, mark up mistakes, redraw.
4. Microcontrollers
- Close reading of the Atmega8 datasheet.
- Set up MacBooks, copy datasheet
- Wiring up an Atmega8.
- Atmega pin-outs (DIP numbering basics). No breadboards yet. Blinker put together with micrograbbers. Need Blue LED, Crystal, pre-programmed Atmega8s. Perhaps have specific behaviors of outputs and we figure out what they do.
- What is digital?
- What's a microcontroller?
- Sampling of Atmega / Arduino projects.
- Another Arduino project. Still no breadboards. Inputs and a new set of behaviors based on inputs.
5. Microfrankencircuit
- Arduino chip on a breadboard. Another simple circuit using pre-programmed Atmega8s. Wire cutting, stripping.
- Power planes. Resistors. Measure Atmega output, compare to voltage drop of blue LED. Figure resistance needed for red, green.
6. Microprocessors
- 6502 assembly
- Memory maps
- Hex, binary
- Write night light, blink programs in 6502
- Reading assignments
- Look at Apple 2 schematics: http://www.kvalda.com/bennington/public/Apple%20II/docs/redbook%20schematics/Be prepared to talk about the following: Find the COMPOSITE VIDEO OUT. Study the circuit involving R6-R11, Q3. Find the oscillator (crystal, etc.). What is the freq of the crystal? Find the 6502 microprocessor (MPU). Identify the address lines. Notice how power and ground are drawn. Notice how pin numbers are arranged. Find the 8 ohm speaker. Study the circuit involving C1 (both of them!), R24, CR1, Q4, R25.
- Read down to (but not including) ADDRESSING MODES: http://nesdev.parodius.com/6502.txt
- Faggin recollections: http://www.intel4004.com/speech.htm
- http://nesdev.parodius.com/NESDoc.pdf Read section 1.5 "NES Hardware Overview", section 2 "Central Processing Unit", skip 2.4.
- 6502 floating point routines: http://www.applefritter.com/filestore2/download/6867/Apple2WozFloatingPoint.pdf
7. Logic
- AND, OR, NOT
- Implementation with transistors, tubes, relays
- Combination lock
8. Instruction Decoder
- Recognize 6502 op codes for blink program
- Memory-mapped IO logic
9. Memory
- Flip-flops
- Octal flip-flops (1 byte)
- Multiplexers
- D flip-flop with gates, relays?
10. ALU
- Half adder, full adder
- Counter
Final
You can use notes. All notes must be turned in with the Final; make sure they're together in some way (stapled, in a notebook, etc.) and labeled with your name. You must draw schematics for the projects and turn them in, they're part of the Final. You should draw them before class, and you can use them during the Final. Label the schematics with your name and the project number and name.
1. LED flashlight. Build a circuit to turn an LED on and off with a switch. Parts must include a power supply, switch (any kind), LED and appropriate resistor.
2. Microcontroller dimmer. Build a circuit to dim an LED using a microcontroller and a potentiometer. You'll must use an Atmega8 microcontroller, potentiometer, power supply, LED, resistor. Turning the pot will make the LED change brightness. It's your responsibility to have a good microcontroller with the correct program. The program is the Analog Sandbox, the last program we put on the microcontrollers.
3. Half adder. Build a circuit that implements this truth table. You can use any logic chips you want; you must bring your own schematics and any datasheets. Inputs A and B must not be floating. Connect LEDs to the outputs C and D.
A B | C D --------------- 0 0 | 0 0 0 1 | 0 1 1 0 | 0 1 1 1 | 1 0
4. 2-to-4 demultiplexer. Build a circuit that implements this truth table. You can use any logic chips you want; bring your own schematics and any datasheets. Inputs A and B must not be floating. Connect LEDs to the outputs C, D, E and F.
A B | C D E F ----------------------- 0 0 | 1 0 0 0 0 1 | 0 1 0 0 1 0 | 0 0 1 0 1 1 | 0 0 0 1
Programs
Materials
Everyone's going to need:
- ATMega168 with bootloader.
- Lots of mini grabbers.
- Breadboard.
- Breadboarding wire.
- Wire cutters, strippers.
- Small plyers.
- 9V batteries, clips.
- 16MHz crystal.
- Access to parts.
- Storage bins.
Class needs:
- Power supplies.
- Soldering irons, solder, suckers, vices.
- Bass wood, knives, cutting surfaces, hot glue guns.
- Parts in Dickinson 209. Organize shelves.
- ZIF socket for Arduino.
- USBTinyISP. [1]
Parts:
- LEDs, motors, pots, resistors, voltage regulators, push buttons (various), DIP sockets for Arduinos.
- TTL: gates, flip flops.



