mirror of https://github.com/rusefi/rusefi-1.git
parent
0c578dde4a
commit
a071e2a168
|
@ -146,14 +146,15 @@ static void populateFrame(Fueling2& msg) {
|
||||||
|
|
||||||
void sendCanVerbose() {
|
void sendCanVerbose() {
|
||||||
auto base = engineConfiguration->verboseCanBaseAddress;
|
auto base = engineConfiguration->verboseCanBaseAddress;
|
||||||
|
auto isExt = engineConfiguration->rusefiVerbose29b;
|
||||||
|
|
||||||
transmitStruct<Status> (base + 0);
|
transmitStruct<Status> (base + 0, isExt);
|
||||||
transmitStruct<Speeds> (base + 1);
|
transmitStruct<Speeds> (base + 1, isExt);
|
||||||
transmitStruct<PedalAndTps> (base + CAN_PEDAL_TPS_OFFSET);
|
transmitStruct<PedalAndTps> (base + CAN_PEDAL_TPS_OFFSET, isExt);
|
||||||
transmitStruct<Sensors1> (base + CAN_SENSOR_1_OFFSET);
|
transmitStruct<Sensors1> (base + CAN_SENSOR_1_OFFSET, isExt);
|
||||||
transmitStruct<Sensors2> (base + 4);
|
transmitStruct<Sensors2> (base + 4, isExt);
|
||||||
transmitStruct<Fueling> (base + 5);
|
transmitStruct<Fueling> (base + 5, isExt);
|
||||||
transmitStruct<Fueling2> (base + 6);
|
transmitStruct<Fueling2> (base + 6, isExt);
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif // EFI_CAN_SUPPORT
|
#endif // EFI_CAN_SUPPORT
|
||||||
|
|
|
@ -82,7 +82,7 @@ class CanTxTyped final : public CanTxMessage
|
||||||
#endif // EFI_CAN_SUPPORT
|
#endif // EFI_CAN_SUPPORT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
explicit CanTxTyped(uint32_t eid) : CanTxMessage(eid, sizeof(TData)) { }
|
explicit CanTxTyped(uint32_t id, bool isExtended) : CanTxMessage(id, sizeof(TData), isExtended) { }
|
||||||
|
|
||||||
#if EFI_CAN_SUPPORT
|
#if EFI_CAN_SUPPORT
|
||||||
/**
|
/**
|
||||||
|
@ -103,9 +103,9 @@ public:
|
||||||
};
|
};
|
||||||
|
|
||||||
template <typename TData>
|
template <typename TData>
|
||||||
void transmitStruct(uint32_t eid)
|
void transmitStruct(uint32_t id, bool isExtended)
|
||||||
{
|
{
|
||||||
CanTxTyped<TData> frame(eid);
|
CanTxTyped<TData> frame(id, isExtended);
|
||||||
// Destruction of an instance of CanTxMessage will transmit the message over the wire.
|
// Destruction of an instance of CanTxMessage will transmit the message over the wire.
|
||||||
// see CanTxMessage::~CanTxMessage()
|
// see CanTxMessage::~CanTxMessage()
|
||||||
populateFrame(frame.get());
|
populateFrame(frame.get());
|
||||||
|
|
|
@ -733,7 +733,7 @@ bit is_enabled_spi_1
|
||||||
bit is_enabled_spi_2
|
bit is_enabled_spi_2
|
||||||
bit is_enabled_spi_3
|
bit is_enabled_spi_3
|
||||||
bit isSdCardEnabled;enable sd/disable sd
|
bit isSdCardEnabled;enable sd/disable sd
|
||||||
bit unused744b4
|
bit rusefiVerbose29b,"29 bit","11 bit";+Use 11 bit (standard) or 29 bit (extended) IDs for rusEFI verbose CAN format.
|
||||||
bit isEngineControlEnabled
|
bit isEngineControlEnabled
|
||||||
bit isHip9011Enabled
|
bit isHip9011Enabled
|
||||||
bit isVerboseAlternator
|
bit isVerboseAlternator
|
||||||
|
|
|
@ -3191,6 +3191,7 @@ cmd_set_engine_type_default = "@@TS_IO_TEST_COMMAND_char@@\x00\x31\x00\x00"
|
||||||
field = "inertia measurement unit", imuType
|
field = "inertia measurement unit", imuType
|
||||||
field = "Enable rusEFI CAN broadcast", enableVerboseCanTx
|
field = "Enable rusEFI CAN broadcast", enableVerboseCanTx
|
||||||
field = "rusEFI CAN data base address", verboseCanBaseAddress
|
field = "rusEFI CAN data base address", verboseCanBaseAddress
|
||||||
|
field = "rusEFI CAN data address type", rusefiVerbose29b
|
||||||
field = "rusEFI CAN data period", canSleepPeriodMs
|
field = "rusEFI CAN data period", canSleepPeriodMs
|
||||||
field = "RX pin", canRxPin @@if_ts_show_can_pins
|
field = "RX pin", canRxPin @@if_ts_show_can_pins
|
||||||
field = "TX pin", canTxPin @@if_ts_show_can_pins
|
field = "TX pin", canTxPin @@if_ts_show_can_pins
|
||||||
|
|
Loading…
Reference in New Issue