SlideShare uma empresa Scribd logo
1 de 15
Drupal Home automation
       with VSCP
       Peter Bosmans
Concept
• Central swithpoint (teleruptors, relais)
• Simple network of distributed controllers (Ex.
  One for each room)
• No master-slave network (SPOF), No need to
  develop a new protocol
• Open source
  – Open hardware
  – Firmware , protocol
  – Controle software
Home automation controle software
•   Home remote (java – tomcat)
•   Linux MCE (based on Ubuntu)
•   Misterhouse (Perl – VSCP enabled)
•   Drupal
    – Webbased, permissions, taxonomy, …
    – Connection with a database (logging, views, …)
    – Expandable -> VSCP module
VSCP
• Very Simple Control Protocol
       http://sourceforge.net/projects/m2m/files/VSCP%20Specification/
       http://en.wikipedia.org/wiki/Very_Simple_Control_Protocol

• Open source
  multiplatform : windows, linux – multicontroller : PIC, AVR, ARM, …

• Runs on different physical layers
  –Level I : RS232, RS485, RF, CAN
  –Level II : Ethernet
• Event based
• Configurable Modules
  –Registers : I/O behavior, I/O zones-subzones
  –DM (Decision matrix) : Filter - Action
VSCP events
• Class : Collection of event types
  – INFORMATION(20) , ALARM(1), MEASUREMENT(10), ….

• Type : Type of event
  – CLASS INFORMATION : BUTTON(1), ON(3), OFF(4), BELOW LIMIT(10), …
  – CLASS MEASUREMENT : COUNT(1), TEMPERATURE(6), WEIGTH(3), …

• Zone : origination of event class-type
  – Basement(1), Ground floor(2), …

• Subzone : sub-origination of event class-type
  – Kitchen(1), Living room(2), Storage(3), Hall(4), …
Communicatie Drupal <-> VSCP



VSCPD
  – Gateway daemon between the CAN-network and IP-network.
  – DM for filter – action
•Incomming VSCP events
  CANbus -> USB2CAN convertor -> USB -> VSCPD -> DM -> PHPscript ->
    XMLPRC
        • DM starts PHPscript with an INFORMATION ON/OFF VSCP event
        • PHPscript creates an XMLRPC call to drupal

•Outgoing VSCP events
  Drupal VSCP module -> VSCPD -> USB -> USB2CAN convertor -> CANbus
VSCP module
• Taxonomy
   – Level I Events : Already configured within xml-file (Taxonomy import/export module)
   – Zones-Subzones : configurable by user
        • Hiërarchical
        • Synonymous field contains the de zone- of subzonenumber

• Contenttypes
   – VSCPevent : Elk VSCPevent heeft een corresponderende Drupal node
        • Taxonomy : Determines het VSCP-event (class, type, zone, subzone)
        • Byte0 : Needed by specific events
        • Data : Needed by specific events
        • Node references (sended, received) : Connection between, the sended and received ,
          VSCP events
        • Logtype : Type of logging ; through revisions of nodes of the contenttype VSCPlog
        • Log reference : Reference to the logging-node when using the type of logging through
          revisions.
        • Button : The corresponding VSCP event of the node will be sended
   – VSCPlog
        • Class, Type, Byte0, Zone, Subzone, Data : Field for the corresponding values.
VSCP module
•   Self-learning by every received event
     – On Node niveau
         • check the VSCP class, type, zone en subzone
         • If the node doesn’t exists : create node
         • If the node exists :
              – update node timestamp
              – Indien referentie naar een send event node : update de receive referentie in de send event
                node
     – On Taxonomie niveau (Zone-Subzone)
         • If the zone and/or subzone doesn’t exists : create the new term

• References
   To connect the last received VSCP event to his
   corresponding sending VSCP event
   Ex.:
   - Connect ‘on/off events’ on ‘button events’.
   - Connect the event of a measured value on the
   determination event that sets a temperature.
VSCP module
• Rules integration
   – Rule trigger :
      • After a VSCP event is received
   – Rule conditions :
      •   VSCP event has zone
      •   VSCP event has subzone
      •   VSCP event has class
      •   VSCP event had type
      •   VSCP event had byte0
      •   VSCP event had databytes
   – Rule action :
      • Send a VSCP event
   – Rule sets
      • Useful for scheduling VSCPevents
Demo : Technical structure
• Electrical installation




