netkas.org forum
April 30, 2017, 07:41:05 PM *
Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
News: Information for registering users http://forum.netkas.org/index.php/topic,2246.0.html
 
   Home   Help Search Login Register  
Pages: 1 ... 3 4 [5] 6 7 ... 15
  Print  
Author Topic: GFX-Strings  (Read 206862 times)
0xdeadbeef
Newbie

Offline Offline

Posts: 25



« Reply #60 on: December 13, 2007, 09:13:02 PM »


I put this signature to block header. Now i need to do datatype detection (data, integer, string) and then the hard part convert plist back to binary form.



EFI doesn't appear to care about the datatype - for example radeon.efi just adds them to the properties as length-counted binary arrays as far as I can see. I think it's up to the receiving drivers to decide what datatype they are.

IE in the bootloader they are all just "data"  Shocked
Logged

Conquering the world - 8 hex digits at a time.
cynix
Newbie

Offline Offline

Posts: 1


« Reply #61 on: December 14, 2007, 02:35:18 AM »

EFI doesn't appear to care about the datatype - for example radeon.efi just adds them to the properties as length-counted binary arrays as far as I can see. I think it's up to the receiving drivers to decide what datatype they are.

IE in the bootloader they are all just "data"  Shocked

I think he meant displaying data in their corresponding types in the plist so it's easier for editing?
Logged
0xdeadbeef
Newbie

Offline Offline

Posts: 25



« Reply #62 on: December 14, 2007, 08:23:29 AM »


I think he meant displaying data in their corresponding types in the plist so it's easier for editing?



What? You mean we're not going to do our editing in a little-endian binary representation? Sheesh!  Wink
Logged

Conquering the world - 8 hex digits at a time.
mcmatrix
Newbie

Offline Offline

Posts: 46



« Reply #63 on: December 14, 2007, 01:00:55 PM »

New version of gfxutil is out!!!
http://forum.netkas.org/index.php?topic=64.0

------------------------

Ok here it is, very first alpha version.
http://rapidshare.com/files/76485904/gfxutil.zip.html

Its very simple program.
It only accepts to files input and output files.

input file has to be binary device-properties (not hex dump) or XML plist file.
output file content depends on input file.
If input file is gfx binary then output is XML plist
and if input is xml plist then output is binary device-properties.

For converting hexdump to binary you may use xxd tool:

'xxd -r -p x3100.hex x3100.bin' will convert from hex to bin
'xxd -p x3100.bin >x3100.hex' will convert from bin to hex

using steps:
1. use xxd to convert from hex to bin
2. use gfxutil to convert from bin to plist file
3. use 'Property List Editor' to modify you settings
4. use gfxutil to convert from plist to bin again
5. use xxd to convert from bin to hex dump

NB! This program is in apha/beta phase. So use it only for betatesting.
I TAKE NO RESPONSEBILITY FOR ANY LOSS, DAMAGE OR INJURY ARISING FROM THE USE OF THIS PROGRAM! 
« Last Edit: December 20, 2007, 09:25:03 AM by mcmatrix » Logged
Thrawnhex
Jr. Member
**
Offline Offline

Posts: 74


« Reply #64 on: December 14, 2007, 01:45:20 PM »

The Converting works for me! But I can't really understand the meanings of values in the data fields. I'll comprehend with other strings...

So thank you!!! And another Question: Is the code free and in which language is is written... i learn objectiv-c and i'd like to watch at the code...

Thrawnhex
Logged
mcmatrix
Newbie

Offline Offline

Posts: 46



« Reply #65 on: December 14, 2007, 01:54:15 PM »

Its base64, it is CoreFoundation property list CFDataRef format.
Binary data will automatically encoded (base64) for saving to xml by CF.

Use "Property List Editor" you can install it from XCode tools.
PL Editor will decode datafields and if you modify them and save then
Editor will encode fields back.
« Last Edit: December 14, 2007, 03:48:44 PM by mcmatrix » Logged
frantisheq
Jr. Member
**
Offline Offline

Posts: 59



« Reply #66 on: December 14, 2007, 03:07:39 PM »

not sure so better to ask Smiley where to get the input file and how do i use exported file? what is this all about? it will generate gfx string from hackintosh or what?

if i understand good i convert hex dump to bin with xxd then use gfxutil util on the bin. edit with property list editor then again plist to bin with gfxutil and bin to hex with xxd. then i add generated hex to boot.plist. OK? stupid question but will this enable me to use 7300GT string on 7300LE?
« Last Edit: December 14, 2007, 03:26:38 PM by frantisheq » Logged
0xdeadbeef
Newbie

