|
|
Project #1 -
Jerrold data stream logger in under 288 bytes!
First, GI sends its data
manchester encoded on a carrier anywhere from 80Mhz to 122.7 in some places.
Once you STRIP the manchester encoding you get a standard 11 bit packet
containing 1 start bit, 8 data bits, 1 even parity bit, 1 stop bit. Years ago GI
actually stripped the manchester data off the incoming packets and sent them to
a standard 6850 uart. Now adays they use an advanced 6850 core in their custom
chip to convert the data. Fortunately, we all have 16450/16550 usarts in our
PC's which HAPPILY read the data coming in off the cable wire (with
help).
First problem, how to convert the manchester data to standard data (polar).
Manchester looks like
this:
We want it to look like
this (for our PC):
Looks difficult??? Not really, notice the transistion between 1 and 0 above. (manchester). If we sample for that then we KNOW when a one or 1 is going to happen (this allows us to lock onto the data coming in).
This is what the data looks like in the real world:
Now, back to our problem. The easiest method is to use a pic.... Well, here is the SOURCE CODE:
-------------------------------------------------------------------------------------------------
; Magicboxes 1998 Jerrold
Data Logger - 1998
; This is copyright material. This software may be
freely
;
distributed as long as the headers are in tact!
device pic16c54,xt_osc,wdt_off,protect_off
temp1
equ
10h
;Counter for serial delay routines
DataIn
equ porta.2
DataOut equ
porta.3
RESET BEGIN
org 10
BEGIN
movlw 11110111b
tris porta ; RA.2 is the RS232
output.
bcf DataOut
restart movlw
19
; wait for approx 60us high
movwf
temp1 ; this flips
the manchester encoding
start
btfss
DataIn
goto
restart
decfsz
temp1,1
goto
start
goto
loop1 ; wait for a 0
bit
; the loop below runs endlessly converting manchester data to unipolar data !
loop0
; wait for a 1 bit
btfss
DataIn
goto
loop0
bcf DataOut
goto
wait60
loop1
; wait for a 0 bit
btfsc
DataIn
goto
loop1
bsf DataOut
goto
wait60
wait60
; wait 50uS
movlw
32
movwf
temp1
loop2 decfsz temp1,1
goto
loop2
nop
btfsc
DataIn ; check to see current
status of new bit, jmp accordingly
goto
loop1
goto
loop0
The circuit:
When you burn a PIC16C54 and build this circuit you should see:
Trace 1 is the data coming
into the PIC16C54, Trace 2 is showing our NEW PC-READY data.
(Thank's GI for providing
your NO-SECURITY data authorization stream!)
Software on the PC side? Real cool. I quickly put together this "hack" tonight which supports 16550 uarts, COM 1 or 2. And allows you to vary the baud rate slightly.
The software looks like this:
The program strips all the
junk off and provides you with formatted GI command strings!
You can use this program
to read data off of your cable line, extra data from test chips
and
cubes. The following is data collected from the Phantom
cube:
Magicboxes - Jerrold
Data Logger v0.1 - Jim Borden -
1998(c)
Unregistered version, contact us for other PC-type Jerrold Control
software
Need custom test chips? Contact us!
http://www.magicboxes.com
3 FD 6E 92 FF FF FF FF
FF
11 FD
4D E0 80 76 0 B 0 2A 0 0 0 0
0 0 0 9A FF FF FF FF FF
8 FD 49 E0 80 76
0 0 DC FF FF FF FF FF
FD 50 E0 80 76 0 0 D5
FF FF FF FF FF
E8 E0 80 76 0 FF 3C FF FF FF FF
7 E9 E0 80 76 0 FF 3B
FF FF FF FF
7 EA E0 80 76 0 FF 3A FF FF FF FF
7 EB E0 80
76 0 FF 39 FF FF FF FF
7 EC E0 80 76 0 FF 38
FF FF FF FF
7 ED E0 80 76 0 FF 37 FF FF FF FF
7 EE E0 80
76 0 FF 36 FF FF FF FF
7 EF E0 80 76 0 FF 35
FF FF FF FF
7 F0 E0 80 76 0 FF 34 FF FF FF FF
7 F1 E0 80
76 0 FF 33 FF FF FF FF
7 F2 E0 80 76 0 FF 32
FF FF FF FF
7 F3 E0 80 76 0 FF 31 FF FF FF FF
7 F4 E0 80
76 0 FF 30 FF FF FF FF
7 F5 E0 80 76 0 FF 2F
FF FF FF FF
7 F6 E0 80 76 0 FF 2E FF FF FF FF
7 F7 E0 80
76 0 FF 2D FF FF FF FF
9 FD B0 E8 E0 80 76 0
FF 8D FF FF FF FF
9 FD B1 E9 E0 80 76 0 FF 8B FF FF FF FF
9 FD B2 EA E0 80
76 0 FF 89 FF FF FF FF
9 FD B3 EB E0 80 76 0
FF 87 FF FF FF FF
9 FD B4 EC E0 80 76 0 FF 85 FF FF FF FF
9 FD B5 ED E0 80
76 0 FF 83 FF FF FF FF
9 FD B6 EE E0 80 76 0
FF 81 FF FF FF FF
9 FD B7 EF E0 80 76 0 FF 7F FF FF FF FF
9 FD B8 F0 E0 80
76 0 FF 7D FF FF FF FF
9 FD B9 F1 E0 80 76 0
FF 7B FF FF FF FF
9 FD BA F2 E0 80 76 0 FF 79 FF FF FF FF
9 FD BB F3 E0 80
76 0 FF 77 FF FF FF FF
9 FD BC F4 E0 80 76 0
FF 75 FF FF FF FF
9 FD BD F5 E0 80 76 0 FF 73 FF FF FF FF
9 FD BE F6 E0 80
76 0 FF 71 FF FF FF FF
9 FD BF F7 E0 80 76 0
FF
This project is now falling under the 3-chip non-profit project. The software below is free however if you want a registered version including "Packet"/"Command" identification code please donate $50 to the 3-chip project. For $75 we will send you a complete data logger with software.
As we all know Steve Glendening's cable area uses CFT2200s and is not digital yet (and we all know he's been saying it will convert tomorrow).I hope this code will allow more people in HIS area to better understand the system and start testing ;-)
Programs to
follow:
Jerrold Data
Router
Actual dual-port IBM -PC Jerrold data router which will take all
commands on the input and CHANGE them to HAPPY commands on the output. For
instance, shutdown commands converted to turnon commands,
etc...
Jerrold Data
Bridge with programmable filters for problem
areas
This program will allow you to experiment with their data until
you find out what they are doing to be mean!
ESN
Finder
This unit will poll your DPBB and CFT and report back to you the
INTERNAL Subscriber number the cable company has put in your
box.
Test Chips &
Cubes
We
will be putting online source code & schematics, PCB layouts and gerber
files to all the major cubes (Phantom, Cheetah, DR. Jerrold, RFT, T2,
Stick, FSK) + manufacturing information so you can make your own for around
$8-10 each in quantities of 500.
Check bad here regularily
for updates. If you want test chips from us first, you can expect the best.
Second, its custom for you!. We sell them at $8-12 each so we don't make a lot
on them and if you are buying them from us we will make sure your set tops DON'T
go down as we write code on the fly. We have test chips available for North
America, UK, Europe, and most other countries.
Files
Download
source code for the PIC16C54/XT-P
Download
obj file for the PIC16C54/XT-P
Download
MagicLog - the unregistered version.
KNOWN
BUGS:
Hardware: None, just use a GOOD 5V supply with
filtering. No noisy packets!
PC Software: The queue
cycles 150K right now so save after a few minutes. (Make sure you hit clear
buffer before you save). The registered version stops after 300K and all
registered folks will get the updated version with PacketIdent, and continuous
logging. E-mail updates will be provided. This is now part of the 3-chip project
and is therefore non-profit. Make lots of cubes and testchips!
P.S. Scientific Atlanta -
haven't forgot you. A VBI data logger will be made available soon along with a
packet logger for your older FSK datastream models).

October
30,1998 - Click here to download MagicBoot - The ESN/Site code cloning tool
(Windows 95/98)!