• Nodes : CAN based modules
   Configuration :
   IN1, OUT1 => Zone = 1 = ‘Basement’ ; Subzone = 1 = ‘Supply’
   IN2, OUT2 => Zone = 2 = ‘Ground floor’ ; Subzone = 1 = ‘Kitchen’
   IN3, OUT3 => Zone = 2 = ‘Ground floor’ ; Subzone = 2 = ‘Living room’
Demo : Drupal - VSCP
• Configuration :
   – Manual setup
       • Taxonomy ‘Zone-Subzone’
       • Content VSCPevent ‘Information – Button’
   – Semi-Automatic with the self-learning mode
       • Taxonomy ‘Zone-Subzone’
       • Content VSCPevent ‘Information – On/Off’
            – Connect the received VSCPevent to the corresponding sended VSCPevent.
• Views :
   – Buttons view : List of ‘Information - button’ VSCP events which contains a
     relation to the last received ‘Information – On/Off’ event
• Some rules examples :
   – ButtonSendEvent : responsible to send the VSCPevent and refresh the page
     after a little time delay.
   – Basement Supply ON – Email : Sends a mail when someone the on the light o
     specific room.
• Rulessets :
   – Schedules VSCPevents. Ex. Switch lights every 2 minutes
   – …
Future developments
•   More sensor integration (temperature, light, …)
•   More widgets for drupal
•   Ajax integration
•   Drupal 7 migration
•   Integration of MQTT within the VSCP daemon
    MQTT (MQ Telemetry Transport) : extremely lightweight
    ‘publish/subscribe’ messaging transport through a ‘broker’
• Integration of WS within the VSCP daemon (HTML5)
• https://www.thingspeak.com/,
  https://pachube.com/, …
Questions ??


Useful Links

VSCP :
         http://www.vscp.org/
VSCP source :
         http://sourceforge.net/projects/m2m/?source=directory
VSCP drupal module :
         http://drupal.org/sandbox/pbosmans/1429844
VSCP kiewit hardware module :
https://sourceforge.net/p/vscpmodules/kiewit
Feedback & follow-up:
http://drupalcampgent.be/feedback

Mais conteúdo relacionado

Semelhante a Drupal home automation with vscp

Debschallange 140530214713-phpapp01 (1)
Debschallange 140530214713-phpapp01 (1)Debschallange 140530214713-phpapp01 (1)
Debschallange 140530214713-phpapp01 (1)
Arshia Jabeen
 

Semelhante a Drupal home automation with vscp (20)

Actors or Not: Async Event Architectures
Actors or Not: Async Event ArchitecturesActors or Not: Async Event Architectures
Actors or Not: Async Event Architectures
 
Guaranteed Event Delivery with Kafka and NodeJS | Amitesh Madhur, Nutanix
Guaranteed Event Delivery with Kafka and NodeJS | Amitesh Madhur, NutanixGuaranteed Event Delivery with Kafka and NodeJS | Amitesh Madhur, Nutanix
Guaranteed Event Delivery with Kafka and NodeJS | Amitesh Madhur, Nutanix
 
Springone2gx 2014 Reactive Streams and Reactor
Springone2gx 2014 Reactive Streams and ReactorSpringone2gx 2014 Reactive Streams and Reactor
Springone2gx 2014 Reactive Streams and Reactor
 
StackWatch: A prototype CloudWatch service for CloudStack
StackWatch: A prototype CloudWatch service for CloudStackStackWatch: A prototype CloudWatch service for CloudStack
StackWatch: A prototype CloudWatch service for CloudStack
 
[Free OpManager training] Part 4- Network fault-management & IT automation
[Free OpManager training]  Part 4- Network fault-management & IT automation[Free OpManager training]  Part 4- Network fault-management & IT automation
[Free OpManager training] Part 4- Network fault-management & IT automation
 
Building the Internet of Things with Thingsquare and Contiki - day 1, part 3
Building the Internet of Things with Thingsquare and Contiki - day 1, part 3Building the Internet of Things with Thingsquare and Contiki - day 1, part 3
Building the Internet of Things with Thingsquare and Contiki - day 1, part 3
 
Docker summit : Docker Networking Control-plane & Data-Plane
Docker summit : Docker Networking Control-plane & Data-PlaneDocker summit : Docker Networking Control-plane & Data-Plane
Docker summit : Docker Networking Control-plane & Data-Plane
 
Docker Networking: Control plane and Data plane
Docker Networking: Control plane and Data planeDocker Networking: Control plane and Data plane
Docker Networking: Control plane and Data plane
 
