@prefix dc: <http://purl.org/dc/elements/1.1/>.

<> dc:description """My home office network""",
	"$Id: opksnet.n3,v 1.11 2004/07/07 15:45:41 connolly Exp $".

@prefix log: <http://www.w3.org/2000/10/swap/log#> .
@prefix ont: <http://www.daml.org/2001/03/daml+oil#>.
@prefix u: <http://www.w3.org/2000/01/rdf-schema#>.
@prefix r: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .

@prefix : <opksnet#>.


######
# RDFS stuff

{ ?S [ u:domain ?C ] ?O } => { ?S a ?C }.
{ ?S [ u:range ?C ] ?O } => { ?O a ?C }.

{ ?S [ u:subPropertyOf ?P ] ?O } => { ?S ?P ?O }.

{ ?S a [ u:subClassOf ?C ] } => { ?S a ?C }.
u:subClassOf a ont:TransitiveProperty.

#####
# DAML+OIL stuff


{ ?S [ ont:inverseOf ?P ] ?O } => { ?O ?P ?S }.

# hasValue
{ ?S a [ ont:onProperty ?P; ont:hasValue ?O ] }
  => { ?S ?P ?O }.

# TransitiveProperty
{ ?P a ont:TransitiveProperty.
  ?S ?P [ ?P ?O ] } => { ?S ?P ?O }.


###########

:CableProperty u:subClassOf :ConnectionProperty.

:usb u:label "USB"; a :CableProperty. # directional; TODO: use domain/range
:firewire u:label "firewire"; a :CableProperty. # directional
:serial u:label "serial"; a :CableProperty.
:cat5 u:label "cat5"; a :CableProperty. # undirected.
:coax u:label "coax"; a :CableProperty. # undirected.
:rj11 u:label "rj11"; a :CableProperty. # undirected.
:scsi u:label "scsi"; a :CableProperty. # directed? show termination?
:vga u:label "VGA"; a :CableProperty. # directed?
:dc19v u:label "19v DC"; a :CableProperty. # undirected
:pw110v u:label "110v"; a :CableProperty. # undirected (sorta...)
:line u:label "line"; a :CableProperty;
  u:comment "audio line level". # undirected
:video u:label "video"; a :CableProperty.

:HWBusProperty u:subClassOf :ConnectionProperty.

:pcmcia u:label "PCMCIA"; a :HWBusProperty;
     u:range :PCMCIACard.
:pci u:label "PCI"; a :HWBusProperty;
     u:range :PCICard.
:isa u:label "ISA"; a :HWBusProperty;
     u:range :ISACard.

:touch a :ConnectionProperty; u:label "touch";
  u:comment "e.g. user touch keyboard".

:sight a :ConnectionProperty; u:label "sight";
  u:comment "e.g. user sight monitor".


:WirelessConnectionProperty u:subClassOf :ConnectionProperty.
:audio u:label "audio"; a :WirelessConnectionProperty.
:wvlan u:label "wireless"; a :WirelessConnectionProperty.
:irda u:label "IRDA"; a :WirelessConnectionProperty.
:gsm u:label "gsm"; a :WirelessConnectionProperty. # misnomer?
:mhz900 u:label "900mhz"; a :WirelessConnectionProperty.
:ghz2_4 u:label "2.4ghz"; a :WirelessConnectionProperty.

:SonyVaio u:subClassOf :Laptop, :PC.

:jammer u:label "jammer"; a :SonyVaio;
  is :usb of :logitechMouse;
  is :usb of :epscan;
  :dc19v [ u:label "Sony\\n19.5v"; :pw110v :outletG ];
  :pcmcia [ a :PCMCIACard; u:label "RoamAbout"; :wvlan :wvlanNET ].

:wvlanNET :netAddr "192.168.1.0".
:netAddr u:subPropertyOf u:label.

:skgizmo a :MobilePhone; u:label "sidekick";
  :gsm [ u:label "T-Mobile\\n+1-816-616-6576"];
  :obsoletes {

:danokia a :MobilePhone;
  u:label "Nokia\\n8129";
  :gsm [ u:label "636-7727"].
}.


:stripU a :PowerStrip; u:label "power strip\\n(UPS)";
  :pw110v :ups.


:logitechMouse u:label "Logitech\\noptical"; a :Mouse, :OpticalMouse.

:logitech u:label "Logitech".

:redMouse u:label "red Logitech\\nmouse"; a :Mouse, :OpticalMouse;
  :usb :usbHub;
  :manufacturer :logitech;
  is :touch of :dirkUser.

# from red logitech mouse:
#Type: UPA
#Code: 097855010179
# store label:
#Type: 128
#Code: 56901257e/

