RomRaider Logo

RomRaider

Open Source ECU Tools
 FAQ •  Register •  Login 

RomRaider

Documentation

Community

Developers

It is currently Thu Dec 25, 2025 1:16 am

All times are UTC - 5 hours [ DST ]





Post new topic Reply to topic  [ 4 posts ] 
Author Message
 Post subject: 2005 g35 won't reflash
PostPosted: Wed Apr 28, 2021 12:25 am 
Offline
Newbie

Joined: Thu Apr 15, 2021 12:50 am
Posts: 4
Hello,

I was able to successfully download my ROM from my 2005 g35 AT and load it up in RR with the definitions from Pytrex. I disabled a the P0420 code and saved the image. When attempting to reflash I did the p option and get the error.

Code:
> p
reflashing selected blocks (dry run). Note, some (harmless) write verification errors WILL
occur if there are "modified blocks" ! (i.e. ROM file differs from ECU ROM)
        Block 07
Erasing block 7 (0x007000-0x007FFF)...
writing chunk @ 0x007B00 ( 68 %,  4286 B/s, ~    0 s remaining)
        Problem: bad response @ 7B00: post-write verify failed


When I look in the def file it identifies my ECU as a AC700 as does the part number lookup when I do it by VIN. However, in the def file it says that is a ECU for a 2004. Could the checksum locations be different or something? Any suggestions for how to proceed?

Here is what nisprog says when it connects

Code:
nisprog> npconn
Connected to ECU !
Using short headers.
ECUID: AC700
Key candidate   dist (smaller is better)
0: 0xEED9A107   0
1: 0xEC5B98DE   2
2: 0x968148AD   12


Top
 Profile  
 
 Post subject: Re: 2005 g35 won't reflash
PostPosted: Wed Apr 28, 2021 10:01 am 
Offline
RomRaider Donator
User avatar

Joined: Fri Jul 26, 2019 3:35 am
Posts: 789
Location: United States of America
Checksums are more than likely fine. If RomRaider didn’t pick up an error when opening the ROM, then it’s most likely accurate. The error is normal because you’re doing a test flash. You’re not actually reflashing the ROM. If you read the notice, it says that you will get a post write verify error, which is exactly what happened.

Next time, just type “y” to reflash the changed blocks and it’ll flash as intended.

Edit; Make sure to disable both P0420 and P0430.

_________________
NissanDefinitions Repository


Top
 Profile  
 
 Post subject: Re: 2005 g35 won't reflash
PostPosted: Wed Apr 28, 2021 10:07 am 
Offline
Experienced
User avatar

Joined: Wed Jan 08, 2014 11:07 pm
Posts: 652
nwellinghoff wrote:
When attempting to reflash I did the p option and get the error.


Read the 4-5 posts here
viewtopic.php?p=158820#p158820

_________________
If you like nisprog + npkern, you can support me via https://liberapay.com/fenugrec/
For sending me encrypted/secure messages, use PGP key 0xBAC61AEB3A3E6531 available from pool.sks-keyservers.net


Top
 Profile  
 
 Post subject: Re: 2005 g35 won't reflash
PostPosted: Wed Apr 28, 2021 1:35 pm 
Offline
Newbie

Joined: Thu Apr 15, 2021 12:50 am
Posts: 4
Ah, thanks. I was able to reflash after ignoring the error. The error at the end is a little scary for a n00b so that is why I took pause. Maybe if the write verification errors were noted and the error was softened it would save you from having to answer this question again :)

I am no C programmer and couldn't get the build to work with VS but maybe something that gives lets you know its ok and returns success.

Code:
np_backend.c | 12 ++++++++++--
 1 file changed, 10 insertions(+), 2 deletions(-)

diff --git a/np_backend.c b/np_backend.c
index 83c6a70..995e6a5 100644
--- a/np_backend.c
+++ b/np_backend.c
@@ -719,8 +719,13 @@ static int npk_raw_flashblock(const uint8_t *src, uint32_t start, uint32_t len)
             errval = diag_l1_recv(global_l2_conn->diag_link->l2_dl0d, NULL, &rxbuf[errval], needed, 300);
          }
          if (errval < 0) errval = 0;   //floor
-         printf("%s\n", decode_nrc(&rxbuf[1]));
+         char *errstring = decode_nrc(&rxbuf[1]);
+         printf("%s\n", errstring);
          (void) diag_l2_ioctl(global_l2_conn, DIAG_IOCTL_IFLUSH, NULL);
+         //take note that the error was a post-write verify such that the error can be softened in practice mode
+         if (strcmp(errstring, "post-write verify failed") == 0 ) {
+            return -2;
+         }
          return -1;
       }
 
@@ -808,7 +813,10 @@ int reflash_block(const uint8_t *newdata, const struct flashdev_t *fdt, unsigned
 
    /* 4- write */
    errval = npk_raw_flashblock(newdata, start, len);
-   if (errval) {
+   if (practice && errval == -2){
+      printf("\n post-write verify failed errors are expected in practice mode as the ROM was not actually written.");
+   }
+   else if (errval) {
       printf("\nReflash error ! Do not panic, do not reset the ECU immediately. The kernel is "
             "most likely still running and receiving commands !\n");
       goto badexit;


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 4 posts ] 

All times are UTC - 5 hours [ DST ]


Who is online

Users browsing this forum: P1on3R and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
Style based on FI Subsilver by phpBBservice.nl