Solving DEBS Grand Challenge with WSO2 CEP
Solving DEBS Grand Challenge with WSO2 CEPSolving DEBS Grand Challenge with WSO2 CEP
Solving DEBS Grand Challenge with WSO2 CEP
 
Debschallange 140530214713-phpapp01 (1)
Debschallange 140530214713-phpapp01 (1)Debschallange 140530214713-phpapp01 (1)
Debschallange 140530214713-phpapp01 (1)
 
Notes on Netty baics
Notes on Netty baicsNotes on Netty baics
Notes on Netty baics
 
Building scalable flexible messaging systems using qpid
Building scalable flexible messaging systems using qpidBuilding scalable flexible messaging systems using qpid
Building scalable flexible messaging systems using qpid
 
Public private hybrid - cmdb challenge
Public private hybrid - cmdb challengePublic private hybrid - cmdb challenge
Public private hybrid - cmdb challenge
 
Spark streaming
Spark streamingSpark streaming
Spark streaming
 
PLNOG 17 - Tomasz Stachlewski - Infrastruktura sieciowa w chmurze AWS
PLNOG 17 - Tomasz Stachlewski - Infrastruktura sieciowa w chmurze AWSPLNOG 17 - Tomasz Stachlewski - Infrastruktura sieciowa w chmurze AWS
PLNOG 17 - Tomasz Stachlewski - Infrastruktura sieciowa w chmurze AWS
 
(ARC401) Black-Belt Networking for the Cloud Ninja | AWS re:Invent 2014
(ARC401) Black-Belt Networking for the Cloud Ninja | AWS re:Invent 2014(ARC401) Black-Belt Networking for the Cloud Ninja | AWS re:Invent 2014
(ARC401) Black-Belt Networking for the Cloud Ninja | AWS re:Invent 2014
 
Amazon Virtual Private Cloud
Amazon Virtual Private CloudAmazon Virtual Private Cloud
Amazon Virtual Private Cloud
 
High throughput data streaming in Azure
High throughput data streaming in AzureHigh throughput data streaming in Azure
High throughput data streaming in Azure
 
10 sdn-vir-6up
10 sdn-vir-6up10 sdn-vir-6up
10 sdn-vir-6up
 
Free NetFlow Analyzer training - Getting the initial settings right
Free NetFlow Analyzer training - Getting the initial settings rightFree NetFlow Analyzer training - Getting the initial settings right
Free NetFlow Analyzer training - Getting the initial settings right
 

Último

CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Service
giselly40
 

Último (20)

The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
 
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men08448380779 Call Girls In Greater Kailash - I Women Seeking Men
08448380779 Call Girls In Greater Kailash - I Women Seeking Men
 
Evaluating the top large language models.pdf
Evaluating the top large language models.pdfEvaluating the top large language models.pdf
Evaluating the top large language models.pdf
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdf
 
Tech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdfTech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdf
 
Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...Driving Behavioral Change for Information Management through Data-Driven Gree...
Driving Behavioral Change for Information Management through Data-Driven Gree...
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?What Are The Drone Anti-jamming Systems Technology?
What Are The Drone Anti-jamming Systems Technology?
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Service
 

