Each of the numbers you see in the can monitor is an 8 bit number in hex format, which as the name implies has 8 bits, bit0=1, bit1=2, bit2=4, bit3=8, bit4=16, bit5=32, bit6=64, bit7=128 with a maximum value of 255 or FF in hexadecimal. If the number you have highlighted is 0 when the rear defrost is off and 80 when its on, this corresponds to bit7 and 128 in decimal
am I limited to using the startbit method, or for on/off can I also use the “offset” and “length” method for making this work. Seems like you can use both ways.
No both methods can be used. In your Parking Brake example which is in frame 0x620, this is showing as 0x10 in hex and 16 in decimal, hence bit 4 in the last byte 7 of the frame. Each frame has 8 bytes (0-7) and each byte has 8 bits, therefore, total 64 bits (0-63).
Using startbit method, you are selecting the startbit position within the entire frame
value targetId=”164” startbit=”60” bitcount=”1”
Using offset method, you are selecting the byte within the frame, but then need to manipulate into the single bit of interest i.e. bit 4
value targetId=”164” offset=”7” length=”1” units=”bit” conversion=”V>>4”
The units=”bit” makes RealDash read only the bit in position 0, the conversion bit shift moves bit 4 (16) into the bit0 position. Hope this makes sense.