IoT/M2MIWG/Machine-to-machine model
< IoT
Contents
Requirements
Tree structure
- REST-like resource model
- ease the management of access rights
- improved extensibility
Core model + extensions
- CORE
- Application State
- Data
- Events
- Commands
- Settings?
- Communication capabilities
- Application State
- Extensions
- Validation
- enum
- min/max
- length
- see JSR-303??? / "Built-in constraint definitions" in particular
- see XSD Restrictions?
- Units
- Access rights
- Archiving policy?
- Logical grouping/tagging
- useless at development time?
- i18n
- Monitoring
- define a prefered way to update resource tree
- Rules
- Use it for monitoring?
- Use it to react to commands?
- Drools?
- Notification
- "Local" communication protocol?
- use openHAB binding mechanism???
- Web Service/REST mapping???
- Validation
Open questions
- Versioning?
- Is there really a difference between settings and data?
- Is a path a valid way to identify data/events/commands...? (vs UUID or anything else)
Examples
Application model
-- author: Benjamin Cabé -- revision: 1.0 Application "HomeAutomation" CommunicationCapabilities { ????? } Data { Rooms Room1 TempSensor1 value (int) batteryLevel (int) macAddress (string) Curtain1 position (int) macAddress (string) Room2 TempSensor1 (WavenisTemperatureSensor) } Events { TemperatureTooHot Intrusion, ACK } Settings { ???? } Commands { ToggleCurtains(OPEN=default|CLOSE) }
typedef model
-- author: Benjamin Cabé -- revision 1.0 include 'tcpip' Type "WavenisSensor" { serialNumber: string, macAddress: tcpip.MacAddress, batteryLevel: float, [...] } Type "WavenisTemperatureSensor" extends "WavenisSensor"{ temperature: float }
rules model
-- author: Benjamin Cabé -- revision 1.0 Rules for application "HomeAutomation" v1.0 rule "trigger TemperatureTooHot" when (Rooms/Room1/TempSensor1 + Rooms/Room2/TempSensor1) / 2 > 25.0 then TemperatureTooHot() end
i18n model
-- author: Benjamin Cabé -- revision 1.0 i18n for application "HomeAutomation" v1.0 en: Data/Rooms=House rooms Data/Rooms/Room1=Living Room Data/Rooms/Room1/TempSensor1=Temperature [...] fr_FR: Data/Rooms=Pièces de la maison Data/Rooms/Room1=Salon Data/Rooms/Room1/TempSensor1=Température [...]