Форум владельцев и любителей БМВ

Форум владельцев и любителей БМВ (https://bmwpost.ru/forum/)
-   Диагностика BMW | кодирование | программирование (https://bmwpost.ru/forum/diagnostika-bmw-kodirovanie-programmirovanie-59/)
-   -   Язык и PRG (https://bmwpost.ru/forum/diagnostika-bmw-kodirovanie-programmirovanie-59/sszyk-i-prg-9332/)

вова 1951 16.11.2010 20:21

Язык и PRG
 
PRG я так понимаю бинарник. Обьяните пж, причем здесь язык:shock:

bmw628 16.11.2010 20:39

Все дело в языке описания ошибок...

вова 1951 16.11.2010 21:39

Цитата:

Сообщение от bmw628 (Сообщение 81846)
Все дело в языке описания ошибок...

Вот это другое дело:wave:

zass 16.11.2010 22:17

...так.. эт... открой тулом и все прояснитси..

вова 1951 17.11.2010 09:00

Цитата:

Сообщение от zass (Сообщение 81876)
...так.. эт... открой тулом и все прояснитси..

Спасибо. Я так и делал:wave:

Dimonaff 25.12.2010 22:07

а есть ли возможность редактирования этих файлов? интересует именно таблицы данныл, локализация под рус яз, в туллс залез, он только читает файлы..

zass 26.12.2010 00:49

а это нужно?
.. есть DIS

Dimonaff 26.12.2010 01:20

очень нужно

Dimonaff 07.01.2011 20:36

Ну так что? никто не пробовал модифицировать prg файлы? tool32 открывает файлы, да там можно поглядеть на часть содержимого. но редактировать не дает. xtract на сколько я понял может извлекать содержимое, а как им пользоваться и как потом запаковать назад? Нужна любая информация, пойдет даже хоть малейшее описание формата файла, в крайнем случае попробую сам редактор смострячить

Dimonaff 07.01.2011 22:48

На сайте БМВ вычитал о таких утилитах - PAFMaker, SWE-Generator, XBD-Generator, Muster-PABD, P-SGBD
Используются для разработки и диагностики как я понял, может кто их имеет в своем распоряжении?

bmwnsk 08.01.2011 12:00

судя по ярлыкам две из перечисленного относятся к e-sys

Dimonaff 09.01.2011 08:00

а что это такое есть? и где можно достать?

zass 09.01.2011 13:59

..доставание оного не решит вопрос редактирования .prg

Dimonaff 10.01.2011 23:33

откуда мне знать что оно решит? ведь у меня ни программ ни инфы как таковой нет, на диллере я не работаю, а пальцем тыкать в текстовом редакторе ничего не решит.
Кто может помочь помогите, кто не может - я не задерживаю и не отвлекаю от ваших важных занятий

yuri89 03.10.2012 09:19

Вложений: 9
Цитата:

Сообщение от Dimonaff (Сообщение 92598)
откуда мне знать что оно решит? ведь у меня ни программ ни инфы как таковой нет, на диллере я не работаю, а пальцем тыкать в текстовом редакторе ничего не решит.
Кто может помочь помогите, кто не может - я не задерживаю и не отвлекаю от ваших важных занятий

Если еще актуально, принимай.

Argos 03.10.2012 09:49

XBD-Generator_2.3.3.part4 архив косячный,перезалей плиз)

Argos 03.10.2012 10:02

ты лучше одним архивом сделай и ссылку на скачку дай...

yuri89 03.10.2012 11:58

Вложений: 1
Цитата:

Сообщение от Argos (Сообщение 210618)
XBD-Generator_2.3.3.part4 архив косячный,перезалей плиз)

перезалил
возможно это тоже пригодится (пункт 3.2 = распаковка prg) и еще в гугле наберите "real time data logging" без кавычек = первая найденная ссылка тоже познавательная.
цитата:
Basically, all you need to do is read the file inpa_english.pdf in the folder \EC-APPS\INPA\DOKU
It contains a complete explanation of how the entire system works and is what I used to get my simple SMG data logging up and running.

As a primer though, I'll run through the basic concepts:

1. IPS file - you create an IPS file which contains descriptions of the screens and menus you want, written in INPA's high-level programming language. It has some VERY rudimentary programming functions available, one of which is fileopen(filename, mode) which creates or opens a file and filewrite(string) which will append the string to the file that has been opened.

2. Once written, you compile your IPS file using INPACOMP.EXE which produces an IPO file and an INI file. These are the files that INPA actually runs - when you use INPA "normally" all it is doing is running a standard set of IPO files from BMW.

3. When writing a screen definition, the structure you follow is broadly:

i. Send a job request to the OBD
ii. Wait for the OBD to report that the job is complete
iii. Read the results of the request that you are interested in to variables
iv. Display them on-screen or write them to your log file

For part (i) above, you need to know both the module to interrogate and the job name that you want it to run. For part (iii) you need to know the result name that you're interested in. This is the time-consuming bit, as everything is in German:

•3.1 Work out which ECU you want to interrogate. The available ECUs are listed in the folder C:\EDIABAS\ECU\
Each .PRG file is an ECU descriptor containing the job names and result values for that ECU. Because I wanted to interrogate the SMG ECU, I worked out pretty quickly that the file I was interested in was SMG2.PRG


•3.2 Use the program C:\EDIABAS\BIN\XTRACT.EXE to list the contents of your chosen PRG file. Eg. for my SMG job, the command I needed was:
XTRACT C:\EDIABAS\ECU\SMG2.PRG -F
The -F on the end causes it to dump the results to a file (SMG2.PRV) rather than the screen


•3.3 Open the file created in Notepad. The file lists all the jobs and results in German. For example, part of the SMG2 results are:
JOBNAME:INITIALISIERUNG
JOBCOMMENT:Init-Job fuer EGS

This is saying that there is a job available called "INITIALISIERUNG" and the brief description is "Init job for EGS". Beneath each job, all the possible results are listed, e.g.:

RESULT: DONE
RESULTTYPE:int
RESULTCOMMENT:1 wenn OKAY

This is saying that the first result value returned is called "DONE", it is a number (int) and it's value is "1" when the job is complete. Note that not all results are necessarily described in the file, sometimes you just have to read the result and try to make sense of it yourself!

So, in our IPS file if we wanted to run that job and read that result, the commands would be:
INPAapiJob("smg2", "INITIALISIERUNG");
to run the job, then once the "OKAY" result is returned, we can read the other results. For the result called "DONE" we could use:

INPAapiResultInt( my_result_variable, "DONE");

This would put the value of the result called "DONE" into the variable my_result_variable

For my project, I found Google Translate a total Godsend - simply copy and paste the XTRACT results in and look for jobs that seem interesting!

4. When displaying screens, INPA continuously cycles through the definition, constantly running the job, reading the results and displaying them, until you press a key to change the view. To display the results, you just pass the variables containing the results to one of INPAs predefined functions - you'll notice there are only a few "widgets" in INPA for displaying info, some are bar graphs, others are dots, etc. Each widget is simply an INPA function. For data logging, you don't even need to know about these functions though, you just pass your variables to filewrite() to dump them in the file.

5. Details of data logging: The filewrite() function simply writes a string to the currently open file and adds a linefeed to the end. Therefore to get a useful file you need to join all the job results together into one string, separated by commas, and write that string to the file. Excel will then recognise the file as a CSV file and load it up into columns of results. To create your string of comma-separated values, use strcat().

Argos 03.10.2012 21:59

[Ссылки могут видеть только зарегистрированные пользователи. Зарегистрироваться...] какую строчку?...

yuri89 11.10.2012 13:48

Цитата:

Сообщение от Argos (Сообщение 210764)
[Ссылки могут видеть только зарегистрированные пользователи. Зарегистрироваться...] какую строчку?...

эту:
[Ссылки могут видеть только зарегистрированные пользователи. Зарегистрироваться...]


Часовой пояс GMT +3, время: 08:17.

Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.

Перевод: zCarot

Форум BMW (БМВ)