Project

General

Profile

DTXr doc » History » Version 94

David Fredriksson, 12/09/2025 08:15 PM

1 20 Torbjorn Carlqvist Admin
{{>toc}}
2
3
h1. DTXr documentation
4 1 Torbjorn Carlqvist Admin
5 5 Torbjorn Carlqvist Admin
h3. Installation
6 2 Torbjorn Carlqvist Admin
7 6 Torbjorn Carlqvist Admin
* System Requirements
8 74 David Fredriksson
DTXr can run on any machine that can run +Java 17+ and has sufficient with RAM and disk capacity.
9 1 Torbjorn Carlqvist Admin
10 21 Torbjorn Carlqvist Admin
|Requirement|System RAM|System DISK|Example|
11
|Minimal|512Mbyte|512Mbyte|Raspberry 1, Raspberry Zero|
12 31 Torbjorn Carlqvist Admin
|Better|512Mbyte|512Mbyte|Rasberry Zero 2|
13
|Avarage|1GByte|1Gbyte|Raspberry 2-4|
14 21 Torbjorn Carlqvist Admin
|Top|2GByte|8Gbyte|Raspberry 4, Raspberry CM4, Server, PC|
15
16 6 Torbjorn Carlqvist Admin
* Network Requirements
17
DTXr can run stand alone without any active network connection. In that case the management pages is accessible via localhost interface. But for DTXr to be a fully functional BACnet/IP device it must be connected to an IP network that offers IP address via DHCP and where broadcast traffic is allowed.
18 10 Torbjorn Carlqvist Admin
19 1 Torbjorn Carlqvist Admin
* Download DTXr software packages
20 10 Torbjorn Carlqvist Admin
Currently only customers to DAVITOR can download DTXr. Contact info@davitor.com for purchase information.
21
22 15 Torbjorn Carlqvist Admin
* Install on Linux
23 60 Torbjorn Carlqvist Admin
** There is special install scripts, please follow these steps:
24 22 Torbjorn Carlqvist Admin
### Download latest DTXr _base_ image and copy to a SD-card that has 16Gbyte capacity or more
25 64 David Fredriksson
26
Or install a new image and install java
27
<pre>sudo apt install default-jdk </pre>
28
29 22 Torbjorn Carlqvist Admin
### Insert the SD card, attach keyboard and screen via cable and start the device
30 41 David Fredriksson
### When you get prompt login as **admin/davitor**
31 72 Torbjorn Carlqvist Admin
### Download the installation script from davitor repository 
32
*(note dtx.sh has an update since Jan 17th, 2024 see new parameter 'installfolder' below)*
33
*(note dtx.sh has an update since Nov 6th, 2025 see new parameter 'type' below)*
34 59 Torbjorn Carlqvist Admin
<pre>wget --user=**** --password=**** https://artifacts.davitor.com/repository/dtx-raw/scripts/dtx.sh</pre>
35 56 Torbjorn Carlqvist Admin
There is also a utillity script that can set the host name and MAC adress. Note, optional and only applicable on LION product appliances.
36 59 Torbjorn Carlqvist Admin
<pre>wget --user=**** --password=****  https://artifacts.davitor.com/repository/dtx-raw/scripts/system.sh</pre>
37 56 Torbjorn Carlqvist Admin
Make the scripts exec
38
<pre>sudo chmod 770 *.sh</pre>
39 1 Torbjorn Carlqvist Admin
### Run installation as below where you first alter:
40 72 Torbjorn Carlqvist Admin
*** Required type (-t type) where type can be "scriptengine" for small platforms like RpiZ with 32-bit OS or "polyglot" for any 64-bits OS like servers or PC.
41 1 Torbjorn Carlqvist Admin
*** Required version (-v x.y.z)
42 69 Torbjorn Carlqvist Admin
*** The the install folder (-f myfolder) Note: Still relative to /usr/local so (-f myfolder) results in /usr/local/myfolder/dtx...
43 57 Torbjorn Carlqvist Admin
*** Partner user name (-u ****)
44
*** Partner password (-p ****)
45
*** Application password for the HTTP interface login on port 9090 (-app-password xxxxxxx)
46 58 Torbjorn Carlqvist Admin
*** BACnet Decvice Id (bac-device-id=nnnnn)
47 57 Torbjorn Carlqvist Admin
*** BACnet password which you will use to control the BACnet device DCC (bacnet-password=xxxxxx)
48 67 Torbjorn Carlqvist Admin
*** BACnet Device Name (bac-device-name=yyyy)
49 1 Torbjorn Carlqvist Admin
*** DAVITOR Reference Key (drk=xxxx) is used to mange and maintain this device from the DAVITOR PLM (Product Lifecycle Management) service. (drk=xxxx) The sequence of drk:s is in PLM instance database.
50
*** Hardware Platform Type (platform=xx) is used to control and switch on/off special features that is hardware dependent.
51
For LION products use:
52 73 David Fredriksson
<pre>sudo ./dtx.sh -t scriptengine|polyglot -v 3.2.2 -f myfolder -u **** -p **** -s "bac-device-id=nnnnn bac-device-name=yyyy app-password=xxxxxx bac-password=xxxxxx lion-enabled=true drk=xxxx platform=XX"</pre>
53 71 David Fredriksson
For other installations like PC, Servers etc. use:
54 72 Torbjorn Carlqvist Admin
<pre>sudo ./dtx.sh -t scriptengine|polyglot -v 3.1.23 -f myfolder -u **** -p **** -s "bac-device-id=nnnnn bac-device-name=yyyy app-password=xxxxxx bac-password=xxxxxx drk=xxxx platform=XX"</pre>
55 1 Torbjorn Carlqvist Admin
### Utillity script to set MAC and host name
56 54 Torbjorn Carlqvist Admin
<pre>sudo ./system.sh -mac 70:B3:D5:16:E8:99 -hn DTX-L1-8R8DI</pre>
57 62 Torbjorn Carlqvist Admin
* Upgrade on linux
58 69 Torbjorn Carlqvist Admin
If you already have DTX installed and should upgrade to a new version *(Don't forget to set correct installfolder with -f)*
59 72 Torbjorn Carlqvist Admin
<pre>sudo ./dtx.sh -t scriptengine|polyglot -v 3.1.23 -f myfolder -u **** -p ****</pre>
60 69 Torbjorn Carlqvist Admin
* Manage the DTX service *(Note, since 17th Jan, 2024 of dtx.sh the names of the services are appended with the instsall folder in order to install multiple instances of DTX in same machine.)*
61 70 Torbjorn Carlqvist Admin
Stop<pre>sudo systemctl stop dtx_{myfolder}</pre> 
62
Start<pre>sudo systemctl start dtx_{myfolder}</pre>
63
Check status<pre>systemctl status dtx_{myfolder}</pre>
64
Disable service, wont start at reboot<pre>sudo systemctl disable dtx_{myfolder}</pre>
65
Enable service, will start automatically at reboot<pre>sudo systemctl enable dtx_{myfolder}</pre>
66 15 Torbjorn Carlqvist Admin
67 55 Torbjorn Carlqvist Admin
* For other Linux distributions follow this steps
68 15 Torbjorn Carlqvist Admin
### _TBD..._
69
70 1 Torbjorn Carlqvist Admin
* Install on Windows
71
** Follow these steps:
72 32 David Fredriksson
### _TBD..._
73 38 Torbjorn Carlqvist Admin
74 32 David Fredriksson
h3. LION Fieldbus
75 38 Torbjorn Carlqvist Admin
76 15 Torbjorn Carlqvist Admin
* See LION [[LION:Wiki]] for howto in installataion, channel assigmnets and testing.
77 1 Torbjorn Carlqvist Admin
78
79
80 78 David Fredriksson
---
81 88 David Fredriksson
h1. User's Guide
82 1 Torbjorn Carlqvist Admin
83 88 David Fredriksson
h2. DTXr Web Interface – End User Documentation
84
85 84 David Fredriksson
h2. 1. Overview
86 86 David Fredriksson
87
h4. The DTXr web interface allows users to:
88 79 David Fredriksson
* View BACnet objects and their properties
89
* Modify writable properties (e.g., Present Value)
90
* Edit weekly schedules
91
* Switch between local and remote devices
92
* Monitor alarms, events, and notifications
93
* Use real-time updates through WebSocket (local device only)
94
95 88 David Fredriksson
96
*Important:*  
97
When selecting a *remote BACnet device*, the object list and notifications *do not update automatically*.  
98
You must press *@Objects → Refresh@* to reload the data.
99
100
For the *local device that hosts the web page*, all updates (property changes, events, alarms) are received *in real time*.
101
102 79 David Fredriksson
---
103
104
h3. 2. Navigation Bar
105
106
h4. 2.1 Objects Menu
107
* *Refresh* reloads all object data and events.
108
109
_Note: Refresh is required when a remote device is selected._
110
111
h4. 2.2 Devices Menu
112
* Displays local device and all discovered BACnet devices.
113
* Devices are grouped by network.
114
* Selecting a device loads its object list.
115
116
h4. 2.3 Priority Menu
117
Controls the *BACnet write priority* used when writing Present Value.
118
119
Examples:
120
* Priority 1 – Manual Life Safety
121
* Priority 8 – Default
122
* Priority 16 – Lowest
123
124
h4. 2.4 Notifications Menu
125
Shows:
126
* Alarms
127
* Events
128
* Return-to-normal
129
130
The menu uses badge counters:
131
* Yellow = events  
132
* Red = alarms  
133
* Green = normal transitions  
134
135
---
136
137 84 David Fredriksson
h3. 3. Objects View
138 79 David Fredriksson
139
The main view lists all BACnet objects.
140
141
Features:
142
* Collapsible categories (accordions)
143
* Lazy loading of properties when expanded
144
* Editable Present Value fields where supported
145
* Real-time updates on the *local* device
146
* Manual refresh required for *remote* devices
147
148
h4. 3.1 Expanding an Object
149
Expanding an object loads:
150
* Properties
151
* Values
152
* Writable fields
153
* Schedule editor button (if applicable)
154
155
h4. 3.2 Writing Property Values
156
Steps:
157
# Edit a value in the input field.
158
# Press the Write/Save button.
159
# DTXr sends a BACnet WriteProperty with the selected priority.
160
# A popup shows success or error.
161
162
---
163
164
h3. 4. Device Discovery
165
166
h4. 4.1 Discovering Devices
167
Opening the *Devices* dropdown sends a Who-Is request and populates the list.
168
169
h4. 4.2 Selecting a Device
170
When switching devices:
171
* Properties reload
172
* Notification list reloads
173
* The selected device name appears in the navbar
174
175
h4. 4.3 Refreshing Content
176
*Mandatory* when using remote devices.
177
178
Use:
179
@Objects → Refresh@
180
181
This reloads:
182
* Object list
183
* Property values
184
* Notifications
185
186
---
187
188
h3. 5. Notifications and Events
189
190
Notifications include:
191
* Alarm
192
* Event
193
* Normal
194
195
Real-time updates:
196
* Enabled for local device
197
* Disabled for remote devices — manual refresh required
198
199
h4. 5.1 Acknowledgment
200
If a notification supports acknowledgment:
201
* Press _Acknowledge_
202
* DTXr sends BACnet AcknowledgeAlarm
203
* Notification updates when completed
204
205
---
206
207
h3. 6. Weekly Schedule Editor
208
209
h4. 6.1 Opening the Editor
210
Click the schedule property to open the weekly calendar modal.
211
212
h4. 6.2 Creating Events
213
Select a time in the calendar to create a new event.
214
215
h4. 6.3 Editing Events
216
Click an event to modify:
217
* Binary schedule → Active / Inactive
218
* Analog schedule → numeric value
219
220
h4. 6.4 Saving the Schedule
221
Click *@Save changes@* to store the weekly schedule.
222
223
The data is:
224
* Compiled into BACnet dailySchedule structures
225
* Sorted chronologically
226
* Sent to the device as JSON
227
228
---
229
230
h3. 7. Popups and Feedback
231
232
Popups indicate:
233
* Success
234
* Errors
235
* Info
236
* Warnings
237
238
---
239
240
h3. 8. Troubleshooting
241
242
h4. 8.1 Objects Not Updating
243
* Remote device selected → press Refresh  
244
* Network or device may be unreachable
245
246
h4. 8.2 Write Errors
247
Possible reasons:
248
* Incorrect priority  
249
* Object out of service  
250
* Invalid value  
251 1 Torbjorn Carlqvist Admin
252 79 David Fredriksson
h4. 8.3 Schedule Issues
253 1 Torbjorn Carlqvist Admin
* No events created  
254
* Missing object ID  
255
* Remote device requires manual refresh  
256
257
258
---
259 81 David Fredriksson
260 83 David Fredriksson
h2. Setup
261 79 David Fredriksson
262 80 David Fredriksson
DTXr is configured through the *Menu → Setup* page.  
263
All configuration settings are grouped into logical sections. Each section below provides a functional overview of what the user can configure.  
264
Values are stored in *settings.json* and applied system-wide after pressing *Save*.
265
266
*Important:*  
267
When a *remote device* is selected from the HUB interface, *a manual page refresh is required* to update configuration data.  
268
Local device information updates in real time.
269 78 David Fredriksson
h4. System
270 1 Torbjorn Carlqvist Admin
271 78 David Fredriksson
Contains all fundamental system-level access and identity configuration.
272 1 Torbjorn Carlqvist Admin
273 78 David Fredriksson
* Administrator Account  
274
  - Configure the password of the fixed “admin” user.  
275
* Operator Account  
276
  - Optional user with limited access for HMIs or machine operation.  
277
  - Username, password and start page can be assigned.  
278
* Developer Account  
279
  - Optional higher-level user with configurable module permissions  
280
    (code, objects, API, blocks, diagram, setup).  
281
* Logging  
282
  - Set the system-wide log level (Debug, Info, Warning, Error).  
283
* Hardware Platform  
284
  - Select hardware profile (PC/server, Mira/Mesh, LION, etc.).  
285
  - This controls the enable/disable state of platform-specific modules.
286
287 1 Torbjorn Carlqvist Admin
---
288 77 David Fredriksson
289 78 David Fredriksson
h4. BACnet
290 1 Torbjorn Carlqvist Admin
291 78 David Fredriksson
Defines all BACnet/IP protocol parameters for the device.
292 1 Torbjorn Carlqvist Admin
293 78 David Fredriksson
* Device Identity  
294
  - Device ID, Device Name.  
295
* Security  
296
  - BACnet password (used for Device Communication Control).  
297
* Protocol Settings  
298
  - Segmentation, Max APDU, Vendor ID and other low-level options.  
299
* Network Mode  
300
  - Basic IP communication behaviour (broadcast, BBMD usage when applicable).
301 1 Torbjorn Carlqvist Admin
302 78 David Fredriksson
This section is essential when integrating DTXr into a BACnet building automation network.
303 1 Torbjorn Carlqvist Admin
304
---
305 77 David Fredriksson
306 78 David Fredriksson
h4. Wireless Mesh
307 1 Torbjorn Carlqvist Admin
308 78 David Fredriksson
Provides access to the mesh radio configuration on supported hardware.
309 1 Torbjorn Carlqvist Admin
310 78 David Fredriksson
* Enable/Disable Mesh  
311
* Mesh Credentials  
312
  - Security keys, network key and authentication key.  
313
* Node Role  
314
  - Coordinator / Router / End Device.  
315
* Provisioning QR Code  
316
  - Device can generate a QR code containing mesh network credentials.
317 77 David Fredriksson
318 78 David Fredriksson
Note: Mesh options are disabled on platform types that do not support radio.
319 77 David Fredriksson
320
---
321
322 1 Torbjorn Carlqvist Admin
h4. Bluetooth
323 76 David Fredriksson
324 1 Torbjorn Carlqvist Admin
Configuration for onboard Bluetooth LE services (if supported by the platform).
325 76 David Fredriksson
326
* Bluetooth Console  
327 1 Torbjorn Carlqvist Admin
  - Enables BLE-based console output.  
328 76 David Fredriksson
* Beacon Mode  
329 1 Torbjorn Carlqvist Admin
  - Enables BLE advertisement and optional custom beacon name.  
330 76 David Fredriksson
* Address Visibility and Power Settings  
331
  - Controls how the device broadcasts itself to the environment.
332
333
These options are automatically enabled or disabled depending on the selected platform type.
334 1 Torbjorn Carlqvist Admin
335 76 David Fredriksson
---
336
337 1 Torbjorn Carlqvist Admin
h4. LION Interface
338 76 David Fredriksson
339
Shown only on LION-enabled platforms.
340
341
* Enable/Disable LION module support.  
342 1 Torbjorn Carlqvist Admin
* Hardware Extensions  
343 76 David Fredriksson
  - Configures behaviour of LION-specific IO hardware.  
344
* Channel Behavior  
345
  - Digital/analog features depending on LION product family.
346
347
---
348 75 David Fredriksson
349 76 David Fredriksson
h4. Davitor Advantage
350
351
Configuration for optional DAVITOR cloud lifecycle management.
352
353 75 David Fredriksson
* DRK (Davitor Reference Key)  
354 76 David Fredriksson
  - Used for remote maintenance and PLM link.  
355 75 David Fredriksson
* PLM Connectivity  
356 76 David Fredriksson
  - Service URL and communication settings when using cloud management.
357 75 David Fredriksson
358 76 David Fredriksson
---
359 75 David Fredriksson
360
h4. External Database Access
361 76 David Fredriksson
362
Lets the DTXr device communicate with an external SQL/NoSQL database.
363
364
* Connection  
365
  - Host, port and protocol information.  
366 75 David Fredriksson
* Credentials  
367 76 David Fredriksson
  - Username/password for authenticated connections.  
368
* Sync/Logging Options  
369
  - Defines how data is written externally (trend logs, events, custom data).
370
371
---
372
373 75 David Fredriksson
h4. File Integration
374 76 David Fredriksson
375
Tools for importing/exporting system content.
376
377
* Backup / Restore  
378
  - Download the current configuration or upload a saved configuration.  
379
* Project File Upload  
380 1 Torbjorn Carlqvist Admin
  - Add or replace project assets (HMIs, scripts, diagrams).  
381 76 David Fredriksson
* Logs  
382 42 David Fredriksson
  - Download generated logs for troubleshooting.
383 76 David Fredriksson
384 13 Torbjorn Carlqvist Admin
---
385 76 David Fredriksson
386
h4. HTTP Server
387 11 Torbjorn Carlqvist Admin
388 76 David Fredriksson
Controls how the embedded DTXr HTTP(S) service behaves.
389
390
* Port Configuration  
391
  - Default HTTP port is 9090.  
392
* HTTPS / TLS  
393 14 Torbjorn Carlqvist Admin
  - Optional encrypted access.  
394 76 David Fredriksson
* Session Timeout  
395
  - Auto-logout delay for inactive users.  
396 14 Torbjorn Carlqvist Admin
* Allowed Hosts  
397 11 Torbjorn Carlqvist Admin
  - Restrict network clients that can access the interface.
398 76 David Fredriksson
399 14 Torbjorn Carlqvist Admin
---
400 76 David Fredriksson
401
h4. Email
402
403
Allows the device to send or receive email for automation events.
404 11 Torbjorn Carlqvist Admin
405 76 David Fredriksson
* SMTP Server  
406 11 Torbjorn Carlqvist Admin
  - Address, port, TLS/STARTTLS.  
407 76 David Fredriksson
* Authentication  
408 14 Torbjorn Carlqvist Admin
  - Optional username/password.  
409 76 David Fredriksson
* Attachments Folder  
410
  - Path where incoming email attachments are stored.
411
412
---
413 11 Torbjorn Carlqvist Admin
414 76 David Fredriksson
h4. Location Services
415
416
The device can determine its location automatically.
417 1 Torbjorn Carlqvist Admin
418 76 David Fredriksson
* Automatic Geolocation  
419
  - Queries an external geolocation service to populate latitude/longitude.  
420
* Manual Input  
421
  - User can override location if browser access is restricted.
422
423 19 Torbjorn Carlqvist Admin
---
424 76 David Fredriksson
425 19 Torbjorn Carlqvist Admin
h4. IoT HUB (BETA)
426 76 David Fredriksson
427 1 Torbjorn Carlqvist Admin
Early-stage experimental cloud integration.
428 76 David Fredriksson
429
* Backend URL  
430 1 Torbjorn Carlqvist Admin
  - IoT gateway endpoint.  
431 76 David Fredriksson
* Device Token  
432
  - Authentication token for cloud usage.  
433 1 Torbjorn Carlqvist Admin
* Upload Options  
434 76 David Fredriksson
  - Define what data the device forwards (events, logs, telemetry).
435
436
---
437
438 1 Torbjorn Carlqvist Admin
h4. Save & Refresh
439 76 David Fredriksson
440
* Save  
441 1 Torbjorn Carlqvist Admin
  - Commits all modified settings to settings.json.  
442 76 David Fredriksson
* Refresh  
443
  - Reloads settings from device memory.  
444
  - Required after switching to a remote device.
445
446 1 Torbjorn Carlqvist Admin
447 76 David Fredriksson
---
448 1 Torbjorn Carlqvist Admin
449 83 David Fredriksson
h2. Blocks Editor (Blockly)
450 82 David Fredriksson
451
The *Blocks* page provides a visual programming environment based on Google Blockly.  
452
Users can build automation logic using drag-and-drop blocks instead of traditional code.  
453
All logic created here is converted into JavaScript and executed by the DTXr runtime.
454
455
The Blocks Editor is divided into four main areas:
456
* The *toolbox* (left side) containing categorized blocks  
457
* The *Blockly workspace* (center)  
458
* The *log and activity panels* (bottom)  
459
* Editor actions available in the top navigation bar
460
461
---
462
463
h5. Navigation Bar Features
464
465
* Blocks → *Refresh*  
466
  - Re-parses the block code displayed in the workspace.  
467
* Blocks → *Clear logs*  
468
  - Clears the log console in the footer area.  
469
* Test  
470
  - Executes the currently visible block code once, without saving.  
471
* Save  
472
  - Saves the current block workspace into the device configuration.  
473
* Activate  
474
  - Saves and also activates the block program so it runs continuously.  
475
* Notifications  
476
  - Shows system events, alarms, and normal transitions in real time.
477
478
---
479
480
h5. Blockly Workspace
481
482
The main canvas where blocks are placed and connected.
483
484
* Drag blocks from the toolbox onto the workspace.  
485
* Connect blocks to form logic chains.  
486
* Right-click a block to duplicate, delete, or collapse it.  
487
* Zoom and pan with the mouse wheel or gestures.
488
489
All changes in the workspace are local until *Save* or *Activate* is pressed.
490
491
---
492
493
h5. Toolbox Categories
494
495
The toolbox is organized into logical categories:
496
497
* JSON  
498
  - Blocks for constructing and parsing JSON objects.  
499
* Logic  
500
  - If/else, comparison, boolean operations.  
501
* Loops  
502
  - Repeat operations.  
503
* Math  
504
  - Arithmetic and numeric values.  
505
* Text  
506
  - String operations and concatenation.  
507
* Variables  
508
  - Create and manage global/local variables.  
509
510
*Events (DTX-specific)*  
511
  - Triggers for analog or binary input changes  
512
  - Astro events  
513
  - Timers  
514
  - Incoming text messages  
515
  - Diagram object push events  
516
517
*Set value / Read value (DTX BACnet extensions)*  
518
  - Write analog, binary, lighting outputs  
519
  - Read analog or binary values  
520
  - Compare input states  
521
522
*Timed tasks*  
523
  - Cron-like scheduling  
524
  - Start, cancel, pause, resume timers  
525
526
*HMI*  
527
  - Update graphical objects or maps in diagrams/HMI pages  
528
529
*Code*  
530
  - Insert raw JavaScript statements  
531
  - Create custom return statements  
532
  - Handle function call events  
533
534
*Misc*  
535
  - Print to log  
536
  - Date/time  
537
538
*Notifications*  
539
  - Send email from block logic  
540
541
These categories combine to cover automation, BACnet control, HMI interaction and notifications.
542
543
---
544
545
h5. Running and Activating Code
546
547
*Test*  
548
Executes the block logic one time, useful for debugging.
549
550
*Save*  
551
Stores the block script but does not run it automatically.
552
553
*Activate*  
554
Saves and deploys the block logic to the DTXr runtime engine.  
555
Activated logic will:
556
* Run automatically on device startup  
557
* Respond to events immediately  
558
* Allow scheduled logic to trigger without manual execution  
559
560
---
561
562
h5. Sidebars and Console
563
564
*Left Sidebar*  
565
May contain the workspace tree or additional contextual tools.
566
567
*Right Sidebar*  
568
Displays block metadata, help text or generated JavaScript depending on configuration.
569
570
*Footer Console*  
571
Two areas are available:
572
* *Log* — printed output from print blocks or runtime  
573
* *Activity* — messages about system behavior, activation, parsing, etc.
574
575
Both areas support resizing using draggable split panes.
576
577
---
578
579
h5. Working With Devices in Blocks Mode
580
581
The device selector is present but indicates:
582
583
*“Not applicable in Blocks mode”*
584
585
This is because Blockly logic always runs locally on the device that hosts DTXr.  
586
Remote devices cannot be programmed using the Blocks Editor.
587
588
---
589
590
h5. Saving Your Work
591
592
The block workspace is saved in the device’s internal configuration.  
593
A backup is included when exporting system configuration via the File Integration tools.
594
595
*Important:*  
596
If block logic interacts with remote devices (reading/writing values),  
597
use *Refresh* in Objects view to ensure the remote values have been updated recently.
598
599
---
600
601
h5. Error Handling
602
603
When errors occur:
604
* The error message appears in the log console  
605
* Pop-up notifications show parsing or execution issues  
606
* Common issues include:
607
  - Missing block connections  
608
  - Undefined variables  
609
  - Writing to unavailable BACnet objects  
610
611
---
612
613
h5. Best Practices
614
615
* Keep block structures grouped and well-organized  
616
* Name variables clearly  
617
* Use print statements during development  
618
* Test frequently before activation  
619
* Avoid long chains inside event triggers  
620
* Use timers for repeated actions, not loops
621
622
---
623
624 93 David Fredriksson
h3. Code Editor
625 92 David Fredriksson
626 93 David Fredriksson
h2. Code Editor (DTXr)
627 1 Torbjorn Carlqvist Admin
628 93 David Fredriksson
The Code Editor in DTXr provides a complete development environment for automation scripting, BACnet integration, file management, debugging, and interacting with both local and remote devices.  
629
The page is divided into several functional areas, each designed to support efficient automation development and system diagnostics.
630 1 Torbjorn Carlqvist Admin
631 93 David Fredriksson
---
632 92 David Fredriksson
633 93 David Fredriksson
h3. Overview of the Page Layout
634 1 Torbjorn Carlqvist Admin
635 93 David Fredriksson
DTXr Code Editor consists of four main UI regions:
636 1 Torbjorn Carlqvist Admin
637 93 David Fredriksson
* **Left Pane – File Browser**  
638
  Shows project files stored on the device, such as automation.js, HTML pages, CSS, JSON, XML, HMI/Diagram files, logs, and configuration files.
639 92 David Fredriksson
640 93 David Fredriksson
* **Center Pane – Code Editor (ACE Editor)**  
641
  A full-featured code editor with syntax highlighting, autocomplete, evaluation tools, and integration with the BACnet browser.
642 1 Torbjorn Carlqvist Admin
643 93 David Fredriksson
* **Right Pane – BACnet Browser**  
644
  Displays the connected BACnet networks, devices, objects, and properties with support for read, write, and object creation.
645 92 David Fredriksson
646 93 David Fredriksson
* **Bottom Area – Console & Activity Log**  
647
  Used for debugging JavaScript, viewing print output, receiving notifications, and tracking internal DTX events.
648 92 David Fredriksson
649 93 David Fredriksson
A **top navigation menu** provides commands such as Save, Activate, Evaluate, Reinitialize and Clear Log.
650 92 David Fredriksson
651
---
652
653 93 David Fredriksson
h3. Left Pane: File Browser
654 1 Torbjorn Carlqvist Admin
655 93 David Fredriksson
The file browser shows all project and system-related files available in the device’s storage.
656 92 David Fredriksson
657 93 David Fredriksson
Functions include:
658 92 David Fredriksson
659 93 David Fredriksson
* Navigating directories
660
* Opening files in the center code pane
661
* Creating new files (JS, HTML, JSON, XML, CSS, HMI/Diagram)
662
* Uploading multiple files at once
663
* Downloading files
664
* Cloning or renaming files
665
* Deleting files
666
* Choosing "Open With" (Diagram Editor, HMI Editor, Markdown Viewer, Raw Mode)
667
* Previewing HTML files in a new browser tab
668 1 Torbjorn Carlqvist Admin
669 93 David Fredriksson
Restrictions:
670 92 David Fredriksson
671 93 David Fredriksson
* Some protected system directories cannot be renamed or removed
672
* When connected to a *remote device*, execution of JavaScript is not supported (only storing/editing files)
673 1 Torbjorn Carlqvist Admin
674 93 David Fredriksson
DTXr warns before navigating away if unsaved edits exist.
675 92 David Fredriksson
676 1 Torbjorn Carlqvist Admin
---
677
678 93 David Fredriksson
h3. Right Pane: BACnet Browser
679 1 Torbjorn Carlqvist Admin
680 93 David Fredriksson
The BACnet browser displays:
681 1 Torbjorn Carlqvist Admin
682 93 David Fredriksson
* Networks  
683
* Devices  
684
* Object Types  
685
* Individual Objects  
686
* Properties (including writable flags and enumeration values)
687 1 Torbjorn Carlqvist Admin
688 93 David Fredriksson
Each node can be expanded independently and refreshed individually to minimize network traffic.
689 1 Torbjorn Carlqvist Admin
690
---
691
692 93 David Fredriksson
h4. Reading & Writing Properties
693 92 David Fredriksson
694 93 David Fredriksson
From any BACnet property node, you may:
695 1 Torbjorn Carlqvist Admin
696 93 David Fredriksson
* Read the value  
697
* Write to writable properties  
698
* Refresh only that property  
699
* Inspect metadata such as engineering units, status flags, and enumeration states  
700 1 Torbjorn Carlqvist Admin
701 92 David Fredriksson
---
702 1 Torbjorn Carlqvist Admin
703 93 David Fredriksson
h4. Device-Level Actions
704 1 Torbjorn Carlqvist Admin
705 93 David Fredriksson
Available actions:
706 92 David Fredriksson
707 93 David Fredriksson
* *Who-Is* – Discover local devices  
708
* *Who-Is Global* – Discover devices across all accessible networks  
709
* *Reinitialize Device* – Warm start, cold start (requires password)  
710
* *Restart Device* – Full reboot (requires password)  
711
* *Read All Properties* – Retrieve a complete BACnet property set  
712 1 Torbjorn Carlqvist Admin
713
---
714
715 93 David Fredriksson
h4. Adding BACnet Objects (Virtual Objects)
716 1 Torbjorn Carlqvist Admin
717 93 David Fredriksson
DTXr allows creation of **virtual BACnet objects**, which exist entirely in software and not in physical hardware.
718 1 Torbjorn Carlqvist Admin
719 93 David Fredriksson
Supported types include:
720 1 Torbjorn Carlqvist Admin
721 93 David Fredriksson
* Analog Value (AV)  
722
* Binary Value (BV)  
723
* Multi-State Value (MSV)  
724
* Trend Logs  
725
* Schedules & Calendars  
726
* Notification Classes  
727
* File objects  
728
* Many additional standard object types  
729 92 David Fredriksson
730 93 David Fredriksson
Virtual objects behave exactly like real BACnet objects:
731 92 David Fredriksson
732 93 David Fredriksson
* They support ReadProperty and WriteProperty  
733
* They support COV subscriptions  
734
* They can be logged, alarmed and trended  
735
* They appear to all BACnet clients on the network  
736
737
These objects enable advanced automation without requiring hardware wiring.
738
739 92 David Fredriksson
---
740
741 93 David Fredriksson
h4. Benefits of Virtual BACnet Objects
742 92 David Fredriksson
743 93 David Fredriksson
Virtual objects make DTX highly flexible:
744 92 David Fredriksson
745 93 David Fredriksson
* Easily combine sensor inputs into new BACnet values  
746
* Represent logic states (HeatingDemand, OccupancyStatus, etc.)  
747
* Create synthetic points (averages, maximums, deltas, differences)  
748
* Produce outputs used by other BACnet controllers  
749
* Build complex automation logic without extra I/O modules  
750
* Use TrendLogs for computed metrics  
751 92 David Fredriksson
752
---
753
754 93 David Fredriksson
h3. Drag & Drop Integration (BACnet Browser → Code)
755 92 David Fredriksson
756 93 David Fredriksson
When dragging a device, object or property into the code pane, DTX automatically generates a usable JavaScript snippet.
757 92 David Fredriksson
758 93 David Fredriksson
Examples:
759 92 David Fredriksson
760 93 David Fredriksson
<pre>read("1234", "analogInput", 1, "presentValue")</pre>
761 92 David Fredriksson
762 93 David Fredriksson
<pre>write("1234", "binaryValue", 5, "presentValue", 1)</pre>
763 92 David Fredriksson
764 93 David Fredriksson
<pre>subscribeCOV("1234", "analogValue", 10, (value) => {
765
    print("COV update: " + value)
766
})</pre>
767 92 David Fredriksson
768 93 David Fredriksson
---
769 92 David Fredriksson
770 93 David Fredriksson
h3. Top Navigation Commands
771 92 David Fredriksson
772 93 David Fredriksson
* **Save** – Saves the current file  
773
* **Activate** – Activates JavaScript files on local device  
774
* **Evaluate** – Runs selected code  
775
* **Evaluate and Print** – Runs and prints output  
776
* **Reinitialize** – Reloads automation system  
777
* **Clear Log** – Clears console  
778 92 David Fredriksson
779 93 David Fredriksson
Remote nodes allow saving but cannot execute code from this page.
780
781 92 David Fredriksson
---
782
783 93 David Fredriksson
h3. Bottom Area: Console & Activity Log
784 92 David Fredriksson
785 93 David Fredriksson
The **Console Log** shows:
786 92 David Fredriksson
787 93 David Fredriksson
* print() output  
788
* JavaScript evaluation results  
789
* Errors and system warnings  
790
* WebSocket logs  
791
792
The **Activity Log** shows internal BACnet and automation notifications.
793
794 92 David Fredriksson
---
795
796 93 David Fredriksson
h3. JavaScript Automation in DTX
797 92 David Fredriksson
798 93 David Fredriksson
DTX includes a full ECMAScript engine:
799 92 David Fredriksson
800 93 David Fredriksson
* **Any JavaScript can be used**  
801
* Arrays, JSON, classes, functions, loops, math, state machines—all supported  
802
* DTX adds automation libraries on top of standard JavaScript  
803
804 92 David Fredriksson
---
805
806 93 David Fredriksson
h4. BACnet Communication Functions
807 92 David Fredriksson
808 93 David Fredriksson
<pre>read(deviceId, type, instance, property)</pre>
809
<pre>write(deviceId, type, instance, property, value)</pre>
810
<pre>subscribeCOV(deviceId, type, instance, callback)</pre>
811
<pre>readAllProperties(deviceId, type, instance)</pre>
812
<pre>whoIs()</pre>
813
<pre>iam()</pre>
814 92 David Fredriksson
815
---
816
817 93 David Fredriksson
h4. Timers & Scheduling
818 92 David Fredriksson
819 93 David Fredriksson
<pre>runEvery(seconds, callback)</pre>
820
<pre>runAt("HH:MM", callback)</pre>
821
<pre>runSchedule(scheduleObj, callback)</pre>
822 92 David Fredriksson
823
---
824
825 93 David Fredriksson
h4. Logging & Notifications
826 92 David Fredriksson
827 93 David Fredriksson
<pre>trend("energy", value)</pre>
828
<pre>getTrend("energy")</pre>
829
<pre>notify(level, message)</pre>
830
<pre>alarmOn(tag)</pre>
831
<pre>alarmOff(tag)</pre>
832 92 David Fredriksson
833
---
834
835 93 David Fredriksson
h4. System Functions
836 92 David Fredriksson
837 93 David Fredriksson
<pre>restart()</pre>
838
<pre>reinit()</pre>
839
<pre>getSystemInfo()</pre>
840
<pre>getDeviceList()</pre>
841 92 David Fredriksson
842
---
843
844 93 David Fredriksson
h3. Complete Automation Examples
845 92 David Fredriksson
846 93 David Fredriksson
h4. Averaging Temperatures
847 92 David Fredriksson
848 93 David Fredriksson
<pre>
849
runEvery(10, () => {
850
    let values = [
851
        read("1001","analogInput",1,"presentValue"),
852
        read("1001","analogInput",2,"presentValue"),
853
        read("1001","analogInput",3,"presentValue"),
854
        read("1001","analogInput",4,"presentValue")
855
    ]
856
    let avg = values.reduce((a,b)=>a+b) / values.length
857
    write("local", "analogValue", 10, "presentValue", avg)
858
})
859
</pre>
860 92 David Fredriksson
861 93 David Fredriksson
h4. COV-Controlled Cooling
862 92 David Fredriksson
863 93 David Fredriksson
<pre>
864
subscribeCOV("3000","analogInput",7,(value)=>{
865
    write("local","binaryValue",5,"presentValue", value > 22 ? 1 : 0)
866
})
867
</pre>
868 92 David Fredriksson
869 93 David Fredriksson
h4. Humidity Alarm
870 92 David Fredriksson
871 93 David Fredriksson
<pre>
872
runEvery(5, () => {
873
    let humidity = read("ruuvi01","analogInput",8,"presentValue")
874
875
    if (humidity > 80) {
876
        alarmOn("HumidityHigh")
877
        notify("critical", "Humidity too high: " + humidity)
878
    } else {
879
        alarmOff("HumidityHigh")
880
    }
881
})
882
</pre>
883
884
h4. Multi-State Virtual Logic
885
886
<pre>
887
runEvery(1, () => {
888
    let t = read("local","analogValue",10,"presentValue")
889
    let state =
890
        t < 18 ? 1 :
891
        t < 22 ? 2 :
892
        t < 25 ? 3 : 4
893
894
    write("local","multiStateValue",20,"presentValue",state)
895
})
896
</pre>
897
898 92 David Fredriksson
899
900
---
901
902 87 David Fredriksson
h2. BACnet
903 82 David Fredriksson
904 87 David Fredriksson
BACnet (Building Automation and Control Network) is an international open communication standard for building automation systems.  
905
It enables devices from different manufacturers to communicate, share data, and coordinate functions such as HVAC, lighting, alarms, access control and energy management.
906 76 David Fredriksson
907 87 David Fredriksson
BACnet is defined and maintained by the BACnet Committee (SSPC 135) under ASHRAE.
908
909
More information: https://bacnet.org
910
911 1 Torbjorn Carlqvist Admin
---
912
913 87 David Fredriksson
h3. Standards and Certification
914
915
BACnet is based on globally recognized standards:
916
917
* *ASHRAE Standard 135*  
918
  The core BACnet protocol specification, maintained by ASHRAE.
919
920
* *ISO 16484-5*  
921
  International standard for building automation and control networks.
922
923
* *ANSI/ASHRAE Addenda*  
924
  Regular updates ensure modern features and cyber-security enhancements.
925
926
Because BACnet is standardized internationally, devices are tested and validated against consistent technical rules.  
927
This ensures long-term compatibility and protects investments in automation systems.
928
929
---
930
931
h3. How BACnet Communication Works
932
933
BACnet defines:
934
* *Objects* — structured data models (AI, AO, BI, BO, Schedules, etc.)  
935
* *Properties* — attributes of each object (Present Value, Units, Status Flags…)  
936
* *Services* — methods for communicating (ReadProperty, WriteProperty, etc.)
937
938
Common communication mechanisms:
939
* **BACnet/IP** over UDP (default port 47808)  
940
* **Who-Is / I-Am** device discovery  
941
* **ReadProperty / WriteProperty** for data exchange  
942
* **COV (Change of Value) subscriptions** for event-driven updates  
943
* **Alarm and Event notifications**  
944
945
DTXr implements:
946
* Full BACnet/IP functionality  
947
* Device discovery  
948
* Automatic reading and writing of properties  
949
* Real-time event handling  
950
* COV subscriptions when available  
951
952
---
953
954 89 David Fredriksson
h3. Key Advantages of BACnet 
955 87 David Fredriksson
956
*Open and vendor-neutral*  
957
BACnet is not controlled by a single private company. Any manufacturer can implement the standard.  
958
This eliminates vendor lock-in and ensures long-term system freedom.
959
960
*Large global ecosystem*  
961
Hundreds of companies worldwide produce BACnet-certified devices:
962
* HVAC controllers  
963
* Sensors and actuators  
964
* Lighting systems  
965
* VAV and damper controllers  
966
* Energy monitoring systems  
967
* User interfaces and visualizations  
968
969
This means integrators can mix-and-match equipment from different brands without special gateways.
970
971
*Interoperability by design*  
972
Because BACnet defines standard object types and required properties, devices share:
973
* Common naming conventions  
974
* Common alarm/event handling behavior  
975
* Standard scheduling objects  
976
* Standard data types  
977
978
This makes exchanging live data straightforward and predictable.
979
980
*Efficient Event-Driven Communication with COV*  
981
Rather than constantly polling for updates, BACnet supports **Change of Value (COV)** subscriptions:
982
* A device notifies subscribers only when a value *actually changes*  
983
* No wasted network traffic  
984
* Faster updates for dynamic values  
985
* Lower CPU and bandwidth usage  
986
* Ideal for large systems or wireless deployments
987
988
COV is one of BACnet’s biggest advantages over legacy systems that rely on heavy cyclic polling.
989
990
*Rich Metadata Built Into the Protocol*  
991
BACnet objects include a wide range of metadata:
992
* Object Name  
993
* Description  
994
* Units  
995
* Engineering limits  
996
* Reliability state  
997
* Status flags  
998
* Priority array  
999
* Object type  
1000
1001
Metadata allows tools like DTXr to:
1002
* Auto-discover device capabilities  
1003
* Display real names and units  
1004
* Visualize systems without custom drivers  
1005
* Auto-generate controls and dashboards  
1006
1007
This reduces engineering time and improves clarity for end users.
1008
1009
---
1010 90 David Fredriksson
1011 89 David Fredriksson
h2. Davitor Advantage
1012 90 David Fredriksson
1013 87 David Fredriksson
h3. Interoperability and Vendor Collaboration
1014
1015
BACnet has a long-standing interoperability testing ecosystem:
1016
1017
* *BACnet Testing Laboratories (BTL)*  
1018
  Certifies devices against standardized profiles, ensuring correct communication.
1019
1020
* *BTL Listings*  
1021
  Public database of certified devices that work together reliably.
1022
1023
* *Plugfests*  
1024
  Manufacturers meet twice per year to test their devices against each other in real networks.
1025
1026
The result:
1027
* Multi-brand BACnet systems work reliably  
1028
* Integration cost is lower  
1029
* Long-term compatibility is ensured  
1030
* Devices can be replaced without redesigning the entire system  
1031
1032
BACnet is one of the strongest and most mature interoperability ecosystems in the automation industry.
1033
1034
---
1035
1036
h3. Why BACnet Works Exceptionally Well With DTXr
1037
1038
DTXr is built around BACnet’s strengths:
1039
* Automatic discovery of BACnet devices  
1040
* Real-time event and alarm handling  
1041
* Full COV support  
1042
* Multi-priority writing of Present Value  
1043
* Automatic metadata integration (names, units, descriptions)  
1044
* Native schedule editor compatible with BACnet Schedule objects  
1045
* BACnet notifications shown directly in the interface  
1046
1047
DTXr can be used as:
1048
* A BACnet central controller  
1049
* A visualization/HMI layer  
1050
* A programming environment (Code + Blocks)  
1051
* A diagnostics tool for technicians  
1052
* A multi-device integration and commissioning tool  
1053
1054
DTXr leverages the power of BACnet without requiring advanced protocol knowledge from the user.
1055 1 Torbjorn Carlqvist Admin
1056
---
1057 89 David Fredriksson
h2. DTX Overview (Development Environment)
1058 1 Torbjorn Carlqvist Admin
1059 89 David Fredriksson
!https://www.davitor.com/Home/DTX!
1060
1061
DTX (by Davitor) is a powerful development and runtime environment designed for building automation, integration, and control — especially for BACnet-based systems.  
1062
The environment is directly integrated into the device, allowing engineers to create, test, and execute automation logic locally or remotely via a web browser.  
1063
DTX is suitable for controllers, gateways, cloud connectors, and industrial IO devices. :contentReference[oaicite:0]{index=0}
1064
1065
---
1066
1067
h3. Core Concept: Development Inside the Device
1068
1069
DTX is described by Davitor as a **“Development Environment for BACnet devices”**.  
1070
Its philosophy centers around **self-contained automation**, where development tools live inside the device itself — eliminating lost code, mismatched versions, or external dependencies. This enhances system integrity and long-term maintainability. :contentReference[oaicite:1]{index=1}
1071
1072
A major benefit of this approach:
1073
* Your automation project is stored and executed natively inside the device.  
1074
* You can access the development environment anywhere on the network.  
1075
* No separate development workstation is required.  
1076
* The same environment works on almost any hardware or operating system supporting Java 11 or higher. :contentReference[oaicite:2]{index=2}
1077
1078
---
1079
1080
h3. Key Features of DTX
1081
1082
*Modular and Future-Proof Design*  
1083
DTX is built with modularity in mind:
1084
* The development environment runs on the device.  
1085
* It is platform-independent and OS-agnostic (runs wherever Java 11+ works).  
1086
* It acts as a **controller**, **cloud service**, or **gateway**, depending on need. :contentReference[oaicite:3]{index=3}
1087
1088
*One Unified Environment*  
1089
DTX includes everything needed for automation development:
1090
* Full **code editor** with JavaScript (ES6) support.  
1091
* A built-in **BACnet browser** for object discovery and inspection.  
1092
* Easy **GUI and HMI creation** tools.  
1093
* Integrated script engine, REST API bindings, email notifications, and schedule management. :contentReference[oaicite:4]{index=4}
1094
1095
*Use Any Developer, Any Skill Level*  
1096
Since DTX uses **JavaScript**, a widely accessible language, the need for specialized proprietary system knowledge is minimized. Anyone with basic JavaScript skills can build automation logic. :contentReference[oaicite:5]{index=5}
1097
1098
---
1099
1100
h3. Protocol Integration and Interoperability
1101
1102
DTX natively supports protocols used in modern automation:
1103
* **BACnet/IP** (full stack with browser and read/write tools)  
1104
* **MODBUS** (both Master and Slave over TCP/RTU)  
1105
* **REST API** (both server and client capabilities for external application integration)  
1106
* Optional LION fieldbus support on specialized hardware  
1107
* MQTT broker capability for IoT use cases  
1108
* Serial port support (ASCII and HEX with configurable delimiter) :contentReference[oaicite:6]{index=6}
1109
1110
The modular approach allows data from any source (BACnet or otherwise) to be exposed directly through DTX’s REST interface — enabling integration with cloud, database or analytics platforms while preserving metadata and object structure. :contentReference[oaicite:7]{index=7}
1111
1112
---
1113
1114
h3. Unified Automation Stack
1115
1116
DTX unifies:
1117
* Development (IDE + editor inside the device)  
1118
* HMI design (visual diagram editor)  
1119
* Script execution (JavaScript engine)  
1120
* Protocol communication (BACnet, Modbus, HTTP, MQTT, etc.)  
1121
* Notifications and email support  
1122
* Database integration (built-in user database or external Postgres SQL) :contentReference[oaicite:8]{index=8}
1123
1124
This makes DTX not only a controller but also a **full automation ecosystem** where:
1125
* Automation logic is developed, tested, and deployed locally  
1126
* Values and objects are available in real time  
1127
* Projects are stored in the device and cannot get disconnected from the runtime  
1128
1129
---
1130
1131
h3. Integration with Davitor Advantage
1132
1133
When combined with Davitor Advantage, DTX becomes a **remotely manageable node** in a scalable automation network:
1134
* Develop locally on any device  
1135
* Provision devices via Davitor cloud  
1136
* Manage and monitor projects across multiple sites and protocols  
1137
* Keep firmware, logic, and configuration synchronized across installations
1138
1139
See https://www.davitor.com for product details and documentation. :contentReference[oaicite:9]{index=9}
1140
1141
---
1142
1143 91 David Fredriksson
h2. Radio Support & Supported Protocols
1144 1 Torbjorn Carlqvist Admin
1145 91 David Fredriksson
DTX provides flexible wireless communication depending on platform and hardware.  
1146
Because DTX can run on any system capable of Java 11 or later, wireless capabilities can range from WiFi-only devices to advanced multi-protocol gateways.
1147 1 Torbjorn Carlqvist Admin
1148 91 David Fredriksson
Below are the primary wireless technologies supported by DTX, in recommended reading order.
1149
1150
---
1151
1152
h3. WiFi (BACnet over WiFi)
1153
1154
DTX includes a complete BACnet/IP stack and can run on any Java 11+ capable WiFi device.  
1155
When DTX is installed on hardware with WiFi (e.g., Raspberry Pi, industrial WiFi gateways, embedded controllers), it automatically supports:
1156
1157
* Full BACnet/IP communication over WiFi  
1158
* COV subscriptions (efficient change-based updates)  
1159
* Who-Is / I-Am device discovery  
1160
* Reading and writing BACnet properties  
1161
* BACnet schedules, events, notifications, and alarms  
1162
* Participation in BACnet networks without wired Ethernet  
1163
1164
This makes DTX a fully wireless BACnet controller when running on WiFi-enabled hardware — ideal for commissioning, mobile diagnostics, or wireless installations.
1165
1166
---
1167
1168
h3. Bluetooth Devices (non-mesh)
1169
1170
DTX supports Bluetooth Low Energy (BLE) devices for direct sensor integration.  
1171
This includes well-known BLE beacon and sensor devices such as **RUUVI smart sensors**, which DTX can automatically detect and encapsulate as BACnet objects.
1172
1173
Examples of RUUVI sensor data mapped by DTX:
1174
1175
* **Temperature** (°C)  
1176
* **Humidity** (%)  
1177
* **Air Pressure** (Pa/hPa)  
1178
* **Movement / Acceleration** (X/Y/Z axis)  
1179
* **Battery level**  
1180
* **Signal strength (RSSI)**  
1181
1182
DTX automatically:
1183
1184
* Detects nearby BLE sensors  
1185
* Parses their advertisement data (no pairing required)  
1186
* Creates corresponding BACnet objects  
1187
* Updates values in real time  
1188
* Allows automation logic and HMI dashboards to use them like any other BACnet sensor  
1189
1190
This enables **fully wireless environmental measurement** with zero wiring and minimal configuration.
1191
1192
RUUVI devices are ideal for:
1193
1194
* HVAC monitoring  
1195
* Building comfort tracking  
1196
* Server room supervision  
1197
* Warehousing & storage  
1198
* Indoor air quality dashboards  
1199
* Asset or movement detection  
1200
1201
Because the sensors broadcast continuously, DTX receives updates passively, with extremely low energy usage on the sensor side.
1202
1203
---
1204
1205
h3. Wireless Long-Range DALI-2 Device (Davitor)
1206
1207
DTX supports integration with **Davitor’s Wireless Long-Range DALI-2 Device**, enabling wireless extension of DALI-2 lighting networks.  
1208
Instead of cabling DALI buses across long distances, the system uses Davitor’s long-range radio modules to connect DALI-2 control gear wirelessly.
1209
1210
Key features:
1211
1212
* Wireless connection between DTX and DALI-2 luminaires  
1213
* Maintains full DALI-2 functionality (dimming, groups, scenes, status)  
1214
* Extends DALI-2 coverage beyond normal cable distance limits  
1215
* Simplifies installation & retrofit work  
1216
* Reduces cable infrastructure costs  
1217
* All DALI-2 channels and objects appear in DTX as BACnet objects  
1218
1219
This allows DTX to become a **wireless lighting controller**, combining BACnet automation with DALI-2 lighting systems.
1220
1221
Suitable for:
1222
1223
* Industrial halls  
1224
* Large buildings  
1225
* Office retrofits  
1226
* Outdoor lighting  
1227
* Warehouses  
1228
* Locations where DALI cabling is impractical  
1229
1230
DTX treats wireless DALI-2 exactly like wired BACnet points, enabling seamless integration with automation scripts, schedules, alarms, and GUI pages.
1231
1232
---
1233
1234
h3. Radio Mesh (MIRA & BLE5 Mesh)
1235
1236
DTX integrates with radio-based mesh networks such as **MIRA Mesh** and **BLE5 Mesh** using Davitor’s multi-protocol radio interface.  
1237
Mesh networks provide long-range, self-healing wireless communication ideal for distributed sensors and actuators.
1238
1239
DTX can:
1240
1241
* Discover mesh nodes automatically  
1242
* Map mesh node values into BACnet objects  
1243
* Control mesh actuators through BACnet writes  
1244
* Use mesh-based sensors for automation logic  
1245
* Support large installations with many devices  
1246
1247
Common mesh technologies used with DTX:
1248
1249
* **MIRA Mesh** — IPv6-based, ultra-low power, long-range self-healing mesh  
1250
* **BLE5 Mesh** — Bluetooth-based many-to-many lighting & sensor networks  
1251
1252
Benefits of mesh:
1253
1254
* Extremely scalable  
1255
* Multi-hop routing increases range  
1256
* No single point of failure  
1257
* Low power consumption for battery nodes  
1258
* Ideal for smart buildings, lighting control, indoor/outdoor sensor grids  
1259
1260
Example applications:
1261
1262
* Wireless environmental sensors  
1263
* Industrial sensor networks  
1264
* Lighting control clusters  
1265
* Distributed monitoring systems  
1266
* Mesh-connected actuators or relay nodes  
1267
1268
DTX treats mesh nodes as native BACnet devices, providing seamless integration across wired, WiFi, Bluetooth, and mesh networks.
1269
1270
---
1271
1272
h3. Summary
1273
1274
DTX supports multiple wireless communication paths:
1275
1276
* **WiFi** — full BACnet/IP capability on wireless hardware  
1277
* **Bluetooth (RUUVI and others)** — automatic BLE sensor discovery and BACnet mapping  
1278
* **Wireless Long-Range DALI-2** — wireless lighting control integration  
1279
* **Radio Mesh (MIRA & BLE5)** — scalable multi-hop wireless automation  
1280
1281
This allows DTX to operate in environments where wired infrastructure is limited, expensive, or impossible — while maintaining complete BACnet interoperability and automation capabilities.
1282 1 Torbjorn Carlqvist Admin
1283
1284
---
1285
1286
1287
h3. Developer's Guide
1288
1289
[[IDE|IDE walk through]]
1290
[[Javascript|The DTXr Javascript guide]]
1291
[[Blockly|Blockly tutorials]]