RomRaider Logo

RomRaider

Open Source ECU Tools
 FAQ •  Register •  Login 

RomRaider

Documentation

Community

Developers

It is currently Tue Dec 23, 2025 9:12 am

All times are UTC - 5 hours [ DST ]





Post new topic Reply to topic  [ 6 posts ] 
Author Message
 Post subject: Switches, Bitwise Switches, and DTCs?
PostPosted: Sun Sep 20, 2020 12:15 am 
Offline
RomRaider Donator
User avatar

Joined: Fri Jul 26, 2019 3:35 am
Posts: 789
Location: United States of America
Hello all!

Would anyone be able to help provide some knowledge on these things? So with switches, I noticed it has data set in hex IN the definition template. NOT in the definition file. Does that mean switches have to be added to the definition template per ECUID, or is the data being presented inside the definition template as hex just required for RomRaider to allow it? On top of this, how would you even be able to figure out where some of these switches are? By the small sample size, it looks like they're similar to bitwise switches. So what's with having two separate switch types?

Onto DTCs; Through cross referencing I was able to locate a few of the DTC bitwiseswitches, DTC supmask, DTC descriptor, and DTC Options. So I was able to find a lot of stuff for enabling the LOGIC, but is there any way to force enable a DTC for testing purposes?

_________________
NissanDefinitions Repository


Top
 Profile  
 
 Post subject: Re: Switches, Bitwise Switches, and DTCs?
PostPosted: Wed Oct 07, 2020 12:22 am 
Offline
Experienced

Joined: Sat Jun 24, 2017 2:23 pm
Posts: 315
Romraider previously only supported the radio button type switches. These are the ones where you can replace bytes with alternative bytes to accomplish a desired behavior. This is a very powerful tool, but would require cumbersome definitions to manipulate even an 8bit bitwise byte. For example, 256 combinations would be required to set the preference for 8 DTCs.

Bitwise editing allows you to drill down further to the individual bits, and so you only need 8 definitions for that same byte. As seen in the CID supmasks, this can be down 32 bits at a time. As a 4-byte "long" data type, this would require 2^32=4,294,967,296 combination options.

With regard to where you find the definition templates, this is dependent on whether the template will be universally applicable to all ROMS, or if the bytes may differ on unique ECUs. If one is modifying code rather than data, it is unlikely that the same modification will apply universally, so the switch is placed in a ROM specific definition rather than the base template.

With regards to force testing a DTC. The only way I am aware of is to turn on the logic by flashing. Then manually create the fault.


Top
 Profile  
 
 Post subject: Re: Switches, Bitwise Switches, and DTCs?
PostPosted: Wed Oct 07, 2020 12:58 am 
Offline
RomRaider Donator
User avatar

Joined: Fri Jul 26, 2019 3:35 am
Posts: 789
Location: United States of America
a33b wrote:
Romraider previously only supported the radio button type switches. These are the ones where you can replace bytes with alternative bytes to accomplish a desired behavior. This is a very powerful tool, but would require cumbersome definitions to manipulate even an 8bit bitwise byte. For example, 256 combinations would be required to set the preference for 8 DTCs.

Bitwise editing allows you to drill down further to the individual bits, and so you only need 8 definitions for that same byte. As seen in the CID supmasks, this can be down 32 bits at a time. As a 4-byte "long" data type, this would require 2^32=4,294,967,296 combination options.

With regard to where you find the definition templates, this is dependent on whether the template will be universally applicable to all ROMS, or if the bytes may differ on unique ECUs. If one is modifying code rather than data, it is unlikely that the same modification will apply universally, so the switch is placed in a ROM specific definition rather than the base template.

With regards to force testing a DTC. The only way I am aware of is to turn on the logic by flashing. Then manually create the fault.


Tons of good information there! Thank you so much for sharing! It’ll definitely help me out quite a bit with figuring out some of these supmasks and such! :) It’s a shame about the forcing DTCs thing, however. It doesn’t sound like a fun time haha I wish we could force trigger DTCs under certain scenarios. Mainly for boosted applications or for custom systems. But that’s probably getting into custom ECU territory haha

_________________
NissanDefinitions Repository


Top
 Profile  
 
 Post subject: Re: Switches, Bitwise Switches, and DTCs?
PostPosted: Tue Sep 10, 2024 10:29 am 
Offline
Newbie

Joined: Wed Jun 01, 2022 9:57 am
Posts: 6
Attachment:
2006 Maxima 1ZK01B DTCs.png


I am working on a 2006 Maxima ZK01B and was wondering if anyone had pointers on finding the DTC supmask & DTC bitwiseswitches?
The Descriptor & Options are very easy to find but the others are giving me some headache because I don't understand the logic. I have Ghidra but I am still learning my way around that software.


You do not have the required permissions to view the files attached to this post.


Top
 Profile  
 
 Post subject: Re: Switches, Bitwise Switches, and DTCs?
PostPosted: Tue Sep 10, 2024 11:36 am 
Offline
Newbie

Joined: Wed Jun 01, 2022 9:57 am
Posts: 6
Attachment:
DTC SupMask.png


No idea if this is correct but via the learning and logic here it looks good. Going to flash & check it. Any tips would be greatly appreciated.


You do not have the required permissions to view the files attached to this post.


Top
 Profile  
 
 Post subject: Re: Switches, Bitwise Switches, and DTCs?
PostPosted: Fri Sep 13, 2024 5:32 pm 
Offline
Newbie

Joined: Sat Nov 23, 2019 5:02 pm
Posts: 37
I have bitedit if you want to test some dtc off


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

All times are UTC - 5 hours [ DST ]


Who is online

Users browsing this forum: No registered users 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