:ethDLink
  dc:description """
 9Dec2001 purchase at bestbuy
 D-Link DFE-530TX+ PCI NIC MIR
 upc code:
 Type: UPA
 Code: 790069220333""".

<> dc:description """
  TODO: use cuecat barcodes ala the above to document
  linux support of products; integrate with LHD.""".


:proSpkrs a :SpeakerPair; u:label "Inland\\nspeakers"; :pw110v :stripD;
  :audio :neoHandset; is :audio of :dirkUser;
  is :touch of :dirkUser. # volume knob


:dirk u:label "Dirk"; a [ = :Desktop; u:subClassOf :PC ];
  :pw110v :stripU;
  is :serial of [ a :CueCat; u:label "cuecat" ],
	[ a :Keyboard; u:label "ps2 keyboard" ];
  :cat5 :router54g;
  :pci [ u:label "nVidia@@\\ngraphics card";
         is :vga of [ u:label "NEC\\nMultiSync LCD1700M+"; a :Monitor;
                :pw110v :stripD; is :sight of :dirkUser ] ];
  is :pci of [ u:label "WinTV"; a :Card; is :video of :vidcam ];
  is :line of [ a :Microphone; u:label "mic" ];
  is :line of :proSpkrs;
  is :usb of :usbHub;

  :obsoletes 
{ # retired ~Dec 2001

# make a subgraph for the bounds of the case?

:shoal u:label "shoal"; a [ = :Desktop; u:subClassOf :PC];
  :usb [ u:label "jobie"; a :Printer; :pw110v :stripD ];
  :pw110v :stripU; # UPS?
  :pcmcia [ u:label "RoamAbout"; :wvlan :wvlanNET ];
  :pci  [ u:label "3c509 eth card"; :cat5 :hub ];
  :pci  [ u:label "BusLogic\\nscsi adapter";
          :scsi :scanner;
	  :scsi :cdwriter ];
  :pci [ u:label "ATI??@@\\ngraphics card";
         :vga [ u:label "NEC MultiSync 5FGe"; a :Monitor;
                :pw110v :stripD ] ];
  :line [ a :SpeakerPair; u:label "Hi-Fi\\nSound Monitor"; :pw110v :stripU ];
  :isa [ u:label "modem @@"; :rj11 :ph491-0501 ].

:cdwriter u:label "Plextor\\nCD writer".

}.

:logiKbd a :Keyboard; u:label "Logitech\\nkeyboard";
  dc:description "purchased 2004-01-30 from compusa";
  is :touch of :dirkUser;
  :usb :usbHub.

:usbHub a :Hub; u:label "USB 2.0\\nhub";
  :pw110v :stripD.


:vidcam a :LittleCamera; u:label "cam";
  is :sight of :dirkUser.

:neoHandset u:label "NEO\\nhandset";
  is :touch of :dirkUser; # sits on belt
  is :line of [ a :Headset; u:label "Uniden\\nheadset"; is :touch of :dirkUser ].

:neoPhone u:label "NEO\\phone base";
  dc:description """purchased 2004-04-09 at sams for $29.81""";
  a [ :UPA "050633201190" ];
  :pw110v :outlet;
  u:seeAlso <http://dm93.org/z2001/RemotePresence>;
  :rj11 :voiper;
  is :ghz2_4 of :neoHandset;
  :obsoletes {


:mhzPhone u:label "MNP-310\\n900mhz phone base";
  :pw110v :outlet;
  u:seeAlso <http://dm93.org/z2001/RemotePresence>;
  :rj11 :voiper;
  is :mhz900 of :mhzPhoneHandset;
  :obsoletes {


:ghzPhone u:label "BELL Equipment\\n2.4ghz phone base";
  :pw110v :outlet;
  u:seeAlso <http://www.w3.org/1998/12/telcon-gizmo.html>;
  a [ :UPA "075668838500"];
  :rj11 :voiper;
  is :ghz2_4 of :ghzPhoneHandset;
  :obsoletes {
[ u:label "RadioShack\\n900MHz cordless phone";
  :rj11 :ph491-0501;
  :pw110v :outlet ]
}.

:ghzPhoneHandset u:label "BELL\\nphone handset";
  is :touch of :dirkUser; # sits on belt
  is :line of [ a :Headset; u:label "Plantronics\\nheadset"; is :touch of :dirkUser ].

}.

:mhzPhoneHandset u:label "MNP-310\\nphone handset";
  is :touch of :dirkUser; # sits on belt
  is :audio of :dirkUser; # speakerphone
  is :line of [ a :Headset; u:label "Plantronics\\nheadset"; is :touch of :dirkUser ].
}.


:voiper u:label "CISCO ATA 186\\n+1-617-395-0241";
  :cat5 :router54g;
  :pw110v :stripU;
  :installed "25Mar2003";
  u:seeAlso <http://www.w3.org/Team/Phoneone.php3?who=connolly>.


