PDA

View Full Version : Uphill to school both ways



1project2many
09-15-2011, 04:40 PM
So, with Winnows and GUIs in almost everything these days, "old fashioned" tools that used typed commands are disappearing faster than Arctic ice. Command prompt based tools are all but forgotten but there are still a few good ones out there. One of the best programs for a GM OBDI tuner to have around is Ludis Langens' Bithoist. I'm currently using it along with a batch file I wrote to automatically identify every .bin from the diy_efi .bin library. Here's an example of the output:

File 'c:\d_drive\bins\unknown\BLCD.BIN'
Address: 0x8000,0xffff
CRC: 0x08574b88
Mask ID: 12b
ID byte: 0x12
Sum word: 0x520c
Sequence: Mar 11, 1994 #202 (02C000CA)
Scan ID: 5088
BCC: BLCD (stock)

This gives file size (by the addresses) a calculated CRC checksum based on downloaded data, the correct mask ID, calculated GM checksum, the date sequence if supplied by GM, scan id and BCC. This program has helped me resolve many mystery proms, and has quickly helped me uncover fraudulent "performance" chips over the years. It's also able to output data in multiple formats and to files or other locations to be used by other programs. For the real hardcore guys it can merge the old C3 cal data (what's in the chip) and code (what's on the mask rom) then try to identify the resulting calibration and create an output file to pass to a disassembler.

It's not complete and I've never tried to update or modify it. Later calibrations are more likely to generate an "unknown" than early cals. I simply place files ID'ed as "stock" in my library in a main directory, place files which are identified but not listed as stock in a subdirectory titled "modified," while all unidentified files are placed in a folder titled "unknown." Saves me from starting with a bad or incorrect file when tuning.

I can upload this along with the helper batch file I've created. It's less than 1meg. Where to place it?

1project2many
09-15-2011, 05:16 PM
Here's an example of a modified file:

File 'c:\d_drive\bins\unknown\abul.bin'
Address: 0xd000,0xdfff
CRC: 0xbbf73d49
Mask ID: 42
ID byte: 0x42
Sum word: 0x8969 (should be 0x8f39)
Scan ID: 7941
BCC: BDR4376
BCC: ABUL8235

The checksum does not match OEM which means this is a modified chip. Who knows what's changed, so I probably won't use this for anything but educational purposes.

EagleMark
09-16-2011, 04:14 PM
If I have everything set right you should be able to attach it here! Is it an .exe ? Pretty sure that's already set up in photgallerey too. I really need to reorganize the photogallerey this winter so it's easier to use.

1project2many
10-19-2011, 06:12 AM
Bithoist by Ludis Langens.

EagleMark
10-19-2011, 07:00 AM
Oh Boy! Looks like I am going to have to brush up on Webmaster skills and build some HTML... wait I learned XML... pages! Thanks Shannen!

1project2many
10-19-2011, 07:49 PM
This program is designed to run by itself... not as a web interface. Unzip all the files to a directory then switch to the command prompt (start --> run --> CMD) and run the program from there. Switch to the directory where the files are and type bithoist. If you're familiar with running DOS programs this will be old hat. If not then it's not too hard to make it work. The included batch file id_buddy will automatically invoke bithoist for every file in a directory and save the results to a text file. Handy right after downloading a whole bunch of cals or when finding a stash of files on an old hard drive. :)

EagleMark
10-19-2011, 08:08 PM
HMMMM! Dos? I remember learning that and giving up on computers till windows 95.

I'll have to find time to do what you said and try it. Wonder if I could build a webpage to interface with the program on server? That would be optimal! Then we could add bins along the way? If not can you add bins to this?

1project2many
10-20-2011, 03:06 PM
I could try contacting Ludis, the guy who wrote it, and see how he did his magic. Ludis has a lot more experience with electronics and computers than I have. He was one of the real pioneers for working out the GM stuff. If it's a big project I don't know if I can commit to it, though.

EagleMark
10-20-2011, 06:56 PM
I spent about an hour trying to make it work on my PC yesterday... FAIL!

historystamp
01-30-2012, 11:06 PM
Here's an example of a modified file:

File 'c:\d_drive\bins\unknown\abul.bin'
Address: 0xd000,0xdfff
CRC: 0xbbf73d49
Mask ID: 42
ID byte: 0x42
Sum word: 0x8969 (should be 0x8f39)
Scan ID: 7941
BCC: BDR4376
BCC: ABUL8235



What was the command line you used to get this? Could you post the input file or a link to the file?

I am trying to get bithoist to work on my Mac.

Thanks.

Robert

EagleMark
01-30-2012, 11:11 PM
Suposedly this is a newer issue BitHoist.

PJG1173
01-31-2012, 12:06 AM
there appears to be a readme file in the zip that contains usage info. I don't see any dos batch files though.

historystamp
01-31-2012, 12:35 AM
Thanks guys. I guess I'm waiting for someone like 1project2many to post what he did to get the output he showed.

I've compiled an' run the thing, but didn't get the same output as shown above with what I thought was the "same" input.

Robert

1project2many
01-31-2012, 01:30 AM
If your binary file is named BLCD.bin and it's in the same directory as bithoist then bithoist BLCD.bin -id should give the desired output. If you need more help then I'm going to have to learn more about MacOS than I currently know.

FWIW Bithoist was written on an Apple platform. If you only type bithoist the program should return proper command line format and options in a list.

historystamp
01-31-2012, 09:31 PM
Thanks. I have what I need.

I wanted to eliminate the possibility that I was invoking the command incorrectly. I'm assuming that I am running into the byte order problem:
"A big-endian machine stores the most significant byte first, and a little-endian machine stores the least significant byte first." Wiki

I cannot find the compiler for the Mac version so I compiled the Unix version. The Unix version seems to "work" but gives the wrong output. Someday, I'll have to see if I can figure out why.

Robert

EagleMark
01-31-2012, 11:10 PM
I really never had time to play with BitHoist. What exactly does it do?

1project2many
02-01-2012, 01:41 AM
Bithoist has several jobs. The most relevant here is to identify a .bin, display it's mask, and confirm that it's stock or modified.

Robert, I'll look through old emails and the gmecm list archives to see if Ludis noted any special instructions. IIRC I needed to modify the make file for the Intel platform. If you're using a make file that I uploaded there's a chance it's the modified version. I have a 'nix machine at the house, although it's Intel based, so we could probably work together to figure out compile instructions that get the job done. Just out of curiousity, could you post a sample of the output you're getting?

historystamp
02-23-2012, 10:29 PM
I got BitHoist to work on my Mac ( PowerPC Mac OS X 10.4.11 ). I noticed that someone else wrote the make for Linux. I compiled from the command line with the Linux make file.

Also, I've got BitHoist to work on Ubuntu Linux with the intel architecture.

mac $ ./BitHoist -id Sunbird.bin
File 'Sunbird.bin'
Address: 0xc000,0xffff
CRC: 0xf3680b8f
Mask ID: 58
ID byte: 0x58
Sum word: 0xd1ee
Sequence: Dec 3, 1990 #1420 (0D2A058C)
Scan ID: 3411
BCC: AUWR3607 (stock)


mac $

historystamp
02-23-2012, 10:47 PM
I'm playing around displaying binary files in hex. I've have two questions.

1) There seems to be a repeating sequence in the first 2 or 4 bytes. What does this mean?
2) What does the last number after the hex dump mean?
example -- :00000001FF from the first command

Here is what I see:

1714





















I working on a little readme to describe how to run the program.

Robert

1project2many
02-27-2012, 06:00 AM
I haven't played with S records in years.
S113C010 =
S1 Data Sequence 2
13 $13 (d19) bytes in remainder of line
C010 address in file of first byte of data line

Intel format.
:10C02000 =
:10 $10 (d16) bytes in data field
C020 Address in chip of first byte of data line
00 Data type (16 bit address data records)

Techtronix format:
%2A6EE4C020 =
%2A $2A (d42) characters in line
6 data fields (vs termination fields) in line
EE checksum
4 number of bytes making up the data address
C020 address in chip of first byte on line