home *** CD-ROM | disk | FTP | other *** search
/ ftp.pasteur.org/FAQ/ / ftp-pasteur-org-FAQ.zip / FAQ / microcontroller-faq / COP8 < prev    next >
Text File  |  1996-05-04  |  59KB  |  1,358 lines

  1. Newsgroups: comp.robotics.misc,comp.realtime,comp.arch.embedded,sci.answers,comp.answers,news.answers
  2. Path: senator-bedfellow.mit.edu!bloom-beacon.mit.edu!apollo.hp.com!lf.hp.com!news.dtc.hp.com!col.hp.com!usenet.eel.ufl.edu!spool.mu.edu!howland.reston.ans.net!newsfeed.internetmci.com!nntp-hub2.barrnet.net!nntp-hub3.barrnet.net!voder!nsc!rgetz
  3. From: rgetz@esd.nsc.com (Robin Getz)
  4. Subject: COP8 microcontroller FAQ 
  5. Message-ID: <DqML12.ALt@nsc.nsc.com>
  6. Followup-To: poster
  7. Summary: This artile is a collection of information sources on the line
  8.          of National Semiconductor Corporation's ("National's") COP8
  9.          family of 8-bit microcontrollers.
  10. Last-Modified: April 21, 1995
  11. Sender: news@nsc.nsc.com (netnews maintenance)
  12. Nntp-Posting-Host: lcc1.nsc.com
  13. Reply-To: rgetz@esd.nsc.com
  14. Organization: National Semiconductor Corporation
  15. X-Newsreader: TIN [version 1.2 PL2]
  16. Date: Mon, 29 Apr 1996 13:19:49 GMT
  17. Approved: news-answers-request@MIT.EDU
  18. Lines: 1337
  19. Xref: senator-bedfellow.mit.edu comp.robotics.misc:5763 comp.realtime:14835 comp.arch.embedded:8245 sci.answers:4286 comp.answers:18422 news.answers:70589
  20.  
  21. Archive-name: microcontroller-faq/COP8
  22. Posting-Frequency: monthly (20thish of each month)
  23. Last-modified: 20June1995
  24. URL: http://www.nsc.com/
  25.  
  26. This article is a draft collection of information sources on the line of
  27. National Semiconductor Corporation ("National") COP8 microcontrollers.
  28.  
  29. The following topics are addressed:
  30.  
  31. 0)  Changes Since Last Time
  32. 0.1)  Why should I read this?
  33.  
  34. 1)  ABOUT THIS FAQ
  35. 1.1)  Who put this FAQ together?
  36. 1.2)  How can I contribute to this list?
  37. 1.3)  What newsgroups will this FAQ be posted to?
  38. 1.4)  May I post this FAQ to my local BBS?
  39. 1.5)  Are there any FAQs pertaining to other microcontrollers?
  40.  
  41. 2)  ABOUT THE COP8
  42. 2.1)  The COP8 microcontroller
  43. 2.2)  COP8 flavors / Numbering Scheme
  44. 2.3)  COP8 chips and approximate prices (in US $)
  45. 2.4)  Advantages in implementing control applications on this
  46.       family of microcontrollers
  47. 2.5)  Techy Details
  48. 2.5.1) How fast are the parts?
  49. 2.5.2) What is the operating voltage of the devices?
  50. 2.5.3) How can I guarantee that my program will run reliably?
  51. 2.5.4) What kind of power savings features are available?
  52. 2.5.5) What about EMI?
  53. 2.5.6) Instruction Set
  54. 2.5.7) Can I hook up a LED to pins direct?
  55.  
  56. 3)  COP8 PRODUCTS
  57. 3.1)  FTP sites
  58. 3.2)  BBSs
  59. 3.3)  Free languages and development tools
  60. 3.4)  Free C compilers
  61. 3.5)  Plans for COP8-based boards
  62. 3.6)  Commercially available products
  63. 3.7)  Contacting National
  64.  
  65. 4)  COP8 DOCUMENTATION
  66. 4.1)  Periodicals
  67. 4.2)  Data Books / Application Notes
  68.  
  69.  
  70. ----------------------------------------------------------------------
  71.  
  72. 0)  Changes since Last Time
  73.  
  74.     Added a reference to coptools@esd.nsc.com (a support line for help on 
  75.     cop8 tools).
  76.  
  77.     Somebody pointed out to me the other day - Since the COP8 and the 8051
  78.     are modified harvard - they can do a load/store instruction in one
  79.     instruction cycle. A Von Neuman machine can not do that. This makes
  80.     (for memory intensive applications) a harvard machine almost 2 times
  81.     as fast as a Von Neuman running at the same speed..... 
  82.  
  83.     Maybe architecture does make a difference on a 8-bit controller....
  84.  
  85. 0.1) Why should I read this document?
  86.  
  87.     The COP8 is a pretty cool 8-bit microcontroller that has never had a
  88.     lot of exposure into the hobbiest/smaller manufactures marketplace.
  89.     I would like to change that. (& on the internet the indiviaul can do
  90.     anything!)
  91.  
  92.     In a nutshell, some of the strengths of the COP8 are:
  93.      o Efficient Instruction Set - 77% os instructions are single cycle/
  94.        single byte
  95.      o Efficient Input/Output utilization - i.e. on a 44-pin package > 80%
  96.        of this pins are devoted to I/O. Efficient pin usage facilitiates a
  97.        cleaner hardware design and smaller die size = Overall cost reduction
  98.      o Powerful Timers - i.e. processor-independent Pulse Width Modulation
  99.        (PWM) and capture capabiliy - less software and processor overhead
  100.      o Low Poer Consumption (Low Voltage / Low Current)
  101.      o Multi-Input Wake Up (MIWU) - Only COP8 offers this unique feature
  102.      o Wide range of temperature and power supply operation
  103.      o Low cost Basic Family to address low-end 8-bit applications and
  104.        feature family to address mid-to-high end 8-bit market
  105.  
  106.     And the Opposite side to the coin (have to be fair):
  107.      o Difficult (i.e. none) external memory interface
  108.      o No Multipy / Divide instructions
  109.      o Multiply / Divide hardware only offered on a couple devices
  110.      o Lack of EEPROM, and LCD (Although they are working on it)
  111.      
  112. -----------------------------------------------------------------------
  113. 1)  ABOUT THIS FAQ
  114.  
  115. 1.1)  Who put this FAQ together?
  116.  
  117.    After reading the excellent FAQs on the 8051 (Intel/Phillips) and
  118.    the 68hc11 (Motorola) put together by Russ Hersch 
  119.    <sibit@datasrv.co.il> (Nice work Russ), I decided to make a FAQ
  120.    on the COP8, National's family of 8-bit microcontrollers.
  121.  
  122.    I work for National in the Geographic Business Unit (GBU) responsible for
  123.    technical support for New Business Development (NBD), so if you want to 
  124.    call this advertising, and don't want me to continue to post this in 
  125.    the future, please email me (that doesn't mean I will stop, but you 
  126.    will get it off your chest ;-). I think that I have kept most of the 
  127.    hype out - please let me know if you think otherwise.
  128.  
  129.    This FAQ will hopefully give everyone a brief overview of why you should
  130.    have a further look at the COP8 instead of automatically picking a
  131.    HC11, or 8051. Not that they are bad parts, in fact they are better
  132.    at some things than the COP8. And COP8 is much better at some things
  133.    than the HC11 or 8051. The COP8 is a good chip, and well worth
  134.    learning and developing with. With everyone's help this FAQ should 
  135.    turn out to be a useful document.
  136.  
  137.    Because I admire Russ's FAQ's and I was too lazy to take the time to think 
  138.    up my own format, I have copied his basic format and a couple of sections 
  139.    (with his permission, of course).
  140.  
  141. 1.2)  How can I contribute to this list?
  142.  
  143.    I ask that if you have any suggestions or additions, or you would like to 
  144.    correct any of the information contained herein, please send me a note.
  145.  
  146.         My Email address is:  rgetz@esd.nsc.com
  147.         My Smail address is:
  148.               Robin Getz
  149.               National Semiconductor Corporation
  150.               MS 16-325
  151.               Santa Clara, CA, 94086
  152.               USA
  153.  
  154.    I certainly hope that those of you who know of interesting items for
  155.    the COP8 will share with everyone by contributing to this list.
  156.  
  157.    If you are a manufacturer and have an anonymous ftp site available
  158.    that supports the COP8, please let me know by Email so that I can
  159.    add it to this FAQ.
  160.  
  161.  
  162. 1.3)  What newsgroups will this FAQ be posted to?
  163.  
  164.    This FAQ will be posted to the following newsgroups:
  165.          comp.realtime       Issues related to real-time computing.
  166.          comp.robotics       All aspects of robots and their applications.
  167.          sci.electronics     Circuits, theory, electrons and discussions.
  168.          comp.arch.embedded  Embedded computer systems topics.
  169.  
  170.    And sometime later, depending on what people think....
  171.          news.answers
  172.          comp.answers
  173.          sci.answers
  174.  
  175.    The first four newsgroups often contain discussions, announcements,
  176.    or information on microcontrollers.  Check them out from time to 
  177.    time. By posting to the *.answers newsgroups, the FAQ will 
  178.    automatically be archived.  The archive name of this FAQ (also 
  179.    included in the header) is: cop8-microcontroller-faq.
  180.  
  181.    Items will be posted once a month.  I can't promise that
  182.    it will be on time, but I hope to post it on the 25th of each month.
  183.  
  184.    You may also want to check out the following newsgroups, since they
  185.    occasionally have items of interest for COP8 users.
  186.          comp.lang.misc
  187.          alt.comp.hardware.homebuilt
  188.  
  189.  
  190. 1.4)  May I post this FAQ to my local BBS?
  191.  
  192.    I am putting no restrictions on the use of this FAQ except - It must
  193.    be distributed in its entirety with the copyright notice, and no
  194.    financial gain may be realized from it.  After all, I have spent, and
  195.    continue to spend, a lot of time on this, and the only thing that I
  196.    intend to gain from it is more information on the COP8, and getting
  197.    to know my fellow COP8 groupies better.
  198.  
  199.    For this reason I have appended a copyright statement to the end of
  200.    this FAQ.  I feel pretty silly doing this, but I just want to protect
  201.    myself.  The copyright does not limit the use of this list for 
  202.    non-commercial purposes.  I hereby give my permission to one and all
  203.    to pass this list around and post it wherever you want - as long as
  204.    it is not for financial gain.
  205.  
  206.        Thanks.
  207.  
  208.  
  209. 1.5)  How about FAQs on other microcontrollers?
  210.  
  211.    If anyone wishes to start a FAQ on another microcontroller, please
  212.    feel free to copy the format of this FAQ (I did).  With a common 
  213.    format, we will all benefit when trying to find information on a 
  214.    particular microcontroller.  If anyone has any comments on the format
  215.    itself, I'm open for suggestions.
  216.  
  217.    Other Microcontroller FAQs
  218.  
  219.      Subject:  68hc11 microcontrollers
  220.      Newsgroups:  comp.realtime
  221.                   comp.robotics
  222.                   sci.electronics
  223.      Archive:  rtfm.mit.edu :  <plus all mirror sites>
  224.                /pub/usenet/comp.answers/microcontroller-faq/68hc11
  225.                /pub/usenet/sci.answers/microcontroller-faq/68hc11
  226.                /pub/usenet/news.answers/microcontroller-faq/68hc11
  227.      Maintainer:  Russ Hersch
  228.                   Email:  sibit@datasrv.co.il
  229.  
  230.      Subject:  PIC microcontrollers
  231.      Newsgroups:  comp.realtime
  232.                   comp.robotics
  233.                   sci.electronics
  234.      Maintainer:  Tom Kellett
  235.                   Tom@takdsign.demon.co.uk
  236.  
  237.      Subject:  8051 microcontrollers
  238.      Newsgroups:  comp.sys.intel
  239.                   comp.realtime
  240.                   comp.robotics
  241.                   comp.lang.forth
  242.                   sci.electronics
  243.      Archive:  rtfm.mit.edu :  <plus all mirror sites>
  244.                /pub/usenet/comp.answers/microcontroller-faq/8051
  245.                /pub/usenet/sci.answers/microcontroller-faq/8051
  246.                /pub/usenet/news.answers/microcontroller-faq/8051
  247.      Maintainer:  Russ Hersch
  248.                   Email:  sibit@datasrv.co.il
  249.  
  250.      Subject:  Microcontroller primer and FAQ
  251.      Newsgroups:  comp.sys.intel
  252.                   comp.realtime
  253.                   comp.robotics
  254.                   sci.electronics
  255.                   alt.comp.hardware.homebuilt
  256.      Archive:  rtfm.mit.edu :  <plus all mirror sites>
  257.                /pub/usenet/comp.answers/microcontroller-faq/primer
  258.                /pub/usenet/sci.answers/microcontroller-faq/primer
  259.                /pub/usenet/news.answers/microcontroller-faq/primer
  260.      Maintainer:  Russ Hersch
  261.                   Email:  sibit@datasrv.co.il
  262.  
  263.    Additional FAQs of interest
  264.  
  265.      Subject:  Robotics
  266.      Newsgroups:  comp.robotics
  267.      Maintainer:  Kevin Dowling
  268.                   Email:  nivek@ri.cmu.edu
  269.  
  270.      Subject:  Electronics
  271.      Newsgroups:  sci.electronics
  272.      Maintainer:  Filip Gieszczykiewicz
  273.                   Email:  filip@smi.med.pitt.edu
  274.  
  275.      Subject:  Real-time
  276.      Newsgroups:  comp.realtime, comp.answers, news.answers
  277.      Archive:  rtfm.mit.edu : pub/usenet/comp.realtime
  278.      Maintainer:  Mark Linimon
  279.                   Email:  linimon@nominil.lonesome.com
  280.  
  281.      Subject:  Neural Networks
  282.      Newsgroups:  comp.ai.neural-nets,comp.answers,news.answers
  283.      Archive:  rtfm.mit.edu : pub/usenet/neural-net-faq
  284.      URL:  http://wwwipd.ira.uka.de/~prechelt/FAQ/neural-net-faq.html
  285.      Maintainer:  Lutz Prechelt
  286.                   Email:  prechelt@ira.uka.de
  287.  
  288.      Subject:  Fuzzy Logic
  289.      Newsgroups:  comp.ai.fuzzy,comp.answers,news.answers
  290.      Archive:  rtfm.mit.edu : pub/usenet/fuzzy-logic/
  291.      URL:  http://www.cs.cmu.edu:8001/Web/Groups/AI/html/faqs
  292.              /ai/fuzzy/part1/faq.html (should be one line)
  293.      Maintainer:  Mark Kantrowitz
  294.                   Email:  mkant+@cs.cmu.edu 
  295.  
  296.    Other useful articles are also available.  One article provides a
  297.    tabular cross reference of features and pin counts. This lists was
  298.    compiled and is being maintained by Roger Nelson
  299.    <rnelson@wsuaix.csc.wsu.edu>.
  300.  
  301.    For more information on various microcontrollers and their features,
  302.    refer to the Microcontroller primer and FAQ listed above. URL:
  303.    ftp://rtfm.mit.edu/pub/usenet/comp.answers/microcontroller-faq/primer
  304.  
  305. ----------------------------------------------------------------------
  306.  
  307. 2)  ABOUT THE COP8
  308.  
  309.  
  310. 2.1)  The COP8 microcontroller
  311.  
  312.    General
  313.  
  314.    Firstly - COP8 (Control Orientated Processor) actually stands for 
  315.    something. (Although the rest of the numbering scheme leaves something 
  316.    to be desired). This is not a failed microprocessor that was cut down for 
  317.    8-bit control (like some others). This is a full featured microcontroller 
  318.    designed for bit level control. (Although National does make a 32-bit 
  319.    processor (32000), the COP8 has nothing to do with it).
  320.  
  321.    The COP8 is a powerful 8-bit data, 15-bit address (32K max ROM)
  322.    microcontroller from National with an instruction set that is 
  323.    similar (somewhat) to the 8051, although it is much easier for
  324.    the beginner to understand and pick up (In my unbasised opinion
  325.    of course :)
  326.  
  327.    Depending on the variety, the COP8 has built-in EEPROM/OTPROM, RAM,
  328.    digital I/O, timers, A/D converter, PWM generator, and synchronous
  329.    and asynchronous communications channels (RS232 and MICROWIRE/PLUS).
  330.    Typical current draw is less than 12ma, with powerdown modes that 
  331.    can reduce current draw to typically less than 1 uA. (Although I 
  332.    have seen ***50nA***)
  333.  
  334.    A typical COP8 contains:
  335.       - CPU with Boolean processor
  336.       - fully static processor
  337.       -  up to vectored 14 interrupts: 2 are external (8 pins can 
  338.           be ORed into one interrupt, for a total of 9 external)
  339.           - arbitration levels
  340.       - 1,2 or 3 16-bit timer/counters (min 1 max 3)
  341.       - programmable full-duplex serial port (UART/USART or 
  342.           MICROWIRE/PLUS)
  343.       - up to 56 I/O lines (11 pins min + Vcc/GND/Reset/CKI/CKO)
  344.       - up to 512 bytes RAM (64 bytes min)
  345.       - up to 16K ROM/EPROM in some models (768 bytes min)
  346.       - new parts are LOW EMI (typically lower than 14dB emissions)
  347.  
  348.    The COP8 peripherals are POWERFUL. The timer that you will find on 
  349.    a COP8 is much more powerful than on a typical microcontroller.
  350.    I will get into this a little later.
  351.  
  352.    The COP8 instruction set is optimized for the one-bit operations so
  353.    often desired in real-world, real-time control applications.  The
  354.    Boolean processor provides direct support for bit manipulation.  This
  355.    leads to more efficient programs that need to deal with binary input
  356.    and output conditions inherent in digital-control problems.  Bit
  357.    addressing can be used for test pin monitoring or program control
  358.    flags.
  359.  
  360.     Architecture
  361.  
  362.     The COP8 is a modified Harvard architecture. With the Harvard 
  363.     architecture, the ROM is separated from the data memory (RAM). Both 
  364.     ROM and RAM have their own separate addressing space with separate 
  365.     address busses (there are two 0 addresses - 1 for ROM, 1 for RAM). The
  366.     COP8, though based on the Harvard Architecture, permits transfers from
  367.     ROM to RAM (hence modified).
  368.  
  369.     The CPU has an 8-bit accumulator (A) that all arithmetic operations go 
  370.     into. Two 8-bit index registers are present (X, B) to provide indexing 
  371.     to anywhere in the memory map. Having the two index registers means the 
  372.     COP8 is very good for processing data.  Although an 8-bit processor, the 
  373.     COP8 has some 16 bit (and bigger) peripherals (timers, 24 by 8 divide, 
  374.     16 by 8 multiply, 16-bit A/D). An 8 bit stack pointer is also present, 
  375.     and instructions are provided for stack manipulation.
  376.  
  377.     Feature Family / Basic Family
  378.  
  379.     The COP8 family is divided into two families - the Basic Family and 
  380.     the Feature Family. There is little difference between the devices 
  381.     although the feature family has the following advantages:
  382.       - 7 more instructions (including PUSH and POP)
  383.       - 2 auto-reload registers on timers / Basic family only has one
  384.       - IDLE Mode (Basic family only offers HALT mode)
  385.       - powerful peripherals ( A/D, UART, high speed timers, WatchDog,
  386.         comparators, etc. )
  387.  
  388.     Onboard subsystems
  389.  
  390.     Timer -  Main timer system comprises of a single 16-bit counter
  391.     (2 x 8-bit registers) clocked at tc (1MHz at Crystal frequency of 
  392.     10MHz). Timers have at least one associated register and all Feature 
  393.     Family devices have 2 registers. All timers have at least 1uSec 
  394.     accuracy and some have 100nS - check datasheet for specific details.
  395.     Timers can be configured in the following methods:
  396.        - External Counter (clocked on positive or negative edge)
  397.        - Timer w/ Auto-Load Register (PWM output)
  398.        - Timer with Capture (triggered on positive or negative edge)
  399.  
  400.     Pulse Stream Generators - Some of the devices have specific timers
  401.     that are 100ns resolution 16-bit PWM (Pulse Width Modulation) outputs 
  402.     only.
  403.  
  404.     Multi-Input Wakeup -The Multi-Input WakeUp (MIWU)  is used to return
  405.     (wakeup) the microcontroller from either HALT or IDLE modes. 
  406.     Alternately MIWU may also be used to generate up to 8 edge 
  407.     selectable external interrupts.  The user can select whether the 
  408.     trigger condition on the pins is going to be either a positive edge 
  409.     (low to high) or a negative edge (high to low).
  410.  
  411.     A-D Converters - 8-bit, 8-channel (multiplexed input) SAR 
  412.     (Successive Approximation Register). Two dedicated pins Vref and 
  413.     Agnd are provided for voltage reference. The time required for an 
  414.     A/D conversion is dependent on the prescaler (fast conversion = more
  415.     power consumed - you can run the microcontroller fast - and the A/D 
  416.     slow). The A/D converter has the following different modes of 
  417.     operation:
  418.       - One channel conversion then stop
  419.       - Any specific channel to be scanned continuously
  420.       - Any differential channel pair measurement and then stop
  421.       - Any differential channel pair be scanned continuously
  422.  
  423.     It also has a device that supports single slope A/D - the device 
  424.     contains a constant current source, a comparator, an analog 
  425.     mutliplexer, and a couple of 16-bit timers. These can be configured to
  426.     give the designer a 16-bit (resolution - not accuracy) A/D converter.
  427.  
  428.     UART / USART - Asynchronous or synchronous serial communication block.
  429.     Clock generation (for asynchronous operation) is very sophisticated - 
  430.     standard baud rates (300,1200,2400,4800,9600,19200,38400) can be generated
  431.     without having to select some obscure crystal frequency (Run the 
  432.     controller at full speed). Synchronous operations occur at 16 x the speed 
  433.     of asynchronous. Framing formats supported are: 1 Start, 7,8 or 9 data, 
  434.     Parity/No Parity, 1 or 2 stop. The Attention Mode (or Network Mode) is 
  435.     also supported, whereby a single master / multi-slave environment is set 
  436.     up. This is a *very* powerful feature that can be used almost anywhere 
  437.     when you need to talk to more than one controller / CPU. Diagnostic 
  438.     mode is also enhanced from a regular UART. Internally, the Transmit 
  439.     Shift Register is "looped back" into the Receive Shift Register. 
  440.     Externally the receiver input pin (RDX) is connected to the 
  441.     transmitter output pin(TDX). This allows the external UART to do a 
  442.     continuity check of the external lines.
  443.  
  444.     MICROWIRE/PLUS - A Synchronous serial communications port, comprised 
  445.     of Serial Clock (SK), Serial Data In (SI), Serial Data Out (SO) and 
  446.     optional chip selects.  There are many specific MICROWIRE, MICROWIRE/PLUS 
  447.     and SPI devices, (the only difference between SPI and MICROWIRE is 
  448.     when the data is shifted in - and with MICROWIRE/PLUS - you control that) 
  449.     such as A/Ds, D/As, EPROM, FLASH, EEPROM, MUX's.....
  450.  
  451.     Comparator - A differential comparator, with a pair of inputs (positive 
  452.     and negative) and an output. The comparator can be software disabled (to 
  453.     save power). The output can either be brought outside (via a pin) or left 
  454.     as a bit somewhere inside the controller.
  455.  
  456.     BrownOut - BrownOut protection is usually an on-board protection circuit 
  457.     that resets the device when the operating voltage (Vcc) is lower than the 
  458.     Brownout voltage.  The device is held in reset and will remain in reset 
  459.     when Vcc stays below the Brownout voltage. The device will resume 
  460.     execution (from reset) after Vcc has risen above the BrownOut Voltage.
  461.  
  462.     CAN - The COP8 supports applications which require a low speed CAN 
  463.     interface. The interface is compatible with CAN Specification 2.0 part B,
  464.     without the capability to receive/transmit extended frames. However, 
  465.     extended frames on the bus are checked and acknowledged according to the 
  466.     CAN specification. The maximum bus speed achievable with the CAN interface
  467.     is a function of crystal frequency, message length and software overhead. 
  468.     The device can support a bus speed of up to 1 Mbit/s with a 10MHz 
  469.     oscillator and 2 byte messages.
  470.  
  471.     Hardware Multiply / Divide - This block supports a 1 byte x 2 bytes
  472.     (3 byte result) multiply operation (in one instruction cycle - 1uS) or a
  473.     3 byte x 2 byte (2 byte result) divide operation (in two instruction 
  474.     cycles - 2uS). There are no multiplication errors that can occur ( FFh x
  475.     FF FFh = FE FF 01h which fits in three bytes). Divide errors are trapped
  476.     (overflow FF FF FFh / 1h = FF FF FFh which is bigger than two bytes and
  477.     division by zero)
  478.  
  479. 2.2)  COP8 flavors / Numbering Scheme
  480.  
  481.     All devices include at least one 16-bit timer, MICROWIRE/PLUS serial
  482.     interface, common pinouts, common instruction set and most are 
  483.     available in ...
  484.  
  485.     Basic Family Numbering Scheme
  486.  
  487.     COP8720CJ-XXX/N
  488.     ^^^^^^^^^ ^^^ ^ 
  489.        |||||| ||| \-- Package Type : N  - DIP
  490.        |||||| |||                  : WM - Surface Mount
  491.        |||||| |||                  : V  - PLCC
  492.        |||||| |||                  : J  - DIP Windowed
  493.        |||||| |||
  494.        |||||| \\\---- Unique ROM id Code assigned by National
  495.        ||||||         NOTE: OTP and windowed parts do not have
  496.        ||||||               this code
  497.        ||||||
  498.        ||||\\-------- Features : CJ - Brown-out,high speed timers,
  499.        ||||                            comparators,MIWU
  500.        ||||                      C  - 16-bit timer 
  501.        ||||
  502.        |||\---------- Number of pins : 0 - 28/40/44 (depends on package)
  503.        |||                           : 1 - 28
  504.        |||                           : 2 - 20
  505.        |||                           : 3 - 16
  506.        |||                           : 8 - Indicates Feature Family 
  507.        |||                           : 5 - Indicates Feature Family 
  508.        |||                           : 4 - Indicates Feature Family 
  509.        |||
  510.        ||\------------ ROM/RAM : 2 - 1k ROM / 64 btyes RAM 
  511.        ||                      : 4 - 2k ROM / 128 bytes RAM
  512.        ||                      : 8 - 4k ROM / 128 bytes RAM
  513.        ||
  514.        |\------------- If 7 is there indicates Programmability (EPROM)
  515.        |               If 6 is there indicates EEPROM for RAM
  516.        |               If nothing indicates ROM device with volatile RAM
  517.        |
  518.        \-------------- Temp range : 6 - Military (-55C to +125C)
  519.                                     8 - Industrial (-40C to +85C)
  520.                                     9 - Commercial (0C to +70C)
  521.  
  522.     Feature Family Numbering Scheme
  523.  
  524.     COP8788EG-XXX/N-R
  525.     ^^^^^ ^^^ ^^^ ^ \ - OTP Oscillator Option: R - RC
  526.        || ||| ||| |                            X - Crystal
  527.        || ||| ||| |
  528.        || ||| ||| \-- Package Type : N  - DIP
  529.        || ||| |||                  : WM - Surface Mount
  530.        || ||| |||                  : V  - PLCC
  531.        || ||| |||                  : J  - DIP Windowed
  532.        || ||| |||
  533.        || ||| \\\---- Unique ROM id Code assigned by National
  534.        || |||         NOTE: OTP and windowed parts do not have
  535.        || |||               this code
  536.        || |||
  537.        || ||\-------- Features : F - 2 timers, 8-bit, 8-channel ADC
  538.        || ||                     G - 3 timers, 2 comparators, UART
  539.        || ||                     C - 1 timer, CAN, 2 comparators
  540.        || ||                     S - 1 timer, 1 comparator, UART
  541.        || ||                     L - 2 timers
  542.        || ||                     K - 1 time, Analog block, 1 comparator
  543.        || ||                     W - 2 timers, 4 Pulse Stream Generators
  544.        || ||                         Hardware Multiply divide
  545.        || ||
  546.        || |\--------- ROM/RAM : B - 2k ROM  /  64 RAM
  547.        || |                     C - 4k ROM  / 128 RAM
  548.        || |                     E - 8k ROM  / 256 RAM
  549.        || |                     G - 16k ROM / 512 RAM
  550.        || |
  551.        || \---------- Number of pins : 8 - 40/44 (depends on package)
  552.        ||                            : 5 - 20
  553.        ||                            : 4 - 28
  554.        ||                            : 2 - Indicates Basic Family device
  555.        ||                            : 1 - Indicates Basic Family device
  556.        ||                            : 0 - Indicates Basic Family device
  557.        ||
  558.        |\------------- If 7 is there indicates Programmability (EPROM)
  559.        |               If 6 is there indicates EEPROM for RAM
  560.        |               If nothing indicates ROM device with volatile RAM
  561.        |
  562.        \-------------- Temp range : 6 - Military (-55C to +125C)
  563.                                     8 - Industrial (-40C to +85C)
  564.                                     9 - Commercial (0C to +70C)
  565.  
  566. 2.3)  COP8 chips and approximate prices (in US $)
  567.  
  568.    I am affiliated with the manufacturer of these devices, & you will most 
  569.    likely be purchasing parts from a distributor. If I was to list prices,
  570.    some people would think that was pricing fixing - so I can't (& won't).
  571.  
  572.    The below prices are subject to lots of things, where you live (prices 
  573.    vary by region), package type (DIP, SO, PLCC), Temperature range 
  574.    (Commerical, Industrial, Military) and volume. Contact your favorite
  575.    National Distributor for more info.
  576.  
  577.    OTPs
  578.    -----------
  579.    Basic Family      |ROM|RAM|DI|  |PL|TI|CO|UA|MI|WD|Other
  580.    Device    | 5000  |   |   |P |SO|CC|ME|MP|RT|WU|OG|
  581.    COP8780   | 3.25  | 4k|128|40|  |44| 1|  |  |  |  |
  582.    COP8781   | 2.55  | 4k|128|28|28|  | 1|  |  |  |  |
  583.    COP8782   | 2.30  | 4k|128|20|20|  | 1|  |  |  |  |
  584.    COP8720CJ | 4.00  | 1k| 64|28|28|  | 2| 1|  | Y| Y|
  585.    COP8722CJ | 3.50  | 1k| 64|20|20|  | 2| 1|  | Y| Y|
  586.    COP8740CJ | 5.25  | 2k|128|28|28|  | 2| 1|  | Y| Y|
  587.    COP8742CJ | 4.40  | 2k|128|20|20|  | 2| 1|  | Y| Y|
  588.  
  589.    Feature Family
  590.    COP8784BC | 7.90  | 2k| 64|28|28|  | 2| 2|  | Y|  |CAN, Power-On-Reset
  591.    COP8788CF | 7.65  | 4k|128|40|  |44| 2|  |  | Y| Y|8-bit 8-chan
  592.    COP8784CF | 7.40  | 4k|128|28|28|  | 2|  |  | Y| Y|A/D
  593.    COP8788EG | 7.85  | 8k|256|40|  |44| 3| 2| 1| Y| Y|
  594.    COP8784EG | 7.60  | 8k|256|28|28|  | 3| 2| 1| Y| Y|
  595.    COP8788CL | 6.70  | 4k|128|40|  |44| 2|  |  | Y| Y|
  596.    COP8784CL | 6.45  | 4k|128|28|28|  | 2|  |  | Y| Y|
  597.    COP8788EK | 9.40  | 8k|256|40|  |44| 3| 1|  | Y| Y|Analog fncts
  598.    COP8784EK | 9.10  | 8k|256|28|28|  | 3| 1|  | Y| Y|(16-bit A/D)
  599.  
  600.  
  601.    Otherwise you can call Future Active Industrial @ 800-723-5817. They do
  602.    stock parts on the shelf, and should be able to ship within a day or
  603.    two. To find you favorite local distributor, please call National, and
  604.    I am sure that we should be able to tell you.
  605.  
  606.    ROMmed - Check with your local National Distributor.
  607.  
  608. 2.4)  Advantages in implementing control applications on this
  609.      family of microcontrollers
  610.  
  611.    Traditional architecture - Modified Harvard (separate RAM and ROM busses) 
  612.    leads to an easy to learn device as well as speeding the device up. As your
  613.    first microcontroller, this is very well suited to learning.
  614.  
  615.    More features - a COP8 is typically a "one-chip" solution since it always
  616.    includes such items as serial I/O, PWM, and many I/O lines, and typically 
  617.    includes on board A/D, UARTs, and many timers.
  618.  
  619.    Fast and effective - the architecture correlates closely with the problem 
  620.    being solved (control systems). Specialized instructions mean that fewer 
  621.    bytes of code need to be fetched and fewer conditional jumps are processed.
  622.    (77% on instructions are single byte/single cycle - this means smaller and 
  623.    faster code).
  624.  
  625.    Low cost - high level of system integration within one component, only a 
  626.    handful of components needed to create a working system.
  627.  
  628. 2.5) Techy Details
  629.  
  630.    Not all of the below features are on all of the devices (check the 
  631.    datasheet):
  632.  
  633. 2.5.1) How fast are the parts?
  634.  
  635.    The COP8 has a max Clock input (CKI) of 10MHz. Since the parts have a 
  636.    divide by 10 internal clock, the instruction cycle time (tc) is 1Mhz
  637.    or 1us. Most internal devices are fed with tc. The UART is fed by tc 
  638.    through a very complex divide and prescaler, which allows any standard 
  639.    baud rate to be generated with almost any tc. (i.e. Get the baud rate 
  640.    you want without having to purchase that 9.8746856MHz crystal!) Some 
  641.    timers are fed with CKI, giving a PWM output with **100ns** resolution.
  642.    Hardware multiply/divide are fed with CKI allowing a 3 byte by 2 byte 
  643.    multiply to be completed in 1us, and a 3 byte by 2 byte divide completing
  644.    in 2us.
  645.  
  646.    The parts are also fast because most of the instructions execute in one
  647.    tc. (1us).
  648.  
  649. 2.5.2) What is the operating voltage of the devices?
  650.  
  651.     The operating voltage of most of the ROMmed devices is between 2.3 <-> 
  652.     6.0V
  653.  
  654.     The operating voltage of most of the OTP's is between 4.5 <-> 5.5V. A low
  655.     voltage (2ishV) OTP is expected within 12 months. 
  656.  
  657. 2.5.3) How can I guarantee that my program will run reliably?
  658.  
  659.    You can't.
  660.  
  661.    Not COP8, nor any other microcontroller is guaranteed to operate when a 
  662.    10MegaWatt Radar wave is passing through it.  EMI can cause any 
  663.    microcontroller to do *VERY* funny things. What your microcontroller can 
  664.    do is provide a couple features to ensure that the application realizes
  665.    that funny things have gone on.
  666.  
  667.    The COP8 provides 3 methods of trapping these types of events.
  668.    NOTE: these events are just as likely to happen on a HC11, 8051,
  669.    PIC, ect . . . COP8 just traps them.
  670.  
  671.    SOFTWARE TRAP - since the Program Counter (PC) is 15 bits in length
  672.    (Max theoretical ROM space of 32K) and the biggest part we make (currently)
  673.    is a 16K part (and most smaller) there is a possibility that the PC could
  674.    point to ROM that does not physically exist.  This will be trapped within 
  675.    one tc (instruction cycle) and cause an interrupt to occur. The interrupt 
  676.    will reload the PC with a known value (0x00FF) and go to that value.  A 
  677.    Software Trap is the only non-maskible interrupt on the COP8. This can also
  678.    be valuable when your program takes 4097 bytes (As most programs do) and
  679.    you have to use a part with an 8K ROM. The upper 4095 bytes of ROM are 
  680.    physically there, but unused. If the PC does the funky chicken and points
  681.    to those ROM locations, is this trapped? (Well - I wouldn't ask the 
  682.    question if I didn't have the answer). Yes, this can be trapped. The 
  683.    best method of doing this is to load all unused ROM locations with 0x00.
  684.    (Software Trap is simple a 00 OpCode). Since this is an interrupt, your
  685.    interrupt handler can do anything it wants. (i.e. re-initialize the device)
  686.  
  687.    WATCHDOG - In a well thought out program this works wonderfully.  The
  688.    software designer knows exactly how long program execution takes, and
  689.    services a timer every so often.  This time frame (the amount of time
  690.    you have to service the timer) is software selectable between 2k->8k,
  691.    2k->16k, 2k->32k or 2k->64k tc. This means there is two ways to have 
  692.    the watchdog time out - either servicing the clock too fast (more
  693.    than once every 2k tc) or too slow (having more than one selectable
  694.    go by). This is actually very powerful - if your "bug" is in your 
  695.    routine that services the watchdog, you will still find out - on most
  696.    other microcontrollers this is not true.
  697.  
  698.    When a Watchdog becomes active, nothing happens internally in the device 
  699.    with the exception of on pin going low. This is because if you are 
  700.    controlling a huge metal lathe with your COP8, and you have a watchdog, it 
  701.    is a bad thing. If you reset the part, you continue on business as usual. 
  702.    A Watchdog is a catastrophic failure. Maybe you want to turn off your 
  703.    lathe, and sound an alarm that the lathe needs servicing. 
  704.  
  705.    This all seems well, but what happens in my real-time controller when my
  706.    crystal starts to fail?  My real-time stops being very real time. (This is 
  707.    another one of those questions that I better have an answer for.)
  708.  
  709.    CLOCK MONITOR - This is guaranteed not to reject the clock if the 
  710.    instruction cycle clock (1/tc) is greater than 10kHz. This equates to
  711.    a clock input rate (CKI) of greater than or equal to 100kHz. Again 
  712.    this simply brings a pin (/RESET) low on the part - and nothing else.
  713.    This is software selectable (You can turn it off if you want to run 
  714.    the parts slower than 100kHz.)
  715.  
  716. 2.5.4) What kind of power savings features do you have?
  717.  
  718.     The device can be placed into IDLE/HALT mode by software control.
  719.     In both Halt and Idle conditions the state of the microcontroller
  720.     remains.  RAM is not cleared and any outputs are not changed.
  721.  
  722.     HALT - 
  723.      In Halt mode, all activities are stopped (including timers and
  724.      counters).  The only way to wake up is by a reset or device
  725.      interrupt (such as an I/O port).  The power requirements of the
  726.      device are minimal and the applied voltage (Vcc) can sometimes be
  727.      decreased below operating voltage without altering the state
  728.      (RAM/Outputs) of the device.  Current consumption is typically
  729.      less than 1 uA.
  730.  
  731.      A common application of HALT mode is in laptop keyboards.  In
  732.      order to have maximum power saving, the controller is in halt
  733.      until it detects a keystroke (via a device interrupt).  It then
  734.      wakes up, decodes and sends the keystroke to the host, and then
  735.      goes back into halt mode, waiting either for another keystroke, 
  736.      or information from the host.
  737.  
  738.      The disadvantage of HALT mode is that since *ALL* activities are
  739.      stopped (including your crystal oscillator) it takes some time 
  740.      before your oscillator will start going again - sometimes this can 
  741.      be in the range of 12 - 100mS (that's milli, not micro). In some 
  742.      applications this is a bad thing - and you want to wake up faster.
  743.      (NOTE: this is a function of the oscillator design, not the 
  744.      microcontroller.)
  745.  
  746.    IDLE - 
  747.      In IDLE mode, all activities are stopped except:
  748.          - associated on-board oscillator circuitry
  749.          - watchdog logic (if any)
  750.          - the clock monitor
  751.          - the idle timer (a free running timer)
  752.      Power supply requirements on the microcontroller in this mode are
  753.      typically around 30% of normal power requirements of the
  754.      microprocessor.  Idle mode is exited by a reset, or some other
  755.      stimulus (such as timer interrupt, serial port, etc.).  A special
  756.      timer/counter (the idle timer) causes the chip to wake up at a
  757.      regular interval to check if things are OK.  The chip then goes
  758.      back to sleep.
  759.  
  760.      IDLE mode is extremely useful for remote, unattended data logging
  761.      - the microprocessor wakes up at regular intervals, takes its
  762.      measurements, logs the data, and then goes back to sleep.
  763.  
  764.      Since the crystal is still going during IDLE mode, the time that it
  765.      takes to get going again is two tc (2 uSec) - but the trade off is 
  766.      more power consumption.
  767.  
  768.  
  769. 2.5.5) What about EMI?
  770.  
  771.     The control and minimization of Electro-Magnetic Interference (EMI)
  772.     is a technology that is, out of necessity, growing rapidly. EMI will
  773.     be defined shortly but, for now, you might be more familiar with the 
  774.     terms Radio Noise, Electrical Noise, or Radio Frequency 
  775.     Interference (RFI). The technology's exploration includes a wide
  776.     frequency spectrum, from dc to 40GHz. It also deals with 
  777.     susceptibility to EMI as well as the emissions of EMI by equipment
  778.     or components. Emissions corresponds to that potential EMi which
  779.     comes out of a piece of equipment or component. Susceptibility, on
  780.     the other hand, is that which couples from the outside to the 
  781.     inside.
  782.  
  783.     In COP8 designs to date, we have looked at noise situations ranging 
  784.     from 1MHz to 200MHz. EMI, in some cases, can affect radio reception,
  785.     TV reception, accuracy of navigation equipment, etc. In severe 
  786.     cases, EMI might even affect medical equipment, radar equipment
  787.     and automotive systems.
  788.  
  789.     EMI is a form of electrical-noise pollution. Think of the time 
  790.     when an electric drill or some other power tool jammed a nearby
  791.     radio with buzzing or crackling noises. This is annoying - but not
  792.     catastrophic. This is much different than when aircraft navigation 
  793.     errors occur from EMI Interruption of air traffic controller
  794.     service or maybe even computer memory loss due to noise could
  795.     cause two aircraft to collide resulting in the loss of lives and
  796.     property.
  797.  
  798.     The ultimate question is - What is National doing to reduce EMI
  799.     emissions on it's COP8? Well, the answer is...LOTS.
  800.  
  801.     Gradual Turn-On Outputs - The outputs and bi-direction ports (except
  802.     pin G7, CKO) use gradual turn on (GTO) output drives. These drivers 
  803.     generate less EMI than standard drives by having slower turn-on time
  804.     and thereby reducing the peak instantaneous current. They have 
  805.     slightly longer propagation delay than standard drivers.
  806.  
  807.     Idd CHOKE - The rate of change (di/dt) of Idd to the chip nucleus is
  808.     controlled through the use of a Idd choke block. This block actively
  809.     reduces current transients reaching the supply and thus reduces the
  810.     H field emissions from the system.
  811.  
  812.     Level shifters are required for all I/O Port pins to ensure that the
  813.     switching is consistent and to ensure that the resultant changes in
  814.     the internal Vcc are not coupled to the port pins.
  815.  
  816.     The oscillator uses a separate power supply filter to minimize the 
  817.     direct coupling of the oscillator frequency to the supply.
  818.  
  819.     Low EMI Logic - In order to further reduce EMI, the logic in the
  820.     chip is disabled when inactive (by disabling the clocks). This 
  821.     will reduce switching and hence current consumption and EMI.
  822.  
  823.     Not all devices have the above described EMI enhancements - *only*
  824.     the newer devices. National holds 11 patents on EMI reducing 
  825.     technology that is incorporated in the COP8.
  826.  
  827.  
  828. 2.5.6) Instruction Set
  829.  
  830.     The strength of the instruction set is based on the following 
  831.     features:
  832.      o Mostly single-byte opcode instructions minimize program size.
  833.      o One instruction cycle for the majority of single-byte 
  834.        instructions to minimize program execution time.
  835.      o Many single-byte, multiple function instructions such as DRSZ 
  836.        (Decrement Register and Skip if Zero).
  837.      o Three memory mapped pointers: two for register indirect 
  838.        addressing, and one for the software stack.
  839.      o Sixteen memory mapped registers that allow an optimized 
  840.        implementation of certain instructions.
  841.      o Ability to set, reset, and test any individual bit in data memory
  842.        address space, including the memory-mapped I/O ports and 
  843.        registers.
  844.      o Register-Indirect LOAD and EXCHANGE instructions with optional 
  845.        automatic post-incrementing or decrementing of the register 
  846.        pointer. This allows for greater efficiency (both in cycle time 
  847.        and program code) in loading, walking across and processing 
  848.        fields in data memory.
  849.      o Unique instructions to optimize program size and 
  850.        efficiency. Some of these instructions are: DRSZ, IFBNE, DCOR, 
  851.        RETSK, VIS and RRC.
  852.      o Forty nine basic intructions
  853.      o Ten addressing modes provide great flexibility
  854.      o Easy to Program
  855.  
  856.     The feature family has seven instructions not available on the 
  857.     basic family devices. These instructions are:
  858.      o Push Data onto Stack (PUSH)
  859.      o Pop Data off of Stack (POP)
  860.      o And Skip if Zero (ANDSZ)
  861.      o Rotate Left through Carry (RLC)
  862.      o If Not Equal (IFNE)
  863.      o Vector Interrupt Select (VIS)
  864.      o Reset Pending Bit (RPND)
  865.  
  866.     The feature family instruction set contains a faster version of the 
  867.     LD B,# (B>15) instruction than the basic family. In the basic family
  868.     this instruction is 2-bytes/3-cycles. In feature family devices, 
  869.     this instruction is 2-bytes/2-cycles. The feature family supports an
  870.     additional addressing mode for the IFEQ instruction; the memory 
  871.     direct-immediate operand addressing mode (IFEQ MD,#).
  872.  
  873.      Accumulator Bit Manipulation Instructions - The Accumulator bit 
  874.      manipulation instructions allow the user to shift the Accumulator 
  875.      bits and to swap its two nibbles.
  876.        Rotate Right Through Carry (RRC)
  877.        Rotate Left Through Carry (RLC)
  878.        Swap Nibbles of Accumulator (SWAP)
  879.  
  880.      Stack Control Instructions
  881.        Push Data onto Stack (PUSH)
  882.        Pop Data off of Stack (POP) 
  883.  
  884.      Arithmetic Instructions - The arithmetic instructions perform 
  885.      binary arithmetic such as addition and subtraction, with or without 
  886.      the Carry bit.
  887.        Add (ADD)
  888.        Add with Carry (ADC)
  889.        Subtract (SUB)
  890.        Subtract with Carry (SUBC)
  891.        Increment (INC)
  892.        Decrement (DEC)
  893.        Decimal Correct (DCOR)
  894.        Clear Accumulator (CLR)
  895.        Set Carry (SC)
  896.        Reset Carry (RC)
  897.  
  898.      Conditional Instructions - The conditional instructions test a 
  899.      condition. If the condition is true, the next instruction is 
  900.      executed in the normal matter; if the condition is false, the next 
  901.      instruction is skipped.
  902.        If Equal (IFEQ)
  903.        If Not Equal (IFNE)
  904.        If Greater Than (IFGT)
  905.        If Carry (IFC)
  906.        If Not Carry (IFNC)
  907.        If Bit (IFBIT)
  908.        If B Pointer Not Equal (IFBNE)
  909.        And Skip if Zero (ANDSZ)
  910.        Decrement Register and Skip if Zero (DRSZ)
  911.  
  912.      Load and Exchange Instructions - The load and exchange instructions
  913.      write byte values in registers or memory. The addressing mode 
  914.      determines the source of the data.
  915.        Load (LD)
  916.        Load Accumulator Indirect (LAID)
  917.        Exchange (X)
  918.  
  919.      Logical Instructions - The logical instructions perform the basic 
  920.      logical operations AND, OR, and XOR (Exclusive OR). Other logical 
  921.      operations can be performed by combining these basic operations. 
  922.      For example, complementing is accomplished by exclusive-ORing the 
  923.      Accumulator with FFh.
  924.        Logical AND (AND)
  925.        Logical OR (OR)
  926.        Exclusive OR (XOR)
  927.  
  928.      Memory Bit Manipulation Instructions - The memory bit manipulation 
  929.      instructions allow the user to set and reset (clear) individual 
  930.      bits in memory.
  931.        Set Bit (SBIT)
  932.        Reset Bit (RBIT)
  933.        Reset Pending Bit (RPND)
  934.  
  935.      Transfer-of Control Instructions - The transfer-of-control 
  936.      instructions change the usual sequential program flow by altering 
  937.      the contents of the Program Counter. The Jump to Subroutine 
  938.      instruction saves the Program Counter contents on the stack before 
  939.      jumping; the Return instructions pops the top of the stack back 
  940.      into the Program Counter.
  941.        Jump Relative (JP)
  942.        Jump Absolute (JMP)
  943.        Jump Absolute Long (JMPL)
  944.        Jump Indirect (JID)
  945.        Jump to Subroutine (JSR)
  946.        Jump to Subroutine Long (JSRL)
  947.        Return from Subroutine (RET)
  948.        Return from Subroutine and Skip (RETSK)
  949.        Return from Interrupt (RETI)
  950.        Software Trap Interrupt (INTR)
  951.        Vector Interrupt Select (VIS)
  952.  
  953.      No-Operation Instruction - The no-operation instruction does 
  954.      nothing, except to occupy space in the program memory and time in 
  955.      execution.
  956.        No-Operation (NOP)
  957.  
  958. 2.5.7) Can I hook up a LED direct?
  959.  
  960.      Yep - you sure can. On all devices is a 8-bit port named D-port.
  961.      D-port pins can sink 10 mA (tested) 40mA (typical), and can
  962.      source 2mA (tested) 22mA (typical). All other ports can sink
  963.      2mA (tested) 17mA (typical) and can source 1mA (tested) 8mA
  964.      (typical).
  965.  
  966.      You should check the datasheet - some parts differ.
  967.  
  968. ----------------------------------------------------------------------
  969.  
  970.  
  971. 3)  COP8 PRODUCTS
  972.  
  973.    This section includes descriptions and references to free and
  974.    commercial software for the COP8.  FTP sites and BBSs contain many
  975.    quality packages and code samples for free.  For heavy duty use, you
  976.    might prefer the many commercial packages that are available.  With
  977.    the public domain (or free) stuff, you're usually on your own.  The
  978.    commercial packages usually provide extensive documentation and
  979.    support.
  980.  
  981.    Because not a lot of little companies use COP8, ('cause until about
  982.    a year ago we didn't make OTPs - the COP8 is used primarily by huge
  983.    companies - I don't think there is an American designed and built
  984.    car that doesn't have a COP in it somewhere - and those guys are not
  985.    going to use OTPs) there is not very much free software for the COP8.
  986.  
  987.     Hopefully this will change. - If you have a good idea for a new 
  988.     product (or are interested in porting your (or somebody else's)
  989.     existing tool to be used with the COP8 - please contact me.)
  990.  
  991. 3.1)  FTP sites
  992.  
  993.    The following is a list of the various anonymous ftp sites that have
  994.    COP8 source code and programming languages.  There are many others
  995.    that  are not listed here that contain bits and pieces.  Usually you
  996.    can find them using Archie and searching for "COP8", "National", or
  997.    "cop8".
  998.  
  999.  
  1000. 3.2)  BBSs
  1001.  
  1002.    The following BBSs sometimes have COP8 information:
  1003.  
  1004.    National Semiconductor Corporation
  1005.        - contains code from Applications Notes and other interesting
  1006.          items
  1007.        - phone -  (800) - NSC MICRO
  1008.                           672 6427
  1009.                -  (408) - 781 4818
  1010.                               4819
  1011.                               4810
  1012.                               4807
  1013.       - internet - telnet nscmicro.nsc.com
  1014.                  - ftp    nscmicro.nsc.com
  1015.  
  1016.    Circuit Cellar, Inc.
  1017.        - contains code from their magazine articles and from the
  1018.          original Circuit Cellar articles in Byte magazine, also
  1019.          contains many other interesting items
  1020.        - The BBS is mentioned in the masthead of each issue (on the
  1021.          table of contents page).  Excerpts from the BBS appear in Ken
  1022.          Davidson's ConnecTime column in every issue with a description
  1023.          of how to access the system at the end of every column.
  1024.        - (203)871-1988
  1025.        - Voice: (203)875-2751
  1026.        - Fax: (203)872-2204
  1027.  
  1028.    Electronics Now
  1029.        - contains code from their magazine articles
  1030.        - (516)293-2283
  1031.        - 1200/2400
  1032.        - 8 Data Bits, No parity, 1 Stop bit
  1033.  
  1034. 3.3)  Free languages and development tools
  1035.  
  1036.     There are none. (Besides the Assembler and Software Utilities that
  1037.     National gives away)
  1038.  
  1039.     Hopefully this will change. - If you have a good idea for a new 
  1040.     product (or are interested in porting your (or somebody else's)
  1041.     existing tool to be used with the COP8 - please contact me.
  1042.     National has a program in place with incentives for people who do things
  1043.     with COP8 - for more information contact rgetz@esd.nsc.com)
  1044.  
  1045. 3.4)  Free C compilers
  1046.  
  1047.     There are none.
  1048.  
  1049.     Hopefully this will change. - If you have a good idea for a new 
  1050.     product (or are interested in porting your (or somebody else's)
  1051.     existing tool to be used with the COP8 - please contact me.
  1052.     See above 3.3)
  1053.  
  1054. 3.5)  Plans for COP8-based boards
  1055.  
  1056.     There are none.
  1057.  
  1058.     Hopefully this will change. - If you have a good idea for a new 
  1059.     product (or are interested in porting your (or somebody else's)
  1060.     existing tool to be used with the COP8 - please contact me.
  1061.     See above 3.3)
  1062.  
  1063. 3.6)  Commercially available products
  1064.  
  1065.    Many firms (large and small) offer a variety of COP8 programming
  1066.    languages, support packages, and development systems.  No endorsement
  1067.    is implied by inclusion in this list.  I have made an attempt to
  1068.    include as many companies as possible.  I apologize to those I left
  1069.    out;  It's only because I didn't know about you.  If you want to be
  1070.    included in this list, just drop me a line - please.  Any corrections
  1071.    appreciated.
  1072.  
  1073.    C compilers - ByteCraft - contains a complete C compiler and integrated
  1074.      development environment for the COP8 family of microcontrollers. This 
  1075.      system provides ease of use and debugging capabilities not found in 
  1076.      other compilers.  AI system generates efficient, tight object code and
  1077.      fast execution. Includes linker and built in macro assembler.
  1078.  
  1079.      COP8 C-Code Development System
  1080.      ByteCraft Limited
  1081.      421 King Street North
  1082.      Waterloo, Ontario, Canada
  1083.      N2J 4E4
  1084.      (519) 888 - 6911 
  1085.      support@bytecraft.com
  1086.  
  1087.    Assemblers
  1088.      National Semiconductor Corporation
  1089.      - available for free on ftp:\\nscmicro.nsc.com\pub\cop8\assembler\
  1090.  
  1091.    Fuzzy Logic
  1092.      NeuFuz4 - NueFuz4 software, with up to 4 analog inputs and 1 analog
  1093.                output. Generates COP8 assembly Code.
  1094.      Contact National, or a National distributor.
  1095.      - demo copy on nscmicro.nsc.com
  1096.  
  1097.    In System Emulators
  1098.      iceMaster - Metalink - full in circuit emulator supporting all of
  1099.        the COP8 basic and feature family. Includes features such as a
  1100.        full performance analyzer, 4k - frame trace buffer, symbolic
  1101.        debugging, electrically transparent, 32K program space, hardware
  1102.        breakpoints.
  1103.  
  1104.      debug Module - Metalink - almost full in circuit emulator (does
  1105.        not support hardware breakpoints). Includes features such as 
  1106.        8 software breakpoints, 100 frame trace buffer, symbolic debugging,
  1107.        Sockets for programming COP8 OTPs in DIP, SO and PLCC.
  1108.  
  1109.      Evaluation and Programming Unit (EPU) - Metalink - in circuit 
  1110.        simulation (non real-time emulation). Includes features such as
  1111.        4k program size, 8 software breakpoints, 100 frame trace buffer,
  1112.        Symbolic debugging, 40-pin DIP socket for programming COP8780 and
  1113.        COP87M80 OTPs.
  1114.    
  1115.      All Metalink Tools can be purchased through National.
  1116.  
  1117.    Real-time Operating Systems (RTOS)
  1118.     There are none.
  1119.  
  1120.     Hopefully this will change. - If you have a good idea for a new 
  1121.     product (or are interested in porting your (or somebody else's)
  1122.     existing tool to be used with the COP8 - please contact me.)
  1123.  
  1124.    Programmers for OTPs and Windowed parts
  1125.                     North America     Europe          ASIA
  1126.     Metalink        (602) 926-0797  (49) 8141-1030    (852) 737-1800
  1127.     Xeltek          (408) 745-7974  (49) 2041-684758  (65) 276-6433
  1128.     BP Microsystems (800) 225-2102  (49) 89-8576667   (852) 3888-0629
  1129.     Data I/O        (800) 322-8246  (49) 89-85-8020   (33) 432-6991
  1130.     Abcom                           (89) 808707
  1131.     System General  (408) 263-6667  (31) 921-7844     (886) 2-9173005
  1132.  
  1133.  
  1134. 3.7) Contacting National
  1135.  
  1136.     Worldwide support (in English) on COP8 Tools you can email:
  1137.       coptools@esd.nsc.com
  1138.  
  1139.     For pricing, avaliblity, or support in your native language, call:
  1140.     Country         Tel                       Fax
  1141.     Australia       (3) 558 - 9999            (3) 558 - 9998
  1142.     Brazil          (55-11) 212 - 5066        (55-11) 212 - 1181
  1143.     Bulgaria        (02) 88 - 01 - 16         (02) 80 - 36 - 18
  1144.     Canada          (800) 272 - 9959          (800) 432 - 9672
  1145.     Denmark         (57) 67 - 20 - 80         (57) 67 - 20 - 82
  1146.     Finland         (0) 759 - 1855            (0) 759 - 1393
  1147.     France          (01) 40 - 94 - 88 - 88    (01) 40 - 94 - 88 - 11
  1148.     Germany         (0 - 69) 789 - 1090       (0 - 69) 789 - 4383
  1149.     Hong Kong       (852) 737 - 1600          (852) 736 - 9960
  1150.     Ireland         (01) 260 - 0022           (01) 283 - 0650
  1151.     Italy           (02) 57500300             (02) 57500400
  1152.     Japan           (043) 299 - 2300          (043) 299 - 2500
  1153.     Korea           (02) 784 - 8051           (02) 784 - 8054
  1154.     Mexico          (525) 661 - 7155          (525) 661 - 6905
  1155.     Puerto Rico     (809) 758 - 9211          (809) 763 - 6959
  1156.     Singapore       (65) 225 - 2226           (65) 225 - 7080
  1157.     Spain           (01) 7 - 33 - 29 - 58     (01) 7 - 33 - 80 - 18
  1158.     Sweden          (08) 7228050              (08) 7229095
  1159.     Switzerland     (01) 8 - 30 - 27 - 27     (01) 8 - 30 - 19 - 00
  1160.     Taiwan          (02) 521 - 3288           (02) 561 - 3054
  1161.     United Kingdom  (0793) 61 - 41 - 41       (0793) 52 - 21 - 80
  1162.     United States   (800) 272 - 9959          (800) 432 - 9672
  1163.  
  1164. ----------------------------------------------------------------------
  1165.  
  1166.  
  1167. 4)  COP8 DOCUMENTATION
  1168.  
  1169. 4.1) Periodicals
  1170.  
  1171.    Various magazines and journals (journals seems to be THE popular name
  1172.    for magazines these days) provide articles from time to time on the
  1173.    COP8 line of microcontrollers:
  1174.  
  1175.    The Computer Applications Journal (Circuit Cellar Ink)
  1176.        - programming and construction articles
  1177.        - POB 7694, Riverton, NJ  08077-8784
  1178.        - Fax: (203)872-2204
  1179.        - Voice orders: (609) 786-0409
  1180.        - On-line orders (BBS): (203) 871-1988
  1181.        - Email orders: ken.davidson@circellar.com
  1182.        - $21.95, $31.95 surface Canada and Mexico,
  1183.          $49.95 air all other countries
  1184.  
  1185.    Computer Design
  1186.        - industry announcements and trends
  1187.        - One Technology Park Drive, P.O. Box 990, Westford, MA  01886
  1188.        - (508)692-0700
  1189.  
  1190.    The Computer Journal
  1191.        - programming and construction articles
  1192.        - PO Box 535, Lincoln  96648
  1193.  
  1194.    Dr. Dobbs Journal
  1195.        - programming articles, concepts, and designs
  1196.        - 411 Borel Ave., San Mateo, CA  94402
  1197.        - (415)358-9500
  1198.  
  1199.    Electronic Engineering Times
  1200.        - industry announcements and trends
  1201.        - 500-B Bi-County Boulevard, Farmingdale, NY  11735
  1202.        - (516)293-3000
  1203.  
  1204.    Electronics Now
  1205.        - construction articles
  1206.        - Box 55115, Boulder, CO  80321-5115
  1207.        - $19.97 one year
  1208.  
  1209.    Elektor Electronics
  1210.        - programming and construction articles
  1211.        - World Wide Subscription Service Ltd
  1212.          Unit 4, Gibbs Reed Farm, Pashley Road
  1213.          Ticehurst TN5 7HE, England
  1214.        - 27 UK pounds
  1215.     or
  1216.        - Old Colony Sound Lab, P.O. Box 243, Peterborough, NH 03458
  1217.        - Tel. (603) 924-6371, 924-6526
  1218.        - Fax: (603) 924-9467
  1219.        - $57 USA and Canada per year
  1220.  
  1221.    Embedded Systems Programming
  1222.        - programming and systems design articles
  1223.        - Miller Freeman Publications
  1224.        - 500 Howard St., San Francisco, CA  94105
  1225.        - (415) 397-1881
  1226.  
  1227.    Microcomputer Journal (formerly Computer Craft)
  1228.        - programming and construction articles
  1229.        - 76 N. Broadway, Hicksville, NY  11801
  1230.        - $18.95 one year, foreign $23.00, foreign air mail $76.00
  1231.  
  1232.    Midnight Engineering
  1233.        - 1700 Washington Ave., Rocky Road, CO  81067
  1234.        - (719)254-4553
  1235.  
  1236.    Nuts & Volts Magazine
  1237.        - A National Publication for the Buying and Selling of
  1238.          Electronic Equipment
  1239.        - 430 Princeland Court, Corona, CA  91719
  1240.        - Mailed third class, USA only:  $17.00 one year
  1241.                                         $31.00 two years
  1242.        - Mailed first class, one year only:  $34.00-USA
  1243.                                              $35.00-Canada/Mexico
  1244.        - Foreign/Air Mail - $70.00;  Foreign/Surface - $39.00
  1245.        - (800)783-4624
  1246.        - Email:  74262.3664@Compuserve.com
  1247.  
  1248. 4.2)  Data Books / Application Notes
  1249.  
  1250.    If you know of any books that cover the COP8, or if you can provide
  1251.    any details on the books listed here, please send me a note.  Thanks.
  1252.  
  1253.    Books provided by National about the COP8
  1254.  
  1255.    COP8 Databook
  1256.      - Lit # 400007-001
  1257.      - Current databook for COP8
  1258.  
  1259.    COP8 Advertisement
  1260.      - Lit #620900-001
  1261.      - Introduces 8-bit microcontrollers and COP8
  1262.  
  1263.    Utility Disk
  1264.      - Mac Version - Lit #630000-001
  1265.      - Win Version - Lit #630001-001
  1266.      - Typical microcontroller application and sample application code
  1267.  
  1268.    Product Overview Disk
  1269.      - Mac Version - Lit #630004-001
  1270.      - Win Version - Lit #630005-001
  1271.      - Self-lead COP8 overview. Shows product features/benefit and 
  1272.        includes an electronic selection guide.
  1273.  
  1274.    COP8 Selection Guide
  1275.      - Lit # 630006-001
  1276.      - Selection guide including 20 application examples
  1277.  
  1278.    COP8 Selection Sheet
  1279.      - Lit #620899-001
  1280.      - Selection guide only
  1281.  
  1282.    COP8 Designers Information Kit
  1283.      - Lit #630007-005
  1284.      - Includes databook, Selection Guide, Independent Software Analysis
  1285.        Utility and Overview disks
  1286.  
  1287.    Independent 8-bit Instruction Set Analysis
  1288.      - Lit #630008-001
  1289.      - Independently prepared software analysis of National's COP8,
  1290.        Motorola's M68HC05, Intel's 8051 and Microchip's PIC16C5X.
  1291.  
  1292.    8780 EPU Product Brief
  1293.      - Lit #610506-001
  1294.      - Metalink's COP8780 Evaluation / Programming Unit
  1295.  
  1296.    Debug Module Product Brief
  1297.      - Lit #610520-001
  1298.      - Fact sheet on Metalink's Debug Module
  1299.  
  1300.    iceMaster Product Brief
  1301.      - 630074-001
  1302.      - Fact Sheet on Metalink's in-circuit emulator
  1303.  
  1304.    COP8C Product Brief
  1305.      - Lit #610505-001
  1306.      - Fact Sheet on ByteCraft's C compiler for COP8
  1307.  
  1308.    NueFuz Product Information Pack
  1309.      - Lit #633101-002
  1310.      - Intro to NeuFuz4 (disk, app-not and fact sheet)
  1311.  
  1312.    Application Notes
  1313.      - Lit #100823-001 - Timekeeping using a COP800
  1314.      - Lit #100643-001 - EMI / RFI Board Design
  1315.      - Lit #100959-001 - Battery charger with Neufuz
  1316.      - Lit #400007-001 - Others can be found in the 1994 databook. 
  1317.  
  1318.    Programmer's Reference Guide
  1319.      - Programmer's Reference Guide includes block diagrams, connection 
  1320.        diagrams, memory map, instruction set, bytes and cycles per
  1321.        instruction, and device features.
  1322.      - Lit #630018-001 - COP820/840
  1323.      - Lit #630019-001 - COP888CL / COP888CF / COP888CG
  1324.  
  1325.    COP800 Basic Family Users Manual
  1326.      - Doc #420410703-001
  1327.      - Describes all basic family devices, in-depth features and
  1328.        common pitfalls
  1329.  
  1330.    COP888 Features Family Users Manual
  1331.      - Doc #420411060-001
  1332.      - Describes all feature family devices, in-depth features and
  1333.        common pitfalls
  1334.  
  1335.    COP8 Assembler / Linker / Librarian Users' Manual
  1336.      - Doc #424421632-001
  1337.      - Printed version of COP8 Assembler Manual.
  1338.  
  1339.    NeuFuz User's Manual
  1340.      - Doc #424421645-001
  1341.      - Manual for Neural / Fuzzy software
  1342.  
  1343.    Dial-A-Helper User's Manual
  1344.      - Doc #420410902-001
  1345.      - Manual for National's BBS
  1346.  
  1347. __________________________________________________________
  1348.  
  1349. Some parts Copyright (c) 1994 by Russell Hersch,<sibit@datasrv.co.il>
  1350.    all rights reserved. (Used with permission)
  1351.  
  1352. The rest is Copyright (c) 1995 Robin Getz all rights reserved.
  1353. -----------------------------------
  1354. Robin Getz - rgetz@esd.nsc.com
  1355.  
  1356.  
  1357.  
  1358.