Drupal home automation with vscp

  • 1. Drupal Home automation with VSCP Peter Bosmans
  • 2. Concept • Central swithpoint (teleruptors, relais) • Simple network of distributed controllers (Ex. One for each room) • No master-slave network (SPOF), No need to develop a new protocol • Open source – Open hardware – Firmware , protocol – Controle software
  • 3. Home automation controle software • Home remote (java – tomcat) • Linux MCE (based on Ubuntu) • Misterhouse (Perl – VSCP enabled) • Drupal – Webbased, permissions, taxonomy, … – Connection with a database (logging, views, …) – Expandable -> VSCP module
  • 4. VSCP • Very Simple Control Protocol http://sourceforge.net/projects/m2m/files/VSCP%20Specification/ http://en.wikipedia.org/wiki/Very_Simple_Control_Protocol • Open source multiplatform : windows, linux – multicontroller : PIC, AVR, ARM, … • Runs on different physical layers –Level I : RS232, RS485, RF, CAN –Level II : Ethernet • Event based • Configurable Modules –Registers : I/O behavior, I/O zones-subzones –DM (Decision matrix) : Filter - Action
  • 5. VSCP events • Class : Collection of event types – INFORMATION(20) , ALARM(1), MEASUREMENT(10), …. • Type : Type of event – CLASS INFORMATION : BUTTON(1), ON(3), OFF(4), BELOW LIMIT(10), … – CLASS MEASUREMENT : COUNT(1), TEMPERATURE(6), WEIGTH(3), … • Zone : origination of event class-type – Basement(1), Ground floor(2), … • Subzone : sub-origination of event class-type – Kitchen(1), Living room(2), Storage(3), Hall(4), …
  • 6. Communicatie Drupal <-> VSCP VSCPD – Gateway daemon between the CAN-network and IP-network. – DM for filter – action •Incomming VSCP events CANbus -> USB2CAN convertor -> USB -> VSCPD -> DM -> PHPscript -> XMLPRC • DM starts PHPscript with an INFORMATION ON/OFF VSCP event • PHPscript creates an XMLRPC call to drupal •Outgoing VSCP events Drupal VSCP module -> VSCPD -> USB -> USB2CAN convertor -> CANbus
  • 7. VSCP module • Taxonomy – Level I Events : Already configured within xml-file (Taxonomy import/export module) – Zones-Subzones : configurable by user • Hiërarchical • Synonymous field contains the de zone- of subzonenumber • Contenttypes – VSCPevent : Elk VSCPevent heeft een corresponderende Drupal node • Taxonomy : Determines het VSCP-event (class, type, zone, subzone) • Byte0 : Needed by specific events • Data : Needed by specific events • Node references (sended, received) : Connection between, the sended and received , VSCP events • Logtype : Type of logging ; through revisions of nodes of the contenttype VSCPlog • Log reference : Reference to the logging-node when using the type of logging through revisions. • Button : The corresponding VSCP event of the node will be sended – VSCPlog • Class, Type, Byte0, Zone, Subzone, Data : Field for the corresponding values.
  • 8. VSCP module • Self-learning by every received event – On Node niveau • check the VSCP class, type, zone en subzone • If the node doesn’t exists : create node • If the node exists : – update node timestamp – Indien referentie naar een send event node : update de receive referentie in de send event node – On Taxonomie niveau (Zone-Subzone) • If the zone and/or subzone doesn’t exists : create the new term • References To connect the last received VSCP event to his corresponding sending VSCP event Ex.: - Connect ‘on/off events’ on ‘button events’. - Connect the event of a measured value on the determination event that sets a temperature.
  • 9. VSCP module • Rules integration – Rule trigger : • After a VSCP event is received – Rule conditions : • VSCP event has zone • VSCP event has subzone • VSCP event has class • VSCP event had type • VSCP event had byte0 • VSCP event had databytes – Rule action : • Send a VSCP event – Rule sets • Useful for scheduling VSCPevents
  • 10. Demo : Technical structure • Electrical installation • Nodes : CAN based modules Configuration : IN1, OUT1 => Zone = 1 = ‘Basement’ ; Subzone = 1 = ‘Supply’ IN2, OUT2 => Zone = 2 = ‘Ground floor’ ; Subzone = 1 = ‘Kitchen’ IN3, OUT3 => Zone = 2 = ‘Ground floor’ ; Subzone = 2 = ‘Living room’
  • 11. Demo : Drupal - VSCP • Configuration : – Manual setup • Taxonomy ‘Zone-Subzone’ • Content VSCPevent ‘Information – Button’ – Semi-Automatic with the self-learning mode • Taxonomy ‘Zone-Subzone’ • Content VSCPevent ‘Information – On/Off’ – Connect the received VSCPevent to the corresponding sended VSCPevent. • Views : – Buttons view : List of ‘Information - button’ VSCP events which contains a relation to the last received ‘Information – On/Off’ event • Some rules examples : – ButtonSendEvent : responsible to send the VSCPevent and refresh the page after a little time delay. – Basement Supply ON – Email : Sends a mail when someone the on the light o specific room. • Rulessets : – Schedules VSCPevents. Ex. Switch lights every 2 minutes – …
  • 12. Future developments • More sensor integration (temperature, light, …) • More widgets for drupal • Ajax integration • Drupal 7 migration • Integration of MQTT within the VSCP daemon MQTT (MQ Telemetry Transport) : extremely lightweight ‘publish/subscribe’ messaging transport through a ‘broker’ • Integration of WS within the VSCP daemon (HTML5) • https://www.thingspeak.com/, https://pachube.com/, …
  • 13. Questions ?? Useful Links VSCP : http://www.vscp.org/ VSCP source : http://sourceforge.net/projects/m2m/?source=directory VSCP drupal module : http://drupal.org/sandbox/pbosmans/1429844 VSCP kiewit hardware module : https://sourceforge.net/p/vscpmodules/kiewit
  • 14.