Seems like there could be a bug in the Bit Mode Channel Mapping. Bits with offset >20 don't seem to work. The green highlighted bits work. I have toggled the ECU internal variables for lamctrl_b and oillamp_b and see the corresponding signals toggle in the RC Dashboard. The yellow highlighted ones don't seem to work. RC Track configuration file attached.
Yes, the raw values of 0x77A Byte 2 all work. With a simple 1:1 conversion I can toggle bits 4, 5, 6, 7 and see the physical value for that Byte change accordingly in the Dashboard.
And no, I didn't try Byte 3 yet, so I can't say if this is only limited to bit offset 21 to 24, or if also higher is affected.
Bug in Bit Mode Channel Mapping? Doesn't work above 20?
Bug in Bit Mode Channel Mapping? Doesn't work above 20?
- Attachments
-
- 20191208.zip
- RC Track configuration with CAN channel mapping. (Well, that's awkward. Can't directly upload .rcp files....)
- (3.95 KiB) Downloaded 422 times
-
- Description of bit states
- 77A_FRM_snapshot.png (53.08 KiB) Viewed 12563 times
-
- CAN definition file snapshot
- 77A_DBC_snapshot.png (24.29 KiB) Viewed 12563 times
I'm trying to use the "Bit Mode" to map individual signal to a 0/1 bit flag. It's much more convenient than bitmasking the byte via Lua script.
It works up to 20. So oillamp_b work just fine. But mil_b, laptrig_b and lap_b don't work. It's like Offset >20 just doesn't work. I've tried both Little and Big Endian. And yes, I see the values change when I map the entire Byte 2. No signals mapped with Offset >20 work.
It works up to 20. So oillamp_b work just fine. But mil_b, laptrig_b and lap_b don't work. It's like Offset >20 just doesn't work. I've tried both Little and Big Endian. And yes, I see the values change when I map the entire Byte 2. No signals mapped with Offset >20 work.
- Attachments
-
- Bit_Mode.png (153.99 KiB) Viewed 12547 times
Tracking here:
https://github.com/autosportlabs/RaceCa ... ssues/1070
What we will do to reproduce is to connect CAN1 and CAN2 in loopback, and then send data from CAN1 to CAN2 using Lua, and test for the expected behavior by using the direct mapping on CAN2.
https://github.com/autosportlabs/RaceCa ... ssues/1070
What we will do to reproduce is to connect CAN1 and CAN2 in loopback, and then send data from CAN1 to CAN2 using Lua, and test for the expected behavior by using the direct mapping on CAN2.
Re: Bug in Bit Mode Channel Mapping? Doesn't work above 20?
Still have it in the issue tracker, we'll see what we can do with it.
Re: Bug in Bit Mode Channel Mapping? Doesn't work above 20?
@brentp I figured it out. It's not that they don't work above 20, it's that the bit numbering is backwards.
viewtopic.php?f=38&t=6314
I'm hoping this is an easy fix, and you can get this updated right away since all you have to do is start counting from the other end
P.S. so I think it was kind of dumb luck that I got some bits to work correctly by adding 1 to the offset.
viewtopic.php?f=38&t=6314
I'm hoping this is an easy fix, and you can get this updated right away since all you have to do is start counting from the other end
P.S. so I think it was kind of dumb luck that I got some bits to work correctly by adding 1 to the offset.