These are my current PIC-E packet sending asm source 
files, version 0.90

**********************************************************************
* This software is  available only for non-commercial  amateur radio *
* or educational  applications.   ALL  other  uses  are  prohibited. * 
* This  software may  be  modified  only  if the  resulting code  be *
* made available  publicly  and the  original  author given  credit. * 
* Contact the author or TAPR for information on commercial licenses. *
* (c) Copyright 1999,  Byon Garrabrant,  N6BG.  All rights reserved. *
**********************************************************************

Users can customize two independent settings in 
options.asm

I assemble with MPASM.EXE /t4 /q pic-e.asm

Fixes from last version:

Fixed the D'130'-2 bug which sped up packets and kept
them from being received on a KPC3 with software CD.

Byon Garrabrant
byon@mail.com
Feb 16, 1999
-------------------------------------------------------
These are my current PIC-E packet sending asm source 
files, version 0.88

Still need to add logic inversion for serial, 
and auto/manual disabling

Fixes:

Changed pin usage to match new hardware:
Serial In    changed from    PORTA,1    to    PORTA,0
Serial Out   changed from    PORTA,0    to    PORTA,1
PTT In       changed from    PORTB,4    to    PORTA,3
Valid Out    changed from    PORTA,3    to    PORTB,0
Tone Out     changed from    PORTB,0    to    PORTB,5
VOX In       changed from    PORTB,5    to    PORTB,3


Byon Garrabrant
byon@mail.com
Jan 24, 1999
-------------------------------------------------------
These are my current PIC-E packet sending asm source 
files, version 0.86

Still need to add logic inversion for serial, 
and auto/manual disabling

Fixes:

Removed PCD3312.asm, I2C.asm, and ladder.asm since we 
have settled on the MX614.

Updated MIC-E format to made bit 6 opposite of bit 7 
in dest callsign (The real Indian Ocean bug)

IORed 0xE0 to set Cmd/Response flag and both "rr" bits 
in dest SSID (from Steve Bible)

Added 800 to speed and 400 to course in MIC-E format.

Added 60 to Longitude Minutes if it was < 10

Added 80 to Long Degrees if 10x

Added 190 to Long Degrees is 00x

Byon Garrabrant
byon@mail.com
Oct 13, 1998
-------------------------------------------------------
These are my current PIC-E packet sending asm source 
files, version 0.84

Still need to add logic inversion for serial

Fixes:

Added separate TXDELAYS for manual and automatic

Disallowed auto transmit if PTT IN is keys

Added other mode line to enable MX614 receive mode

Activate PTT_OUT when manual mode ready

Slowdown PTT IN checking to fix bounce

Changed Config to set OSC to HS

Test for Manual Transmit before Auto

Byon Garrabrant
byon@mail.com
Sep 20, 1998
-------------------------------------------------------
These are my current PIC-E packet sending asm source 
files, version 0.82

Fixes include:

Changed to r bit of MIC_E_DEST_BASE[0-6] to 1
to fix the Indian Ocean bug

Inverted PTT_IN sense (low means transmitting now)

Turning off fix (valid) LED after 15 seconds instead 
of 150 seconds

When fix LED goes out, MIC-E data valid symbol forced 
to the invalid symbol, if it was valid symbol

Removed Knots to Miles conversion

Fixed Debug Hex dump to not stack overflow

Byon Garrabrant
byon@mail.com
Sep 17, 1998
-------------------------------------------------------
These are my current PIC-E packet sending asm source 
files, version 0.80

They have been cleaned up a bit, but still require some
comments in places

These files are not to be viewed by anyone not working
on the TAPR PIC-E project, and may not be included in 
any other project without written permission.

Features:

- Two full configurations, each allowing tx_delay, 
	message bits, symbol, symbol table, path bits,
	auto time, manual time, quiet time, beacon rate,
	callsign, path, and beacon
- Each Path can contain up to 8 digis
- Each Beacon can contain up to 100 characters (with 
	no digis), 45 characters with a full 8 digi path
