diff --git a/tss463_van_ac_diag_experiment/tss463_van_ac_diag_experiment.ino b/examples/tss463_van_ac_diag_experiment/tss463_van_ac_diag_experiment.ino similarity index 100% rename from tss463_van_ac_diag_experiment/tss463_van_ac_diag_experiment.ino rename to examples/tss463_van_ac_diag_experiment/tss463_van_ac_diag_experiment.ino diff --git a/tss463_van_dashboard_experiment/tss463_van_dashboard_experiment.ino b/examples/tss463_van_dashboard_experiment/tss463_van_dashboard_experiment.ino similarity index 100% rename from tss463_van_dashboard_experiment/tss463_van_dashboard_experiment.ino rename to examples/tss463_van_dashboard_experiment/tss463_van_dashboard_experiment.ino diff --git a/tss463_van_monitor/AbstractVanMessageSender.h b/examples/tss463_van_monitor/AbstractVanMessageSender.h similarity index 100% rename from tss463_van_monitor/AbstractVanMessageSender.h rename to examples/tss463_van_monitor/AbstractVanMessageSender.h diff --git a/tss463_van_monitor/VanMessageSender.h b/examples/tss463_van_monitor/VanMessageSender.h similarity index 100% rename from tss463_van_monitor/VanMessageSender.h rename to examples/tss463_van_monitor/VanMessageSender.h diff --git a/tss463_van_monitor/tss463_van_monitor.ino b/examples/tss463_van_monitor/tss463_van_monitor.ino similarity index 100% rename from tss463_van_monitor/tss463_van_monitor.ino rename to examples/tss463_van_monitor/tss463_van_monitor.ino diff --git a/tss463_van_rds_experiment/tss463_van_rds_experiment.ino b/examples/tss463_van_rds_experiment/tss463_van_rds_experiment.ino similarity index 100% rename from tss463_van_rds_experiment/tss463_van_rds_experiment.ino rename to examples/tss463_van_rds_experiment/tss463_van_rds_experiment.ino diff --git a/doc/TSS463C VAN Datalink Controller with Serial interface - doc7601.pdf b/extras/TSS463C VAN Datalink Controller with Serial interface - doc7601.pdf similarity index 100% rename from doc/TSS463C VAN Datalink Controller with Serial interface - doc7601.pdf rename to extras/TSS463C VAN Datalink Controller with Serial interface - doc7601.pdf diff --git a/schema/schema_tss463c_mcp2551.png b/extras/schema/schema_tss463c_mcp2551.png similarity index 100% rename from schema/schema_tss463c_mcp2551.png rename to extras/schema/schema_tss463c_mcp2551.png diff --git a/schema/schema_tss463c_remq0339.png b/extras/schema/schema_tss463c_remq0339.png similarity index 100% rename from schema/schema_tss463c_remq0339.png rename to extras/schema/schema_tss463c_remq0339.png diff --git a/library.properties b/library.properties index 1d0f837..9aee145 100644 --- a/library.properties +++ b/library.properties @@ -1,9 +1,10 @@ -name=tss463c_van -version=1.1 +name=Atmel TSS463C VAN bus Datalink Controller library +version=1.1.0 author=Peter Pinter -maintainer=Peter Pinter +maintainer=Peter Pinter sentence=A library for the Atmel TSS463C VAN Datalink Controller with SPI paragraph=It is intended to interface cars made by the PSA (Peugeot and Citroen) category=Communication url=https://github.com/morcibacsi/arduino_tss463_van -architectures=avr,esp32 \ No newline at end of file +architectures=avr,esp32 +includes=tss463_van.h \ No newline at end of file diff --git a/readme.md b/readme.md index fffae6f..8f6af32 100644 --- a/readme.md +++ b/readme.md @@ -4,7 +4,7 @@ This is an Arduino library for the Atmel TSS463C VAN Datalink Controller with SP [VAN bus][van_bus] is pretty similar to CAN bus. It was used in many cars (Peugeot, Citroen) made by PSA. -It is capable of reading and writing the VAN bus. To understand the VAN protocol and the library I **strongly recommend** to read the datasheet of the TSS463C VAN Datalink Controller. It is included in the repository. The library contains references to the pages of the document to have a better understanding on what is going on. +It is capable of reading and writing the VAN bus. To understand the VAN protocol and the library I **strongly recommend** to read the datasheet of the TSS463C VAN Datalink Controller. It is included in the repository inside the extras folder. The library contains references to the pages of the document to have a better understanding on what is going on. ### Message types Understanding the various message types is essential (see page 19-21 and 42-45 in the datasheet). Some messages are pretty straightforward: they have a source and destination(s), but there are others which are like queries: a device (for example the display) asks another one (like the BSI or the CD changer or the head unit) for some data. So when you are testing and a message does not appear it could mean that you don't have the initiator in your setup (or maybe you are missing the device which should answer for the query). Or it could also mean that you misconfigured the receiver channels. @@ -17,16 +17,15 @@ So if you just want to have a working VAN bus reader and don't want to have your To have the library working, you need to build a shield first as such thing does not exists on the market for the VAN bus. To build the hardware you need to buy a TSS463C VAN controller and a REMQ 0339 VAN line driver (this is also known as Alcatel 2840). Unfortunately these are pretty hard to find but if you are lucky you can buy them on aliexpress (or you can also extract them from an old headunit or display). -#### TSS463C + Rem0339 VAN line driver +#### TSS463C + Remq0339 VAN line driver - -![schema_tss463c_remq0339](https://github.com/morcibacsi/arduino_tss463_van/raw/master/schema/schema_tss463c_remq0339.png) +![schema_tss463c_remq0339](https://github.com/morcibacsi/arduino_tss463_van/raw/master/extras/schema/schema_tss463c_remq0339.png) #### TSS463C + MCP2551 CAN transceiver Instead of the Remq 0339 it is also possible to use a CAN transceiver, for example the MCP2551 -![schema_tss463c_mcp2551](https://github.com/morcibacsi/arduino_tss463_van/raw/master/schema/schema_tss463c_mcp2551.png) +![schema_tss463c_mcp2551](https://github.com/morcibacsi/arduino_tss463_van/raw/master/extras/schema/schema_tss463c_mcp2551.png) ### Installing Copy the following files to your **documents\Arduino\libraries\tss463_van** folder @@ -36,7 +35,7 @@ Copy the following files to your **documents\Arduino\libraries\tss463_van** fold - keywords.txt - library.properties -Check the **tss463_van_monitor** and **tss463_van_dashboard_experiment** folders for examples on how to read and write messages on the bus. +Check the **tss463_van_monitor** and **tss463_van_dashboard_experiment** folders inside the extras folder for examples on how to read and write messages on the bus. ### Tested boards - Arduino UNO/Nano/Pro Mini diff --git a/tss463_channel_registers_struct.h b/src/tss463_channel_registers_struct.h similarity index 100% rename from tss463_channel_registers_struct.h rename to src/tss463_channel_registers_struct.h diff --git a/tss463_van.cpp b/src/tss463_van.cpp similarity index 100% rename from tss463_van.cpp rename to src/tss463_van.cpp diff --git a/tss463_van.h b/src/tss463_van.h similarity index 100% rename from tss463_van.h rename to src/tss463_van.h