:outlet u:label "east outlet".
:outletN u:label "north outlet".
:outletG u:label "downstairs outlet".

:mmac a :iMac, :Desktop; u:label "mmac";
  :cat5 :hhub;
  :rj11 :ph491-6405;
  :pw110v :stripM1;
  is :firewire of :mpod.

:mpod u:label "iPod mini";
 :obsoletes {
:riotunes a :WearableGizmo; u:label "Rio Mp3 player".
}.




:pesco u:label "pesco"; a :Printer;
  :pw110v :stripM1;
  :wvlan :wvlanNET;
  :obsoletes {

[ u:label "jobie"; a :Printer; :pw110v :stripD ].

:c40printer a :Printer; u:label "Epson C40UX";
  :pw110 :stripM1.

:wilma a :Printer; u:label "HP OfficeJet";
  :pw110v :stripD;
}.

:hhub a :Hub; u:label "Hawking\\n10/100 hub";
  a [ :UPA "603992504848"];
  dc:description "purchased 2004-07-06 at microcenter";
  :pw110v :stripM1;
  :cat5 :router54g;
  :obsoletes {

:hub a :Hub; u:label "ADDTRON\\n8-port hub";
  :manufacturer [ u:label "ADDTRON" ];
  :cat5 :wrouter;
  :pw110v :stripM1. #actually, it's a DC power cable to a brick to the strip
}.


:stripM1 a :PowerStrip; u:label "power strip\\nin studio".