Offline Offline

Posts: 25



« Reply #67 on: December 14, 2007, 03:11:14 PM »


Ok here it is, very first alpha version.


Good work! We'll have this efi rubbish fixed yet!  Wink
Logged

Conquering the world - 8 hex digits at a time.
mcmatrix
Newbie

Offline Offline

Posts: 46



« Reply #68 on: December 14, 2007, 03:25:04 PM »

not sure so better to ask Smiley where to get the input file and how do i use exported file? what is this all about? it will generate gfx string from hackintosh or what?

You need to get gfx string from real mac and then you can change/hack it to
make it fit with your computer needs Smiley

The <dict> key contains (long hex key in plist) the important io aadresses. It represents where in iodevicetree registry these device settings will be and following key value pairs are specific device settings that device kext will query from efi.

Correct me if iam wrong.
« Last Edit: December 14, 2007, 03:28:42 PM by mcmatrix » Logged
frantisheq
Jr. Member
**
Offline Offline

Posts: 59



« Reply #69 on: December 14, 2007, 03:27:37 PM »

ok thx. should be in #leopard topic
 i wanted to make string for 7300LE from 7300GT  Tongue couldn't even find 7300GT ID in generated plist  Grin

« Last Edit: December 14, 2007, 05:24:29 PM by frantisheq » Logged
mcmatrix
Newbie

Offline Offline

Posts: 46



« Reply #70 on: December 14, 2007, 05:39:45 PM »

ok thx. should be in #leopard topic
 i wanted to make string for 7300LE from 7300GT  Tongue couldn't even find 7300GT ID in generated plist  Grin



You are free to modify you plist /add/delete/change/   key -> value pairs
or even add or delete dict sub block.
If you know what you are doing then just add device_id propertie into plist.

Only requirement is that value field has to be DATA type.
Logged
netkas
Administrator
Hero Member
*****
Offline Offline

Posts: 799



« Reply #71 on: December 14, 2007, 06:52:49 PM »

there is mostly no devid.

it uses pci adress to ident card, e.g. display@0 or display@2 and etc.. read this thread to find more info
Logged
netkas
Administrator
Hero Member
*****
Offline Offline

Posts: 799



« Reply #72 on: December 15, 2007, 01:40:25 AM »

continuing our mess

e.g. 2600xt

02010C00'D041030A'00000000'01010600'00010101'06000000'7FFF0400
and adress for card is
IODeviceTree:/PCI0@0/POP1@1/display@0
so, u can see 0000 in string, 0101 and 0 at end..

and now sound

02010C00D041030A0000000001010600001B7FFF0400

IODeviceTree:/PCI0@0/pci8086,27d8@1b

that's why string for sound is shorter, it has less parents than display.

soo, lets think  more
p.s. actualy it's 1@10000 and 0@00000 and  etc
« Last Edit: December 15, 2007, 03:22:53 AM by netkas » Logged
netkas
Administrator
Hero Member
*****
Offline Offline

Posts: 799



« Reply #73 on: December 15, 2007, 02:34:10 AM »

a bit more
EfiDevicePath.h

#define EFI_DP_TYPE_MASK                    0x7F
#define EFI_DP_TYPE_UNPACKED                0x80
#define END_DEVICE_PATH_TYPE                0x7f
#define END_ENTIRE_DEVICE_PATH_SUBTYPE      0xff
#define END_INSTANCE_DEVICE_PATH_SUBTYPE    0x01

also files

DevicePathToText.c DevicePathFromText.c

DevicePath.c
« Last Edit: December 15, 2007, 02:53:29 AM by netkas » Logged
netkas
Administrator
Hero Member
*****
Offline Offline

Posts: 799



« Reply #74 on: December 15, 2007, 03:23:40 AM »

my guess - 010106 is sort of separators
so
Code:
02010C00'D041030A'00000000'010106'000001'010106'000000'7FFF0400
           ACPI   00@000000 sepr  01@10000 sep    @0
                   PCI0@0        P0P1@10000
we need to look at things only after @
« Last Edit: December 15, 2007, 03:28:55 AM by netkas » Logged
Pages: 1 ... 3 4 [5] 6 7 ... 15
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.21 | SMF © 2015, Simple Machines
SMFAds for Free Forums
Valid XHTML 1.0! Valid CSS!