- MIC-E compression
- Simultaneous Manual and Automatic modes and timings


The included files are:

pic-e.asm - The main source file.  This one includes 
	all the other required files.

nmea.asm - This decodes the NMEA string, and builds
	the compressed MIC-E data

options.asm - This stores the two user option fields

serial.asm - This receives the serial data from the GPS

timing.asm - This manages timing for sending transmission
	as the requested intervals

ax25.asm - This is a packet AX.25 sending code, which
	is built on one of the below tone sending files. 
	Select one of the following tone sending files 
	in pic-e.asm

ladder.asm - This sends audio through a 4 bit resistor
	ladder.

pcd3312.asm - This sends audio through the Philips 3312
	I2C chip and requires and includes i2c.asm

i2c.asm - This communicates, one-way, with an I2C chip
	and assumes it is present.

mx614.asm - This sends audio through the MX614 BELL202
	modem chip

ROM and RAM requirement for each source module:

                ROM           RAM
PIC-E           101           3
NMEA/MIC-E      278           40
SERIAL          29            3
TIMING          71            6
AX.25           63            6

LADDER          100           9
PCD3312/I2C     89            7
MX614           50            5

OPTIONS         256           0

ROM and RAM requirement for each complete mode:
LADDER          642           67
PCD3312/I2C     631           65
MX614           592           63



ROM:
Given that we have room for 1024 instructions in ROM, and
that we are dedicating 1/4 of that to options (256), that
leaves us with 768 instructions. The base use is 542. That
leave us 226 for tone generation code.  The worst case is
currently ladder, leaving us with 126 free instructions in 
ROM.

RAM:  
Worst case is again ladder, giving a total of 67. Since the 
chip supports 68, we have 1 byte of RAM left.  However, there
are easy places to trim back.

Currently there are 3 I/O pins free with ladder, 5 free with 
3312 and MX614

No EEPROM data is being used

I assemble with MPASM.EXE /t4 /q pic-e.asm

Schematic

I will attempt to describe what each pin is connected to, 
and let someone with proper software draft a real schematic
Wire up the PIC and your choice of the ladder, 3312, or 614.

PIC16F84
PIN 1  - PTT Out/LED
PIN 2  - FIX LED
PIN 3  - MODE IN
PIN 4  - 5V
PIN 5  - GND
PIN 6  - AUDIO 0
PIN 7  - AUDIO 1
PIN 8  - AUDIO 2
PIN 9  - AUDIO 3
PIN 10 - PTT IN
PIN 11 - VOX IN
PIN 12 - N/C
PIN 13 - N/C
PIN 14 - 5V
PIN 15 - 10 MHZ RESINATOR
PIN 16 - 10 MHZ RESINATOR
PIN 17 - N/C
PIN 18 - SERIAL IN

RESISTOR LADDER
AUDIO 0 -> 8K    -> AUDIO OUT
AUDIO 1 -> 4K    -> AUDIO OUT
AUDIO 2 -> 2K    -> AUDIO OUT
AUDIO 3 -> 1K    -> AUDIO OUT
GND     -> 0.1uf -> AUDIO OUT

PCD3312
PIN 1 - GND
PIN 2 - 5V
PIN 3 - 3.579 MHZ CRYSTAL
PIN 4 - 3.579 MHZ CRYSTAL
PIN 5 - AUDIO OUT
PIN 6 - GND
PIN 7 - AUDIO 1
PIN 8 - AUDIO 0
    
MX614
PIN	1  - N/C
PIN	2  - N/C
PIN	3  - 5V
PIN	4  - AUDIO 1
PIN	5  - N/C
PIN	6  - N/C
PIN	7  - AUDIO OUT
PIN	8  - GND
PIN	9  --> 0.1uf ->GND
PIN	10 - N/C
PIN	11 - AUDIO 0
PIN	12 - 5V
PIN	13 - N/C
PIN	14 - N/C
PIN	15 --> 100K -> 5V
PIN	16 - 5V


Comments, Questions?

Byon Garrabrant
byon@mail.com
Aug 30, 1998