:epscan a :Scanner; u:label "Epson 636U\\nscanner";
  :pw110v :outletG;
  :serialNumber "BDGX107766"; #@@ cuecat says type C39, from the box.
  :ordered "2002-03-04";
  :manufacturer [ u:label "Epson"; u:seeAlso <http://www.epson.com/> ];
#@@
# cuecat reads this UPS ground tracking number from the box:
# Type: 128
# Code: 1Z9100X40310566462
  :obsoletes {
:scanner a :Scanner; u:label "UMAX\\nscanner"; :pw110v :stripB.
}.

:bdmodem a :Modem; u:label "Best Data\\nmodem";
  # no longer connected.
  # :serial :dirk;
  # :rj11 :ph491-0501;
  #:pw110v :stripD
  .

:cmodem a :CableModem; u:label "WebST*R\\nCable modem";
  :coax :everest;
  :pw110v :stripU;
  :obsoletes

  { :dsl a :DSLModem; u:label "Speedstream\\nDSL modem";
  :rj11 :ph491-6405;
  :pw110v :stripA. # actually, thru a dc cable to a brick on the strip
  }.

:everest a :CableDataConnection; u:label "everestkc.net".

:stripD a :PowerStrip; u:label "power strip";
  :pw110v :outlet.

:ups u:label "Internet Office UPS"; a :Box;
  :pw110v :outletN.

:ph491-0501 u:label "491-0501".
:ph491-6405 u:label "491-6405".


:router54g u:label "Linksys\\nWRT54GS";
  a [
    :UPA "745883559183";
    u:subClassOf :InternetHost, :Box;
  ];
  :pw110v :stripU;
  :cat5 :cmodem;
  is :wvlan of :wvlanNET.

{
# wireless router
# hmm... model the box as a document?
# what's the subject of the UPC code? the product or a class to which the product belongs?
:wrouter u:label "Hawking\\nwireless router";
  dc:description "borked by lightning 2004-07-04";
  :pw110v :stripU;
  a [
    :UPA "603992503421";
    u:seeAlso <http://www.hawkingtech.com/products/wr254s.htm>;
    u:subClassOf :InternetHost, :Box;
    u:label "Wireless Router with 4-Port Switch";
    dc:description "Access Pointer, Router and Switch all in one";
    :model "WR254S";
    u:comment """Hawking Technology
Irvine, California, USA www.hawkingtech.com techsupport@hawkingtech.com"""
  ];
  u:comment """Ian told me Danny recommended an
   SMC wireless router.
   I saw it on sale for $169.99 at :KCMicrocenter.
   But I didn't get around to buying it until
   several weeks later, when the price had gone
   back up to $169.

   So in stead, I got this for $199; it
   seems to have all the same features except
   the print service.""";
  is :cat5 of :cmodem;
  :wvlan :wvlanNET.
}.



:UPA a r:Property; u:label "UPA";
  u:comment "'Type: UPA' says cat.py, a cue-cat script. see also: UPC codes";
  u:comment """from my bookmarks at the time:
                <DT><A HREF="http://freshmeat.net/news/2000/08/28/967502569.html" ADD_DATE="970722946" LAST_VISIT="970723124" LAST_MODIFIED="970722873">[fm] cuecat driver 0.0.4</A>
                <DT><A HREF="http://air-soldier.com/~cuecat/" ADD_DATE="979183855" LAST_VISIT="979188306" LAST_MODIFIED="979183168">Getting your CueCat declawed</A>
                <DT><A HREF="http://air-soldier.com/~cuecat/5minute.html" ADD_DATE="979150127" LAST_VISIT="979595948" LAST_MODIFIED="979150100">http://air-soldier.com/~cuecat/5minute.html</A>
                <DT><A HREF="http://opensource.lineo.com/cuecat/" ADD_DATE="979185905" LAST_VISIT="981397822" LAST_MODIFIED="979185884">The CueCat project homepage</A>""";
  u:seeAlso <http://www.flyingbuttmonkeys.com/useofthingsyouownisnowillegal/>,
            <http://webqcat.sourceforge.net/>,
 [ = <http://www.wired.com/news/print/0,1294,39139,00.html>;
   dc:title "Turning CueCat Into a Cool Cat";
   dc:creator "Leander Kahney"; #@@ ThingsVersusTheirNames
   dc:date "3:00 a.m. Oct. 3, 2000 PDT";
   dc:publisher "Wired News" ].





# extra memory for dirk
:dirkMem a [
  :UPA "761133828397";
  u:seeAlso <http://www.kbytememory.com/> #@@manufacturer? for-support?
].

#####
#
# considering moving computer to closet.
# Which parts need to be physically near the user?
#

:dirkUser u:label "dirk user". #@@ shape

########
#
# Networking diagram style
#

@prefix gv: <http://www.w3.org/2001/02pd/gv#>.

u:label u:subPropertyOf gv:label.


<> gv:digraph [
  gv:hasNode :jammer, :dirk, :skgizmo, :mmac;
  gv:subGraph [ gv:label "Key";
   gv:hasNode
     [ a :PC; gv:label "PC" ],
     [ a :Monitor; gv:label "Monitor" ],
     [ a :Card; gv:label "Card" ],
     [ a :Printer; gv:label "Printer" ]
  ]
].

:InterBoxProp u:subClassOf gv:EdgeProperty.
:IntraBoxProp u:subClassOf gv:EdgeProperty.
:ConnectionProperty u:subClassOf gv:EdgeProperty.

{ ?S gv:hasNode [ [ a gv:EdgeProperty] ?O ] } => { ?S gv:hasNode ?O }.
{ <> gv:digraph ?S.
  ?S gv:hasNode [ is [ a gv:EdgeProperty ] of ?O ] } => { ?S gv:hasNode ?O }.

:HWBusProperty u:subClassOf :IntraBoxProp.

:CableProperty u:subClassOf :InterBoxProp.
:WirelessConnectionProperty u:subClassOf :InterBoxProp.

:WirelessConnectionProperty u:subClassOf
	[ ont:onProperty gv:style; ont:hasValue "dotted" ].

:HWBusProperty u:subClassOf
	[ ont:onProperty gv:color; ont:hasValue "red" ].



:Box ont:onProperty gv:shape; ont:hasValue "box".
:Card u:subClassOf
  [ ont:onProperty gv:shape; ont:hasValue "polygon"],
  [ ont:onProperty gv:sides; ont:hasValue "7"]. #ugh...

:PCMCIACard u:subClassOf :Card,
  [ ont:onProperty gv:color; ont:hasValue "lawngreen" ].
:ISACard u:subClassOf :Card,
  [ ont:onProperty gv:color; ont:hasValue "powderblue" ].
:PCICard u:subClassOf :Card,
  [ ont:onProperty gv:color; ont:hasValue "salmon" ].

:PC u:subClassOf
	:Box,
	[ ont:onProperty gv:style; ont:hasValue "filled" ],
	[ ont:onProperty gv:color; ont:hasValue "blue" ]
        .

:Monitor u:subClassOf
	:Box,
	[ ont:onProperty gv:style; ont:hasValue "filled" ],
	[ ont:onProperty gv:color; ont:hasValue "green" ]
        .

:Hub u:subClassOf :Box.
:DSLModem u:subClassOf :Box.
:Scanner u:subClassOf :Box.
:Printer u:subClassOf :Box.
:SpeakerPair u:subClassOf :Box.
:WearableGizmo u:subClassOf :Box.

:Mouse u:subClassOf
        [ ont:onProperty gv:shape; ont:hasValue "polygon" ],
        [ ont:onProperty gv:sides; ont:hasValue "6" ].

:PowerStrip u:subClassOf
        [ ont:onProperty gv:shape; ont:hasValue "invtriangle" ].

:MobilePhone u:subClassOf
        :Box,
	[ ont:onProperty gv:color; ont:hasValue "blue" ].


