VLCB
Loading...
Searching...
No Matches
MinimumNodeServiceWithDiagnostics.h
Go to the documentation of this file.
1// Copyright (C) Sven Rosvall (sven@rosvall.ie)
2// This file is part of VLCB-Arduino project on https://github.com/SvenRosvall/VLCB-Arduino
3// Licensed under the Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License.
4// The full licence can be found at: http://creativecommons.org/licenses/by-nc-sa/4.0/
5
6#pragma once
7
9#include <vlcbdefs.hpp>
10
11namespace VLCB
12{
13
14struct VlcbMessage;
15
17{
18public:
19 virtual void reportDiagnostics(byte serviceIndex, byte diagnosticsCode) override;
20 virtual int getDiagnosticCount() override;
21
22protected:
23 virtual void handleMessage(const VlcbMessage *msg) override;
24 virtual void diagNodeNumberChanged() override;
25
26private:
27 void handleRequestDiagnostics(const VlcbMessage *msg, unsigned int nn);
28
29 unsigned int diagNodeNumberChanges = 0;
30};
31
32}
Definition MinimumNodeServiceWithDiagnostics.h:17
virtual int getDiagnosticCount() override
report how many diagnostics this service supports.
Definition MinimumNodeServiceWithDiagnostics.cpp:205
virtual void reportDiagnostics(byte serviceIndex, byte diagnosticsCode) override
Report a given diagnostic value.
Definition MinimumNodeServiceWithDiagnostics.cpp:168
virtual void handleMessage(const VlcbMessage *msg) override
Definition MinimumNodeServiceWithDiagnostics.cpp:12
virtual void diagNodeNumberChanged() override
Definition MinimumNodeServiceWithDiagnostics.cpp:200
Mandatory Service for node.
Definition MinimumNodeService.h:26
Definition AbstractEventTeachingService.cpp:13
CAN/Controller message type.
Definition Controller.h:30