Innovate-motorsports OT-2 SDK Manuale Utente

Navigare online o scaricare Manuale Utente per Strumenti di misura Innovate-motorsports OT-2 SDK. Innovate Motorsports OT-2 SDK User Manual Manuale Utente

  • Scaricare
  • Aggiungi ai miei manuali
  • Stampa
  • Pagina
    / 76
  • Indice
  • SEGNALIBRI
  • Valutato. / 5. Basato su recensioni clienti
Vedere la pagina 0
1
Innovate Motorsports
OT-1b/2 SDK
Version 1.3
Disclaimer: Information in this document is being provided as-is without any
warranty/guarantee of any kind. Innovate Motorsports has taken all reasonable
measures to ensure the quality, reliability, and accuracy of the information in this
document. But if you corrupt an ECU, melt the casing off your computer, or
experience some other terrible calamity, it is not our problem. Feel free to let us
know, we might enjoy laughing at your misfortune, but please do not sue us. You
have been warned!
Vedere la pagina 0
1 2 3 4 5 6 ... 75 76

Sommario

Pagina 1 - Version 1.3

1 Innovate Motorsports OT-1b/2 SDK Version 1.3 Disclaimer: Information in this document is being provided as-is without any warranty/guarantee

Pagina 2 - Table of Contents

10 When our host connects to the OT-2 via Wi-Fi, it is virtually connecting to the physical serial OUT on the device. That is, it starts seeing the s

Pagina 3

11 Not only does it see them, the second LC-1 specifically has to pass them on, transmitting them on its own serial OUT connector, for the data to ev

Pagina 4

12 Second, ‘Commands’: Third, and finally, the more complicated ‘Query’: So, for MTS “In Band” communication (normal), the Host receives two k

Pagina 5 - Revision History:

13 Packets in General As covered above, in ‘in band’ (normal) MTS communication, hosts receive two types of packets, data, and query responses. The

Pagina 6 - Introduction

14 The last piece of information that we generally care about is the packet type (remember, we have two): Word Bit15 Bit14 Bit 13 Bit 12 Bit 11 Bit

Pagina 7

15 It has room for 13 bits of data, but all Innovate Devices only use 10 bits. The reason is legacy/historical. Notice that there is no indication of

Pagina 8 - Prerequisites

16 000 Lambda valid, lambda value contains lambda reading in .001 lambda increments Offset by .5 lambda (0x000 = .5 lambda, 0x3FF = 1.523 lam

Pagina 9 - Basic Scheme

17 3 0 0 0 0 0 Ax19 Ax18 Ax17 0 Ax16 Ax15 Ax14 Ax13 Ax12 Ax11 Ax10 4 0 0 0 0 0 Ax29 Ax28 Ax27 0 Ax26 Ax25 Ax24 Ax23 Ax22 Ax21 Ax20 5 0 0 0 0

Pagina 10

18 N 0 0 0 0 0 0 0 D7 0 D6 D5 D3 D3 D2 D1 D0 This leaves the 4 Words (sometimes easier to think of as 8 bytes in this case) that each device provide

Pagina 11

19 At the time of this writing this would be: Device Channels LC-1 (fixed) 1 Lambda LM-1 (fixed) 1 Lambda (old) + 5 Aux LMA-3 (fixed) 5 Aux DL-32 (f

Pagina 12

2 Table of Contents Revision History:...

Pagina 13 - Packets in General

20 Get to the Good Stuff! OK, you’ve waded though more stuff on in band MTS communication than any sane person would ever want to know. Just think o

Pagina 14 - Data Packets

21 This means that we are no longer receiving packets from the LC-1s in the example above. In addition, the gauge is no longer receiving information.

Pagina 15 - ‘New’ Lambda/AFR Channels

22 The Firmware Version and Identifier should be exactly the same as the response that you got for the in band Query Device Types (0xF3). This can be

Pagina 16

23 Command ‘S’ - Get Setup Mode Header Sent: 1 byte { U8 Cmd; // ‘S’ } Responds: 15 bytes { U8 VersionH; // Firmware version MSB

Pagina 17 - Response Packets

24 Command ‘j’ – Get OBD-II Connection Status Sent: 1 byte { U8 Cmd; // ‘j’ } Responds: 33 bytes { U8 Status; // Connection Status

Pagina 18

25 Command ‘k’ – Get OBD-II Diagnostic Trouble Codes (DTCs) Sent: 1 byte { U8 Cmd; // ‘k’ } Responds: 33 bytes { U8 Count; // Number

Pagina 19 - Commands

26 Command ‘l’ – Get Last OBD-II Loop Time Sent: 1 byte { U8 Cmd; // ‘l’ } Responds: 2 bytes { U16 Time; // Time in mS of last OBD-I

Pagina 20 - Get to the Good Stuff!

27 Command ‘t’ – Get Basic Emissions Status Sent: 1 byte { U8 Cmd; // ‘t’ } Responds: 5 bytes { U8 Count; // char count (norm. 4) //

Pagina 21

28 Command ‘C’ – Set Device Configuration Sent: 37 bytes { U8 Cmd; // ‘C’ U8 Channels; // Number of channels (16 max) U8 Protocol; // OBD

Pagina 22 - Setup Mode Commands

29 Command ‘M’ – Set ‘My’ (temporary) Device Configuration Sent: 37 bytes { U8 Cmd; // ‘M’ U8 Channels; // Number of channels (16 max) U8

Pagina 23

3 Command ‘O’ – Output Data and (optionally) look for input ...42 Command ‘I’ – Look for Input Data ...

Pagina 24

30 Command ‘w’ – Get Wi-Fi Settings Sent: 1 byte { U8 Cmd; // ‘w’ } Responds: 16 bytes { U8 HWAddr[6]; // MAC Address U32 IPAddr;

Pagina 25

31 Command 0xFF – Don’t hang up on me! Sent: 1 bytes { U8 Cmd; // 0xFF } Responds: None Notes: This command merely gives you a way to t

Pagina 26

32 Understanding OT-1b/2 Device Configuration To fully understand the Device Configuration (which can be obtained with the ‘c’ command, and set with

Pagina 27

33 A separate diagram shows how low priority channels fit into the loop. Only one is read each time around. The manual then shows this scheme

Pagina 28

34 Now that we understand ‘Normalized PIDs’ and ‘Priority’, let’s look at the response to the ‘Get Configuration’ (‘c’) command again: Responds: 3

Pagina 29

35 Benefits of In Band Mode The reasons for Innovate using MTS In Band Mode are pretty clear, it makes OBD-II compatible with our existing product l

Pagina 30

36 Expert Modes As mentioned earlier, Expert Modes are entered using the ‘e’ command from Setup Mode. They are specialized ‘sub modes’, each dedicat

Pagina 31

37 Unlike In Band mode, MTS packets are not ‘pushed’ to the virtual OUT connection in Expert Modes. You can poll the last MTS packet passed with t

Pagina 32

38 Special Considerations Entering Expert Modes Before entering an Expert Mode, the OT-1b/2 firmware cleanly suspends the thread that normally does

Pagina 33

39 Can The general flow with Can Expert Mode (‘e’<1>), is: 1. Select a rate (250 Kbit or 500 Kbit) 2. Set up filters for the CAN identifier

Pagina 34

4 IMS USB under Windows...64 Other Platforms ...

Pagina 35 - Benefits of In Band Mode

40 Command ‘r’ – Get the Protocol Rate Sent: 1 byte { U8 Cmd; // ‘r’ } Responds: 1 byte { U8 Result; // Current rate // 1 = 250 Kbit

Pagina 36 - Expert Modes

41 Command ‘f’ – Clear all Pass Filters Sent: 1 byte { U8 Cmd; // ‘f’ } Responds: 1 byte { U8 Result; // Should be 0 } Notes: Clear a

Pagina 37

42 Command ‘e’ – Clear all Handshake Filters Sent: 1 byte { U8 Cmd; // ‘e’ } Responds: 1 byte { U8 Result; // Should be 0 } Notes: Cl

Pagina 38

43 Command ‘I’ – Look for Input Data Sent: 3 bytes { U8 Cmd; // ‘I’ U8 Timeout; // Timeout (in mS) for responses U8 Replies; /

Pagina 39

44 Command ‘b’ – Get Last MTS Packet passed Sent: 1 bytes { U8 Cmd; // ‘b’ } Responds: Variable (2 bytes minimum) { U8 Len; // Length o

Pagina 40

45 J1850 The general flow with J1850 Expert Mode (‘e’<2>), is: 1. Select a ‘rate’ (PWM or VPW, really selecting rate, voltage and encoding)

Pagina 41

46 Command ‘F’ – Add a Pass Filter Sent: 7 bytes { U8 Cmd; // ‘F’ U8 Header; // Header to pass on U8 Destination; // Destination address t

Pagina 42

47 Command ‘O’ – Output Data and (optionally) look for input Sent: Variable { U8 Cmd; // ‘O’ U8 Timeout; // Timeout (in mS) for respons

Pagina 43

48 Command ‘I’ – Look for Input Data Sent: 3 bytes { U8 Cmd; // ‘I’ U8 Timeout; // Timeout (in mS) for responses U8 Replies; /

Pagina 44

49 Command ‘b’ – Get Last MTS Packet passed Sent: 1 bytes { U8 Cmd; // ‘b’ } Responds: Variable (2 bytes minimum) { U8 Len; // Length o

Pagina 45

5 Revision History: Rev Date Author Description 1.0 11/20/09 jjf Initial version 1.1 12/02/09 jjf Structure typo fixes in Setup Mode

Pagina 46

50 ISO The general flow with ISO Expert Mode (‘e’<3>), is: 1. Select a protocol (ISO 9141 or KWP 2000) 2. Setup filters for the messages y

Pagina 47

51 Command ‘F’ – Add a Pass Filter Sent: 7 bytes { U8 Cmd; // ‘F’ U8 Header; // Header to pass on U8 Destination; // Destination address t

Pagina 48

52 Command ‘O’ – Output Data and (optionally) look for input Sent: Variable { U8 Cmd; // ‘O’ U8 Timeout; // Timeout (in mS) for

Pagina 49

53 Command ‘I’ – Look for Input Data Sent: 3 bytes { U8 Cmd; // ‘I’ U8 Timeout; // Timeout (in mS) for responses U8 DataLen; /

Pagina 50

54 Command ‘5’ – Perform standard 5 Baud Initialization Sent: 1 byte { U8 Cmd; // ‘5’ } Responds: 1 byte { U8 Result; // 0=failed

Pagina 51

55 Command ‘L’ – Set the Vehicle LED State Sent: 2 bytes { U8 Cmd; // ‘L’ U8 State; // 0 = off // 1 = on } Responds: 1 byte { U8 Res

Pagina 52 -

56 Command 0xFF – Don’t hang up on me! Sent: 1 bytes { U8 Cmd; // 0xFF } Responds: 1 byte { U8 Result; // should be 0xFF

Pagina 53

57 ISO Raw The general flow with ISO Raw Expert Mode (‘e’<4>), is: 1. Select a baud rate 2. Output bytes and optionally receive bytes ISO

Pagina 54

58 Command ‘O’ – Output Data and (optionally) look for input Sent: Variable { U8 Cmd; // ‘O’ U8 Timeout; // Timeout (in mS) for

Pagina 55

59 Command ‘I’ – Look for Input Data Sent: 3 bytes { U8 Cmd; // ‘I’ U8 Timeout; // Timeout (in mS) for responses U8 Replies; /

Pagina 56

6 Introduction Welcome to the world of OT-1b/2 Programming! Hopefully, this document and the accompanying sample applications should make the proces

Pagina 57 - ISO Raw

60 Command ‘5’ – Perform standard 5 Baud Initialization Sent: 1 byte { U8 Cmd; // ‘5’ } Responds: 1 byte { U8 Result; // 0=failed

Pagina 58

61 Command ‘0’ – Send a 00h at 5 baud on the K line Sent: 1 byte { U8 Cmd; // ‘0’ } Responds: 1 byte { U8 Result; // always 1 } Not

Pagina 59

62 Command ‘b’ – Get Last MTS Packet passed Sent: 1 bytes { U8 Cmd; // ‘b’ } Responds: Variable (2 bytes minimum) { U8 Len; // Length o

Pagina 60

63 But How Do I Connect?! If you have reached this point, you now have a wealth of information. You know how to read MTS packets, configure the OT-1

Pagina 61

64 Tablet’, via serial plug-and-play. This requires fiddling with the Windows device manager to rectify. Perhaps one of the most frustrating problems

Pagina 62

65 The interface is byte oriented, and only involves a few calls: Discovery BOOL imsusbCanConnect(BOOL *inuse); // OUT: indicates if the reason fo

Pagina 63 - But How Do I Connect?!

66 Send a byte to the device. Returns: TRUE on success, FALSE on failure int imsusbPutBytes(int len, // Number of bytes to write BYTE *d

Pagina 64 - IMS USB under Windows

67 So no host network configuration should normally be necessary, aside from connecting to the ad hoc network above OK, now that the down and dirty

Pagina 65

68 // All in BIG Endian !!!! typedef struct { U8 ProtoID[8]; // protocol ID = "IMS Net" U16 OpCode; // == IMSNET_OPCODE_POLL

Pagina 66 - IMS NET (Wi-Fi)

69 Special Considerations for Network/Wi-Fi Although, in general, network programming with the OT-2 is straightforward, there are some special consi

Pagina 67

7 MTS when they see it. So, if you are only connecting through an OT-1b/2, you should never have to worry about the older format. Although a substan

Pagina 68

70 you can circumvent it another way. In our own Windows software, we send the bogus MTS Query 0xFF each time we receive an in band packet. These que

Pagina 69 - Performance

71 Samples They say that a line of code is worth a thousand words. I suppose that depends on the code. However, it is generally helpful to have work

Pagina 70 - Debugging

72 Appendix A: Normalized PIDs This table gives names, descriptions, units, and ranges to scale MTS samples (0-1023) to. For the ECU mode 1 PID asso

Pagina 71 - Samples

73 "OBD_O2S11", "O2 Sensor(NB) 1-1", "Volts", 0.0, 1.275, "OBD_SHRTFT11","O2 Fuel Trim 1-1&quo

Pagina 72 - Appendix A: Normalized PIDs

74 "TIMING", "Ignition Timing", "deg", -10.0, 50.0, "MAP3BA", "MAP 3Ba", "PS

Pagina 73 - Common non-OBD IMS Inputs:

75 0x31, "CLR_DIST - Dist. MIL clear", 0x30, "WARM_UPS - Since MIL clear", 0x1F, "RUNTM - Run Time", 0x14,

Pagina 74

76 Appendix B – Determining Normalized PID Availability Although it is possible to use the ‘a’ command in Setup Mode to determine if a normalized PI

Pagina 75

8 As the outline on the diagram above shows, this SDK covers, generically, how to communicate with Innovate devices via either our universal USB dr

Pagina 76

9 MTS Basics (or “Serial 2 revisited”) Regardless of how you physically connect to an OT-1B/2, its default behavior is to continuously send a stream

Commenti su questo manuale

Nessun commento