mirror of https://github.com/rusefi/isotp-c.git
reduce max isotp message size. see OpenXC vi-firmware issue #375 https://github.com/openxc/vi-firmware/issues/375. (#5)
This commit is contained in:
parent
4e7375321a
commit
ee24440b7c
|
@ -10,7 +10,7 @@
|
||||||
// TODO we want to avoid malloc, and we can't be allocated 4K on the stack for
|
// TODO we want to avoid malloc, and we can't be allocated 4K on the stack for
|
||||||
// each IsoTpMessage, so for now we're setting an artificial max message size
|
// each IsoTpMessage, so for now we're setting an artificial max message size
|
||||||
// here - for most multi-frame use cases, 256 bytes is plenty.
|
// here - for most multi-frame use cases, 256 bytes is plenty.
|
||||||
#define OUR_MAX_ISO_TP_MESSAGE_SIZE 256
|
#define OUR_MAX_ISO_TP_MESSAGE_SIZE 127
|
||||||
|
|
||||||
/* Private: IsoTp nibble specifics for PCI and Payload.
|
/* Private: IsoTp nibble specifics for PCI and Payload.
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -136,7 +136,7 @@ END_TEST
|
||||||
|
|
||||||
START_TEST (test_receive_large_multi_frame)
|
START_TEST (test_receive_large_multi_frame)
|
||||||
{
|
{
|
||||||
const uint8_t data0[CAN_MESSAGE_BYTE_SIZE] = {0x11, 0x01, 0x49, 0x02, 0x01, 0x31, 0x46, 0x4d};
|
const uint8_t data0[CAN_MESSAGE_BYTE_SIZE] = {0x10, 0x80, 0x49, 0x02, 0x01, 0x31, 0x46, 0x4d};
|
||||||
IsoTpMessage message = isotp_continue_receive(&SHIMS, &RECEIVE_HANDLE, 0x2a, data0, 8);
|
IsoTpMessage message = isotp_continue_receive(&SHIMS, &RECEIVE_HANDLE, 0x2a, data0, 8);
|
||||||
//Make sure we don't try to receive messages that are too large and don't send flow control.
|
//Make sure we don't try to receive messages that are too large and don't send flow control.
|
||||||
fail_unless(!can_frame_was_sent);
|
fail_unless(!can_frame_was_sent);
|
||||||
|
|
Loading…
Reference in New Issue