Skip to content

Commit 631df2e

Browse files
committed
Update TWAI.md
1 parent 0cbb915 commit 631df2e

File tree

1 file changed

+4
-8
lines changed

1 file changed

+4
-8
lines changed

docs/TWAI.md

+4-8
Original file line numberDiff line numberDiff line change
@@ -78,13 +78,11 @@ TwaiSend<bus\><a class="cmnd" id="dalisend"></a>|Send zero or up to eigth data b
7878
A minimal berry script should look like this:
7979
```
8080
class twai_cls
81-
var active # (bool)
8281
var twai_speed, twai_mode # (int, int)
8382
8483
def init()
8584
self.twai_speed = 4 # 0 = 25K, 1 = 50K, 2 = 100K, 3 = 125K, 4 = 250K, 5 = 500K, 6 = 800K, 7 = 1Mbits
8685
self.twai_mode = 2 # 0 = TWAI_MODE_NORMAL, 1 = TWAI_MODE_NO_ACK, 2 = TWAI_MODE_LISTEN_ONLY
87-
self.active = 0
8886
end
8987
9088
#----------------------------------------------------------------------------------------------
@@ -103,24 +101,22 @@ class twai_cls
103101
var extended = ident >> 31 & 0x1 # Extended identifier flag (0..1)
104102
var id = ident & 0x1fffffff
105103
106-
107-
self.active = 1 # At least one valid decode
108104
end
109105
end
110106
111107
twai = twai_cls() # This class name (twai) is used by the TWAI driver!
112108
tasmota.add_driver(twai)
113109
```
114-
Save the file as `twai.be` and add a line `load('twai.be')` to file `preinit.be`. This will execute the file at restart and prepare the driver for 250Kbit/s and Listen Only Mode.
110+
Save the file as `twai_minimal.be` and add a line `load('twai_minimal.be')` to file `preinit.be`. This will execute the file at restart and prepare the driver for 250Kbit/s and Listen Only Mode.
115111

116112
### Remeha Calenta Ace sniffer for Domoticz
117113

118114
<img alt="Remeha" src="../_media/Remeha1.jpg" style="margin:10px;float:right;width:18em"> </img>
119115
The Remeha boiler provides a RJ12 connector for a Service Tool. The communication between the boiler and the Service Tool takes place using CAN-bus in 11-bit identifier mode. A dongle consisting of a <b>M5 Mini CAN Unit</b> and a <b>M5Atom</b> (ESP32/ESP32S3) or <b>M5Nano</b> (ESP32C6) with Tasmota can be used as sniffer sending important data to a Home Automation tool like Domoticz.
120116

121-
To make the <b>M5 Mini CAN Unit</b> compliant with the CAN-bus standard you'll need to remove the internal 120 Ohm resistor as the Remeha L-Bus is already terminated with two 120 Ohm resistors.
117+
??? note "To make the M5 Mini CAN Unit compliant with the CAN-bus standard you'll need to remove the internal 120 Ohm resistor as the Remeha L-Bus is already terminated with two 120 Ohm resistors."
122118

123-
??? warning "When using the <b>M5 Mini CAN Unit</b> DO NOT CONNECT ANY USB CABLE TO THE M5ATOM OR M5NANO. It likely blows (one of) the ESD diodes (as mine did). If USB connection is needed use <b>M5 Unit CAN</b>."
119+
??? warning "When using the M5 Mini CAN Unit DO NOT CONNECT ANY USB CABLE TO THE M5ATOM OR M5NANO. It likely blows (one of) the ESD diodes (as mine did). If USB connection is needed use M5 Unit CAN."
124120

125121
As an alternative you can use the <b>M5 Unit CAN</b> which has no internal 120 Ohm termination resistor. In that case you'll need to power the M5Atom or M5Nano externally with a USB power supply as the CAN-bus is isolated.
126122

@@ -271,7 +267,7 @@ end
271267
twai = twai_cls()
272268
tasmota.add_driver(twai)
273269
```
274-
Save the file as `twai.be` and add a line `load('twai.be')` to file `preinit.be`. This will execute the file a restart and prepare the driver for 1Mbit/s and Listen Only Mode.
270+
Save the file as `calenta.be` and add a line `load('calenta.be')` to file `preinit.be`. This will execute the file a restart and prepare the driver for 1Mbit/s and Listen Only Mode.
275271

276272
#### Result of monitoring boiler pressure over time
277273

0 commit comments

Comments
 (0)