Skip to content
Snippets Groups Projects
Commit 3a628d2f authored by Tim Stadtmann's avatar Tim Stadtmann
Browse files

Cleanup doc process-script and add pdf-doc

parent f8b621ea
No related branches found
No related tags found
No related merge requests found
File deleted
No preview for this file type
......@@ -57,17 +57,17 @@
\newlabel{EV3:source.EV3.debug}{{1.3}{4}{Notes}{section*.14}{}}
\newlabel{EV3:source.EV3.batteryMode}{{1.3}{4}{Notes}{section*.15}{}}
\newlabel{EV3:source.EV3.batteryValue}{{1.3}{4}{Notes}{section*.16}{}}
\newlabel{EV3:source.EV3.isConnected}{{1.3}{4}{Notes}{section*.17}{}}
\@writefile{toc}{\contentsline {paragraph}{Example}{4}{paragraph*.18}}
\newlabel{EV3:source.EV3.beep}{{1.3}{4}{Example}{section*.19}{}}
\newlabel{EV3:source.EV3.isConnected}{{1.3}{5}{Notes}{section*.17}{}}
\@writefile{toc}{\contentsline {paragraph}{Example}{5}{paragraph*.18}}
\newlabel{EV3:source.EV3.beep}{{1.3}{5}{Example}{section*.19}{}}
\@writefile{toc}{\contentsline {paragraph}{Notes}{5}{paragraph*.20}}
\@writefile{toc}{\contentsline {paragraph}{Example}{5}{paragraph*.21}}
\newlabel{EV3:source.EV3.connect}{{1.3}{5}{Example}{section*.22}{}}
\@writefile{toc}{\contentsline {paragraph}{Example}{5}{paragraph*.23}}
\newlabel{EV3:source.EV3.disconnect}{{1.3}{5}{Example}{section*.24}{}}
\@writefile{toc}{\contentsline {paragraph}{Notes}{5}{paragraph*.25}}
\@writefile{toc}{\contentsline {paragraph}{Example}{5}{paragraph*.26}}
\newlabel{EV3:source.EV3.playTone}{{1.3}{5}{Example}{section*.27}{}}
\@writefile{toc}{\contentsline {paragraph}{Example}{6}{paragraph*.26}}
\newlabel{EV3:source.EV3.playTone}{{1.3}{6}{Example}{section*.27}{}}
\@writefile{toc}{\contentsline {paragraph}{Example}{6}{paragraph*.28}}
\newlabel{EV3:source.EV3.setProperties}{{1.3}{6}{Example}{section*.29}{}}
\@writefile{toc}{\contentsline {paragraph}{Example}{6}{paragraph*.30}}
......@@ -76,37 +76,37 @@
\@writefile{toc}{\contentsline {paragraph}{Example}{6}{paragraph*.33}}
\newlabel{EV3:source.EV3.tonePlayed}{{1.3}{6}{Example}{section*.34}{}}
\newlabel{Motor:module-source}{{1.3}{6}{EV3}{section*.35}{}}
\@writefile{toc}{\contentsline {section}{\numberline {1.4}Motor}{6}{section.1.4}}
\newlabel{Motor::doc}{{1.4}{6}{Motor}{section.1.4}{}}
\newlabel{Motor:motor}{{1.4}{6}{Motor}{section.1.4}{}}
\newlabel{Motor:source.Motor}{{1.4}{6}{Motor}{section*.36}{}}
\@writefile{toc}{\contentsline {section}{\numberline {1.4}Motor}{7}{section.1.4}}
\newlabel{Motor::doc}{{1.4}{7}{Motor}{section.1.4}{}}
\newlabel{Motor:motor}{{1.4}{7}{Motor}{section.1.4}{}}
\newlabel{Motor:source.Motor}{{1.4}{7}{Motor}{section*.36}{}}
\@writefile{toc}{\contentsline {paragraph}{Notes}{7}{paragraph*.37}}
\newlabel{Motor:source.Motor.power}{{1.4}{7}{Notes}{section*.38}{}}
\newlabel{Motor:source.Motor.speedRegulation}{{1.4}{7}{Notes}{section*.39}{}}
\newlabel{Motor:source.Motor.smoothStart}{{1.4}{7}{Notes}{section*.40}{}}
\newlabel{Motor:source.Motor.smoothStop}{{1.4}{7}{Notes}{section*.41}{}}
\newlabel{Motor:source.Motor.limitValue}{{1.4}{7}{Notes}{section*.42}{}}
\newlabel{Motor:source.Motor.limitMode}{{1.4}{7}{Notes}{section*.43}{}}
\newlabel{Motor:source.Motor.brakeMode}{{1.4}{7}{Notes}{section*.44}{}}
\newlabel{Motor:source.Motor.debug}{{1.4}{7}{Notes}{section*.45}{}}
\newlabel{Motor:source.Motor.isRunning}{{1.4}{7}{Notes}{section*.46}{}}
\newlabel{Motor:source.Motor.tachoCount}{{1.4}{7}{Notes}{section*.47}{}}
\newlabel{Motor:source.Motor.currentSpeed}{{1.4}{7}{Notes}{section*.48}{}}
\newlabel{Motor:source.Motor.type}{{1.4}{7}{Notes}{section*.49}{}}
\newlabel{Motor:source.Motor.limitValue}{{1.4}{8}{Notes}{section*.42}{}}
\newlabel{Motor:source.Motor.limitMode}{{1.4}{8}{Notes}{section*.43}{}}
\newlabel{Motor:source.Motor.brakeMode}{{1.4}{8}{Notes}{section*.44}{}}
\newlabel{Motor:source.Motor.debug}{{1.4}{8}{Notes}{section*.45}{}}
\newlabel{Motor:source.Motor.isRunning}{{1.4}{8}{Notes}{section*.46}{}}
\newlabel{Motor:source.Motor.tachoCount}{{1.4}{8}{Notes}{section*.47}{}}
\newlabel{Motor:source.Motor.currentSpeed}{{1.4}{8}{Notes}{section*.48}{}}
\newlabel{Motor:source.Motor.type}{{1.4}{8}{Notes}{section*.49}{}}
\newlabel{Motor:source.Motor.internalReset}{{1.4}{8}{Notes}{section*.50}{}}
\@writefile{toc}{\contentsline {paragraph}{Notes}{8}{paragraph*.51}}
\newlabel{Motor:source.Motor.resetTachoCount}{{1.4}{8}{Notes}{section*.52}{}}
\newlabel{Motor:source.Motor.setBrake}{{1.4}{8}{Notes}{section*.53}{}}
\@writefile{toc}{\contentsline {paragraph}{Notes}{8}{paragraph*.54}}
\newlabel{Motor:source.Motor.setProperties}{{1.4}{8}{Notes}{section*.55}{}}
\@writefile{toc}{\contentsline {paragraph}{Notes}{9}{paragraph*.54}}
\newlabel{Motor:source.Motor.setProperties}{{1.4}{9}{Notes}{section*.55}{}}
\@writefile{toc}{\contentsline {paragraph}{Example}{9}{paragraph*.56}}
\newlabel{Motor:source.Motor.start}{{1.4}{9}{Notes}{section*.57}{}}
\newlabel{Motor:source.Motor.stop}{{1.4}{9}{Notes}{section*.58}{}}
\@writefile{toc}{\contentsline {paragraph}{Notes}{9}{paragraph*.59}}
\newlabel{Motor:source.Motor.syncedStart}{{1.4}{9}{Notes}{section*.60}{}}
\@writefile{toc}{\contentsline {paragraph}{Notes}{9}{paragraph*.61}}
\@writefile{toc}{\contentsline {paragraph}{Example}{9}{paragraph*.62}}
\newlabel{Motor:source.Motor.syncedStop}{{1.4}{9}{Notes}{section*.63}{}}
\@writefile{toc}{\contentsline {paragraph}{Notes}{10}{paragraph*.61}}
\@writefile{toc}{\contentsline {paragraph}{Example}{10}{paragraph*.62}}
\newlabel{Motor:source.Motor.syncedStop}{{1.4}{10}{Notes}{section*.63}{}}
\@writefile{toc}{\contentsline {paragraph}{Notes}{10}{paragraph*.64}}
\newlabel{Motor:source.Motor.waitFor}{{1.4}{10}{Notes}{section*.65}{}}
\@writefile{toc}{\contentsline {paragraph}{Notes}{10}{paragraph*.66}}
......@@ -115,29 +115,86 @@
\newlabel{Sensor:sensor}{{1.5}{10}{Sensor}{section.1.5}{}}
\newlabel{Sensor::doc}{{1.5}{10}{Sensor}{section.1.5}{}}
\newlabel{Sensor:source.Sensor}{{1.5}{10}{Sensor}{section*.68}{}}
\@writefile{toc}{\contentsline {paragraph}{Notes}{10}{paragraph*.69}}
\newlabel{Sensor:source.Sensor.mode}{{1.5}{10}{Notes}{section*.70}{}}
\@writefile{toc}{\contentsline {paragraph}{Notes}{11}{paragraph*.69}}
\newlabel{Sensor:source.Sensor.mode}{{1.5}{11}{Notes}{section*.70}{}}
\newlabel{Sensor:source.Sensor.debug}{{1.5}{12}{Notes}{section*.71}{}}
\newlabel{Sensor:source.Sensor.value}{{1.5}{12}{Notes}{section*.72}{}}
\newlabel{Sensor:source.Sensor.type}{{1.5}{12}{Notes}{section*.73}{}}
\newlabel{Sensor:source.Sensor.value}{{1.5}{13}{Notes}{section*.72}{}}
\newlabel{Sensor:source.Sensor.type}{{1.5}{13}{Notes}{section*.73}{}}
\newlabel{Sensor:source.Sensor.reset}{{1.5}{13}{Notes}{section*.74}{}}
\@writefile{toc}{\contentsline {paragraph}{Notes}{13}{paragraph*.75}}
\newlabel{Sensor:source.Sensor.setProperties}{{1.5}{13}{Notes}{section*.76}{}}
\@writefile{toc}{\contentsline {paragraph}{Example}{13}{paragraph*.77}}
\newlabel{CommandLayer:module-source}{{1.5}{13}{Sensor}{section*.78}{}}
\@writefile{toc}{\contentsline {section}{\numberline {1.6}CommandLayer}{13}{section.1.6}}
\newlabel{CommandLayer:commandlayer}{{1.6}{13}{CommandLayer}{section.1.6}{}}
\newlabel{CommandLayer::doc}{{1.6}{13}{CommandLayer}{section.1.6}{}}
\@writefile{toc}{\contentsline {subsection}{\numberline {1.6.1}Command}{13}{subsection.1.6.1}}
\newlabel{CommandLayer:command}{{1.6.1}{13}{Command}{subsection.1.6.1}{}}
\@writefile{toc}{\contentsline {subsection}{\numberline {1.6.2}CommunicationInterface}{13}{subsection.1.6.2}}
\newlabel{CommandLayer:communicationinterface}{{1.6.2}{13}{CommunicationInterface}{subsection.1.6.2}{}}
\newlabel{CommunicationLayer:module-source}{{1.6.2}{13}{CommunicationInterface}{section*.79}{}}
\@writefile{toc}{\contentsline {section}{\numberline {1.7}CommunicationLayer}{13}{section.1.7}}
\newlabel{CommunicationLayer:communicationlayer}{{1.7}{13}{CommunicationLayer}{section.1.7}{}}
\newlabel{CommunicationLayer::doc}{{1.7}{13}{CommunicationLayer}{section.1.7}{}}
\@writefile{toc}{\contentsline {subsection}{\numberline {1.7.1}USB}{13}{subsection.1.7.1}}
\newlabel{CommunicationLayer:usb}{{1.7.1}{13}{USB}{subsection.1.7.1}{}}
\@writefile{toc}{\contentsline {subsection}{\numberline {1.7.2}Bluetooth}{13}{subsection.1.7.2}}
\newlabel{CommunicationLayer:bluetooth}{{1.7.2}{13}{Bluetooth}{subsection.1.7.2}{}}
\@writefile{toc}{\contentsline {chapter}{Index}{15}{section*.80}}
\@writefile{toc}{\contentsline {paragraph}{Example}{14}{paragraph*.77}}
\newlabel{hid:module-source}{{1.5}{14}{Sensor}{section*.78}{}}
\@writefile{toc}{\contentsline {section}{\numberline {1.6}hidapi}{14}{section.1.6}}
\newlabel{hid:hidapi}{{1.6}{14}{hidapi}{section.1.6}{}}
\newlabel{hid::doc}{{1.6}{14}{hidapi}{section.1.6}{}}
\newlabel{hid:source.hidapi}{{1.6}{14}{hidapi}{section*.79}{}}
\@writefile{toc}{\contentsline {paragraph}{Notes}{14}{paragraph*.80}}
\newlabel{hid:source.hidapi.handle}{{1.6}{14}{Notes}{section*.81}{}}
\newlabel{hid:source.hidapi.vendorID}{{1.6}{14}{Notes}{section*.82}{}}
\newlabel{hid:source.hidapi.productID}{{1.6}{14}{Notes}{section*.83}{}}
\newlabel{hid:source.hidapi.nReadBuffer}{{1.6}{14}{Notes}{section*.84}{}}
\newlabel{hid:source.hidapi.nWriteBuffer}{{1.6}{15}{Notes}{section*.85}{}}
\newlabel{hid:source.hidapi.slib}{{1.6}{15}{Notes}{section*.86}{}}
\newlabel{hid:source.hidapi.sheader}{{1.6}{15}{Notes}{section*.87}{}}
\@writefile{toc}{\contentsline {paragraph}{Example}{15}{paragraph*.88}}
\newlabel{hid:source.hidapi.close}{{1.6}{15}{Example}{section*.89}{}}
\@writefile{toc}{\contentsline {paragraph}{Notes}{15}{paragraph*.90}}
\newlabel{hid:source.hidapi.enumerate}{{1.6}{15}{Example}{section*.91}{}}
\@writefile{toc}{\contentsline {paragraph}{Notes}{15}{paragraph*.92}}
\newlabel{hid:source.hidapi.error}{{1.6}{15}{Example}{section*.93}{}}
\@writefile{toc}{\contentsline {paragraph}{Notes}{15}{paragraph*.94}}
\newlabel{hid:source.hidapi.exit}{{1.6}{16}{Example}{section*.95}{}}
\newlabel{hid:source.hidapi.getHIDInfoString}{{1.6}{16}{Example}{section*.96}{}}
\@writefile{toc}{\contentsline {paragraph}{Notes}{16}{paragraph*.97}}
\newlabel{hid:source.hidapi.getManufacturersString}{{1.6}{16}{Example}{section*.98}{}}
\newlabel{hid:source.hidapi.getProductString}{{1.6}{16}{Example}{section*.99}{}}
\newlabel{hid:source.hidapi.getSerialNumberString}{{1.6}{16}{Example}{section*.100}{}}
\newlabel{hid:source.hidapi.init}{{1.6}{16}{Example}{section*.101}{}}
\@writefile{toc}{\contentsline {paragraph}{Notes}{16}{paragraph*.102}}
\newlabel{hid:source.hidapi.open}{{1.6}{16}{Example}{section*.103}{}}
\@writefile{toc}{\contentsline {paragraph}{Notes}{16}{paragraph*.104}}
\newlabel{hid:source.hidapi.read}{{1.6}{17}{Example}{section*.105}{}}
\@writefile{toc}{\contentsline {paragraph}{Notes}{17}{paragraph*.106}}
\newlabel{hid:source.hidapi.read_timeout}{{1.6}{17}{Example}{section*.107}{}}
\newlabel{hid:source.hidapi.setNonBlocking}{{1.6}{17}{Example}{section*.108}{}}
\newlabel{hid:source.hidapi.write}{{1.6}{17}{Example}{section*.109}{}}
\@writefile{toc}{\contentsline {paragraph}{Notes}{17}{paragraph*.110}}
\newlabel{usbBrickIO:module-source}{{1.6}{17}{hidapi}{section*.111}{}}
\@writefile{toc}{\contentsline {section}{\numberline {1.7}usbBrickIO}{18}{section.1.7}}
\newlabel{usbBrickIO:usbbrickio}{{1.7}{18}{usbBrickIO}{section.1.7}{}}
\newlabel{usbBrickIO::doc}{{1.7}{18}{usbBrickIO}{section.1.7}{}}
\newlabel{usbBrickIO:source.usbBrickIO}{{1.7}{18}{usbBrickIO}{section*.112}{}}
\@writefile{toc}{\contentsline {paragraph}{Notes}{18}{paragraph*.113}}
\newlabel{usbBrickIO:source.usbBrickIO.debug}{{1.7}{18}{Notes}{section*.114}{}}
\newlabel{usbBrickIO:source.usbBrickIO.vendorID}{{1.7}{18}{Notes}{section*.115}{}}
\newlabel{usbBrickIO:source.usbBrickIO.productID}{{1.7}{18}{Notes}{section*.116}{}}
\newlabel{usbBrickIO:source.usbBrickIO.nReadBuffer}{{1.7}{18}{Notes}{section*.117}{}}
\newlabel{usbBrickIO:source.usbBrickIO.nWriteBuffer}{{1.7}{18}{Notes}{section*.118}{}}
\newlabel{usbBrickIO:source.usbBrickIO.timeOut}{{1.7}{18}{Notes}{section*.119}{}}
\@writefile{toc}{\contentsline {paragraph}{Examples}{18}{paragraph*.120}}
\newlabel{usbBrickIO:source.usbBrickIO.close}{{1.7}{18}{Examples}{section*.121}{}}
\newlabel{usbBrickIO:source.usbBrickIO.open}{{1.7}{18}{Examples}{section*.122}{}}
\newlabel{usbBrickIO:source.usbBrickIO.read}{{1.7}{18}{Examples}{section*.123}{}}
\newlabel{usbBrickIO:source.usbBrickIO.setProperties}{{1.7}{18}{Examples}{section*.124}{}}
\newlabel{usbBrickIO:source.usbBrickIO.write}{{1.7}{19}{Examples}{section*.125}{}}
\newlabel{btBrickIO:module-source}{{1.7}{19}{usbBrickIO}{section*.126}{}}
\@writefile{toc}{\contentsline {section}{\numberline {1.8}btBrickIO}{19}{section.1.8}}
\newlabel{btBrickIO:btbrickio}{{1.8}{19}{btBrickIO}{section.1.8}{}}
\newlabel{btBrickIO::doc}{{1.8}{19}{btBrickIO}{section.1.8}{}}
\newlabel{btBrickIO:source.btBrickIO}{{1.8}{19}{btBrickIO}{section*.127}{}}
\@writefile{toc}{\contentsline {paragraph}{Notes}{19}{paragraph*.128}}
\newlabel{btBrickIO:source.btBrickIO.debug}{{1.8}{19}{Notes}{section*.129}{}}
\newlabel{btBrickIO:source.btBrickIO.serialPort}{{1.8}{19}{Notes}{section*.130}{}}
\newlabel{btBrickIO:source.btBrickIO.deviceName}{{1.8}{19}{Notes}{section*.131}{}}
\newlabel{btBrickIO:source.btBrickIO.channel}{{1.8}{19}{Notes}{section*.132}{}}
\newlabel{btBrickIO:source.btBrickIO.timeOut}{{1.8}{20}{Notes}{section*.133}{}}
\newlabel{btBrickIO:source.btBrickIO.backend}{{1.8}{20}{Notes}{section*.134}{}}
\@writefile{toc}{\contentsline {paragraph}{Examples}{20}{paragraph*.135}}
\newlabel{btBrickIO:source.btBrickIO.close}{{1.8}{20}{Examples}{section*.136}{}}
\newlabel{btBrickIO:source.btBrickIO.open}{{1.8}{20}{Examples}{section*.137}{}}
\newlabel{btBrickIO:source.btBrickIO.read}{{1.8}{20}{Examples}{section*.138}{}}
\newlabel{btBrickIO:source.btBrickIO.setProperties}{{1.8}{20}{Examples}{section*.139}{}}
\newlabel{btBrickIO:source.btBrickIO.write}{{1.8}{20}{Examples}{section*.140}{}}
\@writefile{toc}{\contentsline {chapter}{MATLAB Module Index}{21}{section*.141}}
\@writefile{toc}{\contentsline {chapter}{Index}{23}{section*.142}}
......@@ -11,45 +11,92 @@
\indexentry{debug (source.EV3 attribute)|hyperpage}{4}
\indexentry{batteryMode (source.EV3 attribute)|hyperpage}{4}
\indexentry{batteryValue (source.EV3 attribute)|hyperpage}{4}
\indexentry{isConnected (source.EV3 attribute)|hyperpage}{4}
\indexentry{beep() (source.EV3 method)|hyperpage}{4}
\indexentry{isConnected (source.EV3 attribute)|hyperpage}{5}
\indexentry{beep() (source.EV3 method)|hyperpage}{5}
\indexentry{connect() (source.EV3 method)|hyperpage}{5}
\indexentry{disconnect() (source.EV3 method)|hyperpage}{5}
\indexentry{playTone() (source.EV3 method)|hyperpage}{5}
\indexentry{playTone() (source.EV3 method)|hyperpage}{6}
\indexentry{setProperties() (source.EV3 method)|hyperpage}{6}
\indexentry{stopAllMotors() (source.EV3 method)|hyperpage}{6}
\indexentry{stopTone() (source.EV3 method)|hyperpage}{6}
\indexentry{tonePlayed() (source.EV3 method)|hyperpage}{6}
\indexentry{source (module)|hyperpage}{6}
\indexentry{Motor (class in source)|hyperpage}{6}
\indexentry{Motor (class in source)|hyperpage}{7}
\indexentry{power (source.Motor attribute)|hyperpage}{7}
\indexentry{speedRegulation (source.Motor attribute)|hyperpage}{7}
\indexentry{smoothStart (source.Motor attribute)|hyperpage}{7}
\indexentry{smoothStop (source.Motor attribute)|hyperpage}{7}
\indexentry{limitValue (source.Motor attribute)|hyperpage}{7}
\indexentry{limitMode (source.Motor attribute)|hyperpage}{7}
\indexentry{brakeMode (source.Motor attribute)|hyperpage}{7}
\indexentry{debug (source.Motor attribute)|hyperpage}{7}
\indexentry{isRunning (source.Motor attribute)|hyperpage}{7}
\indexentry{tachoCount (source.Motor attribute)|hyperpage}{7}
\indexentry{currentSpeed (source.Motor attribute)|hyperpage}{7}
\indexentry{type (source.Motor attribute)|hyperpage}{7}
\indexentry{limitValue (source.Motor attribute)|hyperpage}{8}
\indexentry{limitMode (source.Motor attribute)|hyperpage}{8}
\indexentry{brakeMode (source.Motor attribute)|hyperpage}{8}
\indexentry{debug (source.Motor attribute)|hyperpage}{8}
\indexentry{isRunning (source.Motor attribute)|hyperpage}{8}
\indexentry{tachoCount (source.Motor attribute)|hyperpage}{8}
\indexentry{currentSpeed (source.Motor attribute)|hyperpage}{8}
\indexentry{type (source.Motor attribute)|hyperpage}{8}
\indexentry{internalReset() (source.Motor method)|hyperpage}{8}
\indexentry{resetTachoCount() (source.Motor method)|hyperpage}{8}
\indexentry{setBrake() (source.Motor method)|hyperpage}{8}
\indexentry{setProperties() (source.Motor method)|hyperpage}{8}
\indexentry{setProperties() (source.Motor method)|hyperpage}{9}
\indexentry{start() (source.Motor method)|hyperpage}{9}
\indexentry{stop() (source.Motor method)|hyperpage}{9}
\indexentry{syncedStart() (source.Motor method)|hyperpage}{9}
\indexentry{syncedStop() (source.Motor method)|hyperpage}{9}
\indexentry{syncedStop() (source.Motor method)|hyperpage}{10}
\indexentry{waitFor() (source.Motor method)|hyperpage}{10}
\indexentry{source (module)|hyperpage}{10}
\indexentry{Sensor (class in source)|hyperpage}{10}
\indexentry{mode (source.Sensor attribute)|hyperpage}{10}
\indexentry{mode (source.Sensor attribute)|hyperpage}{11}
\indexentry{debug (source.Sensor attribute)|hyperpage}{12}
\indexentry{value (source.Sensor attribute)|hyperpage}{12}
\indexentry{type (source.Sensor attribute)|hyperpage}{12}
\indexentry{value (source.Sensor attribute)|hyperpage}{13}
\indexentry{type (source.Sensor attribute)|hyperpage}{13}
\indexentry{reset() (source.Sensor method)|hyperpage}{13}
\indexentry{setProperties() (source.Sensor method)|hyperpage}{13}
\indexentry{source (module)|hyperpage}{13}
\indexentry{source (module)|hyperpage}{13}
\indexentry{source (module)|hyperpage}{14}
\indexentry{hidapi (class in source)|hyperpage}{14}
\indexentry{handle (source.hidapi attribute)|hyperpage}{14}
\indexentry{vendorID (source.hidapi attribute)|hyperpage}{14}
\indexentry{productID (source.hidapi attribute)|hyperpage}{14}
\indexentry{nReadBuffer (source.hidapi attribute)|hyperpage}{14}
\indexentry{nWriteBuffer (source.hidapi attribute)|hyperpage}{15}
\indexentry{slib (source.hidapi attribute)|hyperpage}{15}
\indexentry{sheader (source.hidapi attribute)|hyperpage}{15}
\indexentry{close() (source.hidapi method)|hyperpage}{15}
\indexentry{enumerate() (source.hidapi method)|hyperpage}{15}
\indexentry{error() (source.hidapi method)|hyperpage}{15}
\indexentry{exit() (source.hidapi method)|hyperpage}{16}
\indexentry{getHIDInfoString() (source.hidapi method)|hyperpage}{16}
\indexentry{getManufacturersString() (source.hidapi method)|hyperpage}{16}
\indexentry{getProductString() (source.hidapi method)|hyperpage}{16}
\indexentry{getSerialNumberString() (source.hidapi method)|hyperpage}{16}
\indexentry{init() (source.hidapi method)|hyperpage}{16}
\indexentry{open() (source.hidapi method)|hyperpage}{16}
\indexentry{read() (source.hidapi method)|hyperpage}{17}
\indexentry{read\_timeout() (source.hidapi method)|hyperpage}{17}
\indexentry{setNonBlocking() (source.hidapi method)|hyperpage}{17}
\indexentry{write() (source.hidapi method)|hyperpage}{17}
\indexentry{source (module)|hyperpage}{17}
\indexentry{usbBrickIO (class in source)|hyperpage}{18}
\indexentry{debug (source.usbBrickIO attribute)|hyperpage}{18}
\indexentry{vendorID (source.usbBrickIO attribute)|hyperpage}{18}
\indexentry{productID (source.usbBrickIO attribute)|hyperpage}{18}
\indexentry{nReadBuffer (source.usbBrickIO attribute)|hyperpage}{18}
\indexentry{nWriteBuffer (source.usbBrickIO attribute)|hyperpage}{18}
\indexentry{timeOut (source.usbBrickIO attribute)|hyperpage}{18}
\indexentry{close() (source.usbBrickIO method)|hyperpage}{18}
\indexentry{open() (source.usbBrickIO method)|hyperpage}{18}
\indexentry{read() (source.usbBrickIO method)|hyperpage}{18}
\indexentry{setProperties() (source.usbBrickIO method)|hyperpage}{18}
\indexentry{write() (source.usbBrickIO method)|hyperpage}{19}
\indexentry{source (module)|hyperpage}{19}
\indexentry{btBrickIO (class in source)|hyperpage}{19}
\indexentry{debug (source.btBrickIO attribute)|hyperpage}{19}
\indexentry{serialPort (source.btBrickIO attribute)|hyperpage}{19}
\indexentry{deviceName (source.btBrickIO attribute)|hyperpage}{19}
\indexentry{channel (source.btBrickIO attribute)|hyperpage}{19}
\indexentry{timeOut (source.btBrickIO attribute)|hyperpage}{20}
\indexentry{backend (source.btBrickIO attribute)|hyperpage}{20}
\indexentry{close() (source.btBrickIO method)|hyperpage}{20}
\indexentry{open() (source.btBrickIO method)|hyperpage}{20}
\indexentry{read() (source.btBrickIO method)|hyperpage}{20}
\indexentry{setProperties() (source.btBrickIO method)|hyperpage}{20}
\indexentry{write() (source.btBrickIO method)|hyperpage}{20}
This is makeindex, version 2.15 [TeX Live 2013] (kpathsea + Thai support).
Scanning style file ./python.ist......done (6 attributes redefined, 0 ignored).
Scanning input file MindstormsEV3Toolbox.idx....done (55 entries accepted, 0 rejected).
Sorting entries....done (342 comparisons).
Generating output file MindstormsEV3Toolbox.ind....done (93 lines written, 0 warnings).
Scanning input file MindstormsEV3Toolbox.idx....done (102 entries accepted, 0 rejected).
Sorting entries....done (719 comparisons).
Generating output file MindstormsEV3Toolbox.ind....done (155 lines written, 0 warnings).
Output written in MindstormsEV3Toolbox.ind.
Transcript written in MindstormsEV3Toolbox.ilg.
......@@ -2,54 +2,98 @@
\def\bigletter#1{{\Large\sffamily#1}\nopagebreak\vspace{1mm}}
\bigletter B
\item backend (source.btBrickIO attribute), \hyperpage{20}
\item batteryMode (source.EV3 attribute), \hyperpage{4}
\item batteryValue (source.EV3 attribute), \hyperpage{4}
\item beep() (source.EV3 method), \hyperpage{4}
\item brakeMode (source.Motor attribute), \hyperpage{7}
\item beep() (source.EV3 method), \hyperpage{5}
\item brakeMode (source.Motor attribute), \hyperpage{8}
\item btBrickIO (class in source), \hyperpage{19}
\indexspace
\bigletter C
\item channel (source.btBrickIO attribute), \hyperpage{19}
\item close() (source.btBrickIO method), \hyperpage{20}
\item close() (source.hidapi method), \hyperpage{15}
\item close() (source.usbBrickIO method), \hyperpage{18}
\item connect() (source.EV3 method), \hyperpage{5}
\item currentSpeed (source.Motor attribute), \hyperpage{7}
\item currentSpeed (source.Motor attribute), \hyperpage{8}
\indexspace
\bigletter D
\item debug (source.btBrickIO attribute), \hyperpage{19}
\item debug (source.EV3 attribute), \hyperpage{4}
\item debug (source.Motor attribute), \hyperpage{7}
\item debug (source.Motor attribute), \hyperpage{8}
\item debug (source.Sensor attribute), \hyperpage{12}
\item debug (source.usbBrickIO attribute), \hyperpage{18}
\item deviceName (source.btBrickIO attribute), \hyperpage{19}
\item disconnect() (source.EV3 method), \hyperpage{5}
\indexspace
\bigletter E
\item enumerate() (source.hidapi method), \hyperpage{15}
\item error() (source.hidapi method), \hyperpage{15}
\item EV3 (class in source), \hyperpage{3}
\item exit() (source.hidapi method), \hyperpage{16}
\indexspace
\bigletter G
\item getHIDInfoString() (source.hidapi method), \hyperpage{16}
\item getManufacturersString() (source.hidapi method), \hyperpage{16}
\item getProductString() (source.hidapi method), \hyperpage{16}
\item getSerialNumberString() (source.hidapi method), \hyperpage{16}
\indexspace
\bigletter H
\item handle (source.hidapi attribute), \hyperpage{14}
\item hidapi (class in source), \hyperpage{14}
\indexspace
\bigletter I
\item init() (source.hidapi method), \hyperpage{16}
\item internalReset() (source.Motor method), \hyperpage{8}
\item isConnected (source.EV3 attribute), \hyperpage{4}
\item isRunning (source.Motor attribute), \hyperpage{7}
\item isConnected (source.EV3 attribute), \hyperpage{5}
\item isRunning (source.Motor attribute), \hyperpage{8}
\indexspace
\bigletter L
\item limitMode (source.Motor attribute), \hyperpage{7}
\item limitValue (source.Motor attribute), \hyperpage{7}
\item limitMode (source.Motor attribute), \hyperpage{8}
\item limitValue (source.Motor attribute), \hyperpage{8}
\indexspace
\bigletter M
\item mode (source.Sensor attribute), \hyperpage{10}
\item Motor (class in source), \hyperpage{6}
\item mode (source.Sensor attribute), \hyperpage{11}
\item Motor (class in source), \hyperpage{7}
\item motorA (source.EV3 attribute), \hyperpage{4}
\item motorB (source.EV3 attribute), \hyperpage{4}
\item motorC (source.EV3 attribute), \hyperpage{4}
\item motorD (source.EV3 attribute), \hyperpage{4}
\indexspace
\bigletter N
\item nReadBuffer (source.hidapi attribute), \hyperpage{14}
\item nReadBuffer (source.usbBrickIO attribute), \hyperpage{18}
\item nWriteBuffer (source.hidapi attribute), \hyperpage{15}
\item nWriteBuffer (source.usbBrickIO attribute), \hyperpage{18}
\indexspace
\bigletter O
\item open() (source.btBrickIO method), \hyperpage{20}
\item open() (source.hidapi method), \hyperpage{16}
\item open() (source.usbBrickIO method), \hyperpage{18}
\indexspace
\bigletter P
\item playTone() (source.EV3 method), \hyperpage{5}
\item playTone() (source.EV3 method), \hyperpage{6}
\item power (source.Motor attribute), \hyperpage{7}
\item productID (source.hidapi attribute), \hyperpage{14}
\item productID (source.usbBrickIO attribute), \hyperpage{18}
\indexspace
\bigletter R
\item read() (source.btBrickIO method), \hyperpage{20}
\item read() (source.hidapi method), \hyperpage{17}
\item read() (source.usbBrickIO method), \hyperpage{18}
\item read\_timeout() (source.hidapi method), \hyperpage{17}
\item reset() (source.Sensor method), \hyperpage{13}
\item resetTachoCount() (source.Motor method), \hyperpage{8}
......@@ -60,34 +104,52 @@
\item sensor2 (source.EV3 attribute), \hyperpage{4}
\item sensor3 (source.EV3 attribute), \hyperpage{4}
\item sensor4 (source.EV3 attribute), \hyperpage{4}
\item serialPort (source.btBrickIO attribute), \hyperpage{19}
\item setBrake() (source.Motor method), \hyperpage{8}
\item setNonBlocking() (source.hidapi method), \hyperpage{17}
\item setProperties() (source.btBrickIO method), \hyperpage{20}
\item setProperties() (source.EV3 method), \hyperpage{6}
\item setProperties() (source.Motor method), \hyperpage{8}
\item setProperties() (source.Motor method), \hyperpage{9}
\item setProperties() (source.Sensor method), \hyperpage{13}
\item setProperties() (source.usbBrickIO method), \hyperpage{18}
\item sheader (source.hidapi attribute), \hyperpage{15}
\item slib (source.hidapi attribute), \hyperpage{15}
\item smoothStart (source.Motor attribute), \hyperpage{7}
\item smoothStop (source.Motor attribute), \hyperpage{7}
\item source (module), \hyperpage{3}, \hyperpage{6}, \hyperpage{10}, \hyperpage{13}
\item source (module), \hyperpage{3}, \hyperpage{6}, \hyperpage{10}, \hyperpage{14},
\hyperpage{17}, \hyperpage{19}
\item speedRegulation (source.Motor attribute), \hyperpage{7}
\item start() (source.Motor method), \hyperpage{9}
\item stop() (source.Motor method), \hyperpage{9}
\item stopAllMotors() (source.EV3 method), \hyperpage{6}
\item stopTone() (source.EV3 method), \hyperpage{6}
\item syncedStart() (source.Motor method), \hyperpage{9}
\item syncedStop() (source.Motor method), \hyperpage{9}
\item syncedStop() (source.Motor method), \hyperpage{10}
\indexspace
\bigletter T
\item tachoCount (source.Motor attribute), \hyperpage{7}
\item tachoCount (source.Motor attribute), \hyperpage{8}
\item timeOut (source.btBrickIO attribute), \hyperpage{20}
\item timeOut (source.usbBrickIO attribute), \hyperpage{18}
\item tonePlayed() (source.EV3 method), \hyperpage{6}
\item type (source.Motor attribute), \hyperpage{7}
\item type (source.Sensor attribute), \hyperpage{12}
\item type (source.Motor attribute), \hyperpage{8}
\item type (source.Sensor attribute), \hyperpage{13}
\indexspace
\bigletter U
\item usbBrickIO (class in source), \hyperpage{18}
\indexspace
\bigletter V
\item value (source.Sensor attribute), \hyperpage{12}
\item value (source.Sensor attribute), \hyperpage{13}
\item vendorID (source.hidapi attribute), \hyperpage{14}
\item vendorID (source.usbBrickIO attribute), \hyperpage{18}
\indexspace
\bigletter W
\item waitFor() (source.Motor method), \hyperpage{10}
\item write() (source.btBrickIO method), \hyperpage{20}
\item write() (source.hidapi method), \hyperpage{17}
\item write() (source.usbBrickIO method), \hyperpage{19}
\end{theindex}
This is pdfTeX, Version 3.1415926-2.5-1.40.14 (TeX Live 2013/Debian) (format=pdflatex 2016.11.23) 23 FEB 2017 15:01
This is pdfTeX, Version 3.1415926-2.5-1.40.14 (TeX Live 2013/Debian) (format=pdflatex 2016.11.23) 9 MAY 2017 15:23
entering extended mode
restricted \write18 enabled.
%&-line parsing enabled.
......@@ -1019,7 +1019,9 @@ File: ts1pcr.fd 2001/06/04 font definitions for TS1/pcr.
)
LaTeX Font Info: Font shape `T1/pcr/bx/n' in size <10> not available
(Font) Font shape `T1/pcr/b/n' tried instead on input line 1.
LaTeX Font Info: Try loading font information for TS1+ptm on input line 208.
LaTeX Font Info: Font shape `T1/ptm/bx/it' in size <10> not available
(Font) Font shape `T1/ptm/b/it' tried instead on input line 201.
LaTeX Font Info: Try loading font information for TS1+ptm on input line 202.
(/usr/share/texlive/texmf-dist/tex/latex/psnfss/ts1ptm.fd
......@@ -1028,41 +1030,60 @@ File: ts1ptm.fd 2001/06/04 font definitions for TS1/ptm.
LaTeX Font Info: Font shape `T1/pcr/m/it' in size <10> not available
(Font) Font shape `T1/pcr/m/sl' tried instead on input line 1.
[4]
Underfull \hbox (badness 10000) in paragraph at lines 369--371
Underfull \hbox (badness 10000) in paragraph at lines 398--400
[]\T1/pcr/b/n/10 serPort \T1/ptm/m/n/10 (\T1/pcr/m/sl/10 string in {'/dev/rfcom
m1', '/dev/rfcomm2', ...}\T1/ptm/m/n/10 ) --
[]
[5]
Underfull \hbox (badness 10000) in paragraph at lines 450--451
Underfull \hbox (badness 10000) in paragraph at lines 479--480
[]\T1/pcr/b/n/10 batteryMode \T1/ptm/m/n/10 (\T1/pcr/m/sl/10 string in {'Voltag
e'/'Percentage'}\T1/ptm/m/n/10 ) -- see
[]
[6] [7] [8] [9] [10] [11] [12] (./MindstormsEV3Toolbox.ind [13] [14
[6] [7] [8] [9] [10] [11] [12] [13] [14] [15]
Underfull \hbox (badness 10000) in paragraph at lines 1591--1593
[]\T1/ptm/m/n/10 See also HI-DAPI.GETMANUFACTURERSSTRING, HI-DAPI.GETPRODUCTSTR
ING, HI-
[]
[16] [17] [18] [19]
Underfull \hbox (badness 5504) in paragraph at lines 2066--2068
[]\T1/ptm/m/n/10 See also BT-BRICKIO.DEBUG, BT-BRICKIO.SERIALPORT, BT-BRICKIO.D
EVICENAME, BT-
[]
[20] [21
] (./MindstormsEV3Toolbox.ind [22
] [23
] [15
] [24
])
Package atveryend Info: Empty hook `BeforeClearDocument' on input line 1293.
Package atveryend Info: Empty hook `AfterLastShipout' on input line 1293.
Package atveryend Info: Empty hook `BeforeClearDocument' on input line 2098.
Package atveryend Info: Empty hook `AfterLastShipout' on input line 2098.
(./MindstormsEV3Toolbox.aux)
Package atveryend Info: Executing hook `AtVeryEndDocument' on input line 1293.
Package atveryend Info: Executing hook `AtEndAfterFileList' on input line 1293.
Package atveryend Info: Executing hook `AtVeryEndDocument' on input line 2098.
Package atveryend Info: Executing hook `AtEndAfterFileList' on input line 2098.
Package rerunfilecheck Info: File `MindstormsEV3Toolbox.out' has not changed.
(rerunfilecheck) Checksum: 22BCF1B5A3444C4A0155F0F0F4B50E6D;826.
Package atveryend Info: Empty hook `AtVeryVeryEnd' on input line 1293.
(rerunfilecheck) Checksum: CA85C18231C8BE65A74CF3036572891B;1005.
Package atveryend Info: Empty hook `AtVeryVeryEnd' on input line 2098.
)
Here is how much of TeX's memory you used:
13469 strings out of 493304
183892 string characters out of 6139870
275845 words of memory out of 5000000
16501 multiletter control sequences out of 15000+600000
59422 words of font info for 78 fonts, out of 8000000 for 9000
13596 strings out of 493304
186205 string characters out of 6139870
277350 words of memory out of 5000000
16554 multiletter control sequences out of 15000+600000
62190 words of font info for 80 fonts, out of 8000000 for 9000
958 hyphenation exceptions out of 8191
36i,11n,45p,527b,667s stack positions out of 5000i,500n,10000p,200000b,80000s
36i,12n,45p,527b,673s stack positions out of 5000i,500n,10000p,200000b,80000s
{/usr/share/texlive/texmf-dist/fonts/enc/dvips/base/8r.enc}</usr/share/texliv
e/texmf-dist/fonts/type1/urw/courier/ucrb8a.pfb></usr/share/texlive/texmf-dist/
fonts/type1/urw/courier/ucrr8a.pfb></usr/share/texlive/texmf-dist/fonts/type1/u
......@@ -1070,12 +1091,13 @@ rw/courier/ucrro8a.pfb></usr/share/texlive/texmf-dist/fonts/type1/urw/helvetic/
uhvb8a.pfb></usr/share/texlive/texmf-dist/fonts/type1/urw/helvetic/uhvbo8a.pfb>
</usr/share/texlive/texmf-dist/fonts/type1/urw/helvetic/uhvr8a.pfb></usr/share/
texlive/texmf-dist/fonts/type1/urw/times/utmb8a.pfb></usr/share/texlive/texmf-d
ist/fonts/type1/urw/times/utmr8a.pfb></usr/share/texlive/texmf-dist/fonts/type1
/urw/times/utmri8a.pfb>
Output written on MindstormsEV3Toolbox.pdf (19 pages, 147194 bytes).
ist/fonts/type1/urw/times/utmbi8a.pfb></usr/share/texlive/texmf-dist/fonts/type
1/urw/times/utmr8a.pfb></usr/share/texlive/texmf-dist/fonts/type1/urw/times/utm
ri8a.pfb>
Output written on MindstormsEV3Toolbox.pdf (28 pages, 177469 bytes).
PDF statistics:
374 PDF objects out of 1000 (max. 8388607)
335 compressed objects within 4 object streams
115 named destinations out of 1000 (max. 500000)
93 words of extra memory for PDF output out of 10000 (max. 10000000)
584 PDF objects out of 1000 (max. 8388607)
533 compressed objects within 6 object streams
186 named destinations out of 1000 (max. 500000)
109 words of extra memory for PDF output out of 10000 (max. 10000000)
......@@ -4,6 +4,8 @@
\BOOKMARK [1][-]{section.1.3}{\376\377\000E\000V\0003}{chapter.1}% 4
\BOOKMARK [1][-]{section.1.4}{\376\377\000M\000o\000t\000o\000r}{chapter.1}% 5
\BOOKMARK [1][-]{section.1.5}{\376\377\000S\000e\000n\000s\000o\000r}{chapter.1}% 6
\BOOKMARK [1][-]{section.1.6}{\376\377\000C\000o\000m\000m\000a\000n\000d\000L\000a\000y\000e\000r}{chapter.1}% 7
\BOOKMARK [1][-]{section.1.7}{\376\377\000C\000o\000m\000m\000u\000n\000i\000c\000a\000t\000i\000o\000n\000L\000a\000y\000e\000r}{chapter.1}% 8
\BOOKMARK [0][-]{section*.80}{\376\377\000I\000n\000d\000e\000x}{}% 9
\BOOKMARK [1][-]{section.1.6}{\376\377\000h\000i\000d\000a\000p\000i}{chapter.1}% 7
\BOOKMARK [1][-]{section.1.7}{\376\377\000u\000s\000b\000B\000r\000i\000c\000k\000I\000O}{chapter.1}% 8
\BOOKMARK [1][-]{section.1.8}{\376\377\000b\000t\000B\000r\000i\000c\000k\000I\000O}{chapter.1}% 9
\BOOKMARK [0][-]{section*.141}{\376\377\000M\000A\000T\000L\000A\000B\000\040\000M\000o\000d\000u\000l\000e\000\040\000I\000n\000d\000e\000x}{}% 10
\BOOKMARK [0][-]{section*.142}{\376\377\000I\000n\000d\000e\000x}{}% 11
No preview for this file type
......@@ -32,7 +32,7 @@
\title{Mindstorms EV3 Toolbox Documentation}
\date{Feb 23, 2017}
\date{May 09, 2017}
\release{v0.4-rc.10}
\author{LfB - RWTH Aachen}
\newcommand{\sphinxlogo}{}
......@@ -146,8 +146,8 @@
This MATLAB toolbox was designed to abstract and simplify controlling Lego Mindstorms
EV3 robots. Via Bluetooth or USB you can read sensor values or control
your robots' motors in an intuitive way. On a low level (the {\hyperref[CommunicationLayer::doc]{\sphinxcrossref{\DUrole{doc}{Communication
layer}}}}) you are able to send various commands directly to the brick, while on a high level,
your robots' motors in an intuitive way. On a low level (the \DUrole{xref,doc}{Communication
layer}) you are able to send various commands directly to the brick, while on a high level,
several classes abstract this behaviour for you. If you want to easily access your EV3 robot,
these are the classes you will mostly use.
......@@ -197,7 +197,36 @@ Toolbox documentation
\label{EV3:ev3}\label{EV3::doc}\index{EV3 (class in source)}
\begin{fulllineitems}
\phantomsection\label{EV3:source.EV3}\pysiglinewithargsret{\sphinxstrong{class }\sphinxcode{source.}\sphinxbfcode{EV3}}{\emph{varargin}}{}
\phantomsection\label{EV3:source.EV3}\pysiglinewithargsret{\sphinxstrong{class }\sphinxcode{source.}\sphinxbfcode{EV3}}{\emph{varargin}}{}~\begin{description}
\item[{\emph{List of methods}:}] \leavevmode\begin{itemize}
\item {}
\sphinxcode{connect()}
\item {}
\sphinxcode{disconnect()}
\item {}
\sphinxcode{stopAllMotors()}
\item {}
\sphinxcode{beep()}
\item {}
\sphinxcode{playTone()}
\item {}
\sphinxcode{stopTone()}
\item {}
\sphinxcode{tonePlayed()}
\item {}
\sphinxcode{setProperties()}
\end{itemize}
\end{description}
High-level class to work with physical bricks.
This is the `central' class (from user's view) when working with this toolbox. It
......@@ -519,7 +548,39 @@ b.tonePlayed(); \% -\textgreater{} Outputs 1 to console.
\label{Motor::doc}\label{Motor:motor}\index{Motor (class in source)}
\begin{fulllineitems}
\phantomsection\label{Motor:source.Motor}\pysiglinewithargsret{\sphinxstrong{class }\sphinxcode{source.}\sphinxbfcode{Motor}}{\emph{varargin}}{}
\phantomsection\label{Motor:source.Motor}\pysiglinewithargsret{\sphinxstrong{class }\sphinxcode{source.}\sphinxbfcode{Motor}}{\emph{varargin}}{}~\begin{description}
\item[{\emph{List of methods}:}] \leavevmode\begin{itemize}
\item {}
{\hyperref[Motor:source.Motor.start]{\sphinxcrossref{\sphinxcode{start()}}}}
\item {}
{\hyperref[Motor:source.Motor.stop]{\sphinxcrossref{\sphinxcode{stop()}}}}
\item {}
{\hyperref[Motor:source.Motor.syncedStart]{\sphinxcrossref{\sphinxcode{syncedStart()}}}}
\item {}
{\hyperref[Motor:source.Motor.syncedStop]{\sphinxcrossref{\sphinxcode{syncedStop()}}}}
\item {}
{\hyperref[Motor:source.Motor.waitFor]{\sphinxcrossref{\sphinxcode{waitFor()}}}}
\item {}
{\hyperref[Motor:source.Motor.internalReset]{\sphinxcrossref{\sphinxcode{internalReset()}}}}
\item {}
{\hyperref[Motor:source.Motor.resetTachoCount]{\sphinxcrossref{\sphinxcode{resetTachoCount()}}}}
\item {}
{\hyperref[Motor:source.Motor.setBrake]{\sphinxcrossref{\sphinxcode{setBrake()}}}}
\item {}
{\hyperref[Motor:source.Motor.setProperties]{\sphinxcrossref{\sphinxcode{setProperties()}}}}
\end{itemize}
\end{description}
High-level class to work with motors.
This class is supposed to ease the use of the brick's motors. It is possible to set all
......@@ -901,7 +962,18 @@ connected as speed correctly returns 0 if it's not)
\label{Sensor:sensor}\label{Sensor::doc}\index{Sensor (class in source)}
\begin{fulllineitems}
\phantomsection\label{Sensor:source.Sensor}\pysiglinewithargsret{\sphinxstrong{class }\sphinxcode{source.}\sphinxbfcode{Sensor}}{\emph{varargin}}{}
\phantomsection\label{Sensor:source.Sensor}\pysiglinewithargsret{\sphinxstrong{class }\sphinxcode{source.}\sphinxbfcode{Sensor}}{\emph{varargin}}{}~\begin{description}
\item[{\emph{List of methods}:}] \leavevmode\begin{itemize}
\item {}
{\hyperref[Sensor:source.Sensor.reset]{\sphinxcrossref{\sphinxcode{reset()}}}}
\item {}
{\hyperref[Sensor:source.Sensor.setProperties]{\sphinxcrossref{\sphinxcode{setProperties()}}}}
\end{itemize}
\end{description}
High-level class to work with sensors.
The Sensor-class facilitates the communication with sensors. This mainly consists of
......@@ -1267,26 +1339,759 @@ b.sensor1.setProperties(`debug', `on', `mode', DeviceMode.Color.Ambient); \%
Advanced
\phantomsection\label{CommandLayer:module-source}\index{source (module)}
\phantomsection\label{hid:module-source}\index{source (module)}
\section{hidapi}
\label{hid:hidapi}\label{hid::doc}\index{hidapi (class in source)}
\begin{fulllineitems}
\phantomsection\label{hid:source.hidapi}\pysiglinewithargsret{\sphinxstrong{class }\sphinxcode{source.}\sphinxbfcode{hidapi}}{\emph{vendorID}, \emph{productID}, \emph{nReadBuffer}, \emph{nWriteBuffer}}{}~\begin{description}
\item[{\emph{List of methods}:}] \leavevmode\begin{itemize}
\item {}
{\hyperref[hid:source.hidapi.open]{\sphinxcrossref{\sphinxcode{open()}}}}
\item {}
{\hyperref[hid:source.hidapi.close]{\sphinxcrossref{\sphinxcode{close()}}}}
\item {}
{\hyperref[hid:source.hidapi.read]{\sphinxcrossref{\sphinxcode{read()}}}}
\item {}
{\hyperref[hid:source.hidapi.read_timeout]{\sphinxcrossref{\sphinxcode{read\_timeout()}}}}
\item {}
{\hyperref[hid:source.hidapi.write]{\sphinxcrossref{\sphinxcode{write()}}}}
\item {}
{\hyperref[hid:source.hidapi.getHIDInfoString]{\sphinxcrossref{\sphinxcode{getHIDInfoString()}}}}
\item {}
{\hyperref[hid:source.hidapi.setNonBlocking]{\sphinxcrossref{\sphinxcode{setNonBlocking()}}}}
\item {}
{\hyperref[hid:source.hidapi.init]{\sphinxcrossref{\sphinxcode{init()}}}}
\item {}
{\hyperref[hid:source.hidapi.exit]{\sphinxcrossref{\sphinxcode{exit()}}}}
\item {}
{\hyperref[hid:source.hidapi.error]{\sphinxcrossref{\sphinxcode{error()}}}}
\item {}
{\hyperref[hid:source.hidapi.enumerate]{\sphinxcrossref{\sphinxcode{enumerate()}}}}
\item {}
{\hyperref[hid:source.hidapi.getManufacturersString]{\sphinxcrossref{\sphinxcode{getManufacturersString()}}}}
\item {}
{\hyperref[hid:source.hidapi.getProductString]{\sphinxcrossref{\sphinxcode{getProductString()}}}}
\item {}
{\hyperref[hid:source.hidapi.getSerialNumberString]{\sphinxcrossref{\sphinxcode{getSerialNumberString()}}}}
\end{itemize}
\end{description}
Interface to the hidapi library
\paragraph{Notes}
\begin{itemize}
\item {}
Developed from the hidapi available at \url{http://www.signal11.us/oss/hidapi/}.
\item {}
Windows: hidapi.dll needed.
\item {}
Mac: hidapi.dylib needed. In addition, Xcode has to be installed.
\item {}
Linux: hidapi has to be compiled on host-system.
\end{itemize}
\index{handle (source.hidapi attribute)}
\begin{fulllineitems}
\phantomsection\label{hid:source.hidapi.handle}\pysigline{\sphinxbfcode{handle}}
\end{fulllineitems}
\index{vendorID (source.hidapi attribute)}
\begin{fulllineitems}
\phantomsection\label{hid:source.hidapi.vendorID}\pysigline{\sphinxbfcode{vendorID}}
\emph{numeric} -- Vendor-ID of the USB device.
\end{fulllineitems}
\index{productID (source.hidapi attribute)}
\begin{fulllineitems}
\phantomsection\label{hid:source.hidapi.productID}\pysigline{\sphinxbfcode{productID}}
\emph{numeric} -- Product-ID of the USB device.
\end{fulllineitems}
\index{nReadBuffer (source.hidapi attribute)}
\begin{fulllineitems}
\phantomsection\label{hid:source.hidapi.nReadBuffer}\pysigline{\sphinxbfcode{nReadBuffer}}
\emph{numeric} -- Read-buffer size in bytes.
\end{fulllineitems}
\index{nWriteBuffer (source.hidapi attribute)}
\begin{fulllineitems}
\phantomsection\label{hid:source.hidapi.nWriteBuffer}\pysigline{\sphinxbfcode{nWriteBuffer}}
\emph{numeric} -- Write-buffer size in bytes. Needs to be 1 Byte bigger than
actual packet.
\end{fulllineitems}
\index{slib (source.hidapi attribute)}
\begin{fulllineitems}
\phantomsection\label{hid:source.hidapi.slib}\pysigline{\sphinxbfcode{slib}}
\emph{string} -- Name of shared library file (without file extension). Defaults to
`hidapi'.
\end{fulllineitems}
\section{CommandLayer}
\label{CommandLayer:commandlayer}\label{CommandLayer::doc}
\index{sheader (source.hidapi attribute)}
\subsection{Command}
\label{CommandLayer:command}
\begin{fulllineitems}
\phantomsection\label{hid:source.hidapi.sheader}\pysigline{\sphinxbfcode{sheader}}
\emph{string} -- Name of shared library header. Defaults to `hidapi.h'.
\end{fulllineitems}
\paragraph{Example}
hidHandle = hidapi(1684,0005,1024,1025); \%\textbar{}br\textbar{}
\index{close() (source.hidapi method)}
\begin{fulllineitems}
\phantomsection\label{hid:source.hidapi.close}\pysiglinewithargsret{\sphinxbfcode{close}}{\emph{hid}}{}
Close the connection to a hid device.
\begin{description}
\item[{Throws:}] \leavevmode
InvalidHandle: Handle to USB-device not valid
\end{description}
\paragraph{Notes}
\begin{itemize}
\item {}
Gets called automatically when deleting the hidapi instance.
\end{itemize}
\begin{enumerate}
\setcounter{enumi}{2000}
\item {}
Check if pointer is (unexpectedly) already invalidated
\end{enumerate}
\end{fulllineitems}
\index{enumerate() (source.hidapi method)}
\begin{fulllineitems}
\phantomsection\label{hid:source.hidapi.enumerate}\pysiglinewithargsret{\sphinxbfcode{enumerate}}{\emph{hid}, \emph{vendorID}, \emph{productID}}{}
Enumerates the info about the hid device with the given vendorID and productID
and returns a string with the returned hid information.
\begin{quote}\begin{description}
\item[{Parameters}] \leavevmode\begin{itemize}
\item {}
\textbf{\texttt{vendorID}} (\emph{\texttt{numeric}}) -- Vendor-ID of the USB device in decimal.
\item {}
\textbf{\texttt{productID}} (\emph{\texttt{numeric}}) -- Product-ID of the USB device in decimal.
\end{itemize}
\end{description}\end{quote}
\paragraph{Notes}
\begin{itemize}
\item {}
Using a vendorID and productID of (0,0) will enumerate all connected hid
devices.
\item {}
MATLAB does not have the hid\_device\_infoPtr struct so some of the returned
information will need to be resized and cast into uint8 or chars.
\end{itemize}
Enumerate the hid devices
\end{fulllineitems}
\index{error() (source.hidapi method)}
\begin{fulllineitems}
\phantomsection\label{hid:source.hidapi.error}\pysiglinewithargsret{\sphinxbfcode{error}}{\emph{hid}}{}
Return the hid device error string if a function produced an error.
\begin{description}
\item[{Throws:}] \leavevmode
InvalidHandle: Handle to USB-device not valid
\end{description}
\paragraph{Notes}
\begin{itemize}
\item {}
This function must be called explicitly if you think an error was generated
from the hid device.
\end{itemize}
\begin{enumerate}
\setcounter{enumi}{2000}
\item {}
Check if pointer is (unexpectedly) already invalidated
\end{enumerate}
\end{fulllineitems}
\index{exit() (source.hidapi method)}
\begin{fulllineitems}
\phantomsection\label{hid:source.hidapi.exit}\pysiglinewithargsret{\sphinxbfcode{exit}}{\emph{hid}}{}
hidapi.exit Exit hidapi
hid.exit() exits the hidapi library.
\begin{description}
\item[{Throws:}] \leavevmode
CommError: Error during communication with device
\subsection{CommunicationInterface}
\label{CommandLayer:communicationinterface}\phantomsection\label{CommunicationLayer:module-source}\index{source (module)}
\end{description}
Notes::
- You should not have to call this function directly.
\end{fulllineitems}
\index{getHIDInfoString() (source.hidapi method)}
\begin{fulllineitems}
\phantomsection\label{hid:source.hidapi.getHIDInfoString}\pysiglinewithargsret{\sphinxbfcode{getHIDInfoString}}{\emph{hid}, \emph{info}}{}
Get the corresponding hid info from the hid device.
\begin{description}
\item[{Throws:}] \leavevmode
CommError: Error during communication with device
InvalidHandle: Handle to USB-device not valid
\end{description}
\paragraph{Notes}
\begin{itemize}
\item {}
Info is the hid information string.
\end{itemize}
See also HIDAPI.GETMANUFACTURERSSTRING, HIDAPI.GETPRODUCTSTRING,
HIDAPI.GETSERIALNUMBERSTRING.
Read buffer nReadBuffer length
\end{fulllineitems}
\index{getManufacturersString() (source.hidapi method)}
\begin{fulllineitems}
\phantomsection\label{hid:source.hidapi.getManufacturersString}\pysiglinewithargsret{\sphinxbfcode{getManufacturersString}}{\emph{hid}}{}
Get manufacturers string from hid object using getHIDInfoString.
\end{fulllineitems}
\index{getProductString() (source.hidapi method)}
\begin{fulllineitems}
\phantomsection\label{hid:source.hidapi.getProductString}\pysiglinewithargsret{\sphinxbfcode{getProductString}}{\emph{hid}}{}
Get product string from hid object using getProductString.
\end{fulllineitems}
\index{getSerialNumberString() (source.hidapi method)}
\begin{fulllineitems}
\phantomsection\label{hid:source.hidapi.getSerialNumberString}\pysiglinewithargsret{\sphinxbfcode{getSerialNumberString}}{\emph{hid}}{}
Get serial number from hid object using getSerialNumberString.
\end{fulllineitems}
\index{init() (source.hidapi method)}
\begin{fulllineitems}
\phantomsection\label{hid:source.hidapi.init}\pysiglinewithargsret{\sphinxbfcode{init}}{\emph{hid}}{}
Inits the hidapi library.
\begin{description}
\item[{Throws:}] \leavevmode
CommError: Error during communication with device
\end{description}
\paragraph{Notes}
\begin{itemize}
\item {}
This is called automatically in the library itself with the open function. You
should not have to call this function directly.
\end{itemize}
\end{fulllineitems}
\index{open() (source.hidapi method)}
\begin{fulllineitems}
\phantomsection\label{hid:source.hidapi.open}\pysiglinewithargsret{\sphinxbfcode{open}}{\emph{hid}}{}
Open a connection with a hid device
\begin{description}
\item[{Throws:}] \leavevmode
CommError: Error during communication with device
\end{description}
\paragraph{Notes}
\begin{itemize}
\item {}
Gets called automatically when creating an hidapi-object.
\item {}
The pointer return value from this library call is always null so it is not
possible to know if the open was successful.
\item {}
The final parameter to the open hidapi library call has different types
depending on OS. On windows it is uint16, on linux/mac int32.
\end{itemize}
\section{CommunicationLayer}
\label{CommunicationLayer:communicationlayer}\label{CommunicationLayer::doc}
Create a null pointer for the hid\_open function (depends on OS)
\end{fulllineitems}
\index{read() (source.hidapi method)}
\begin{fulllineitems}
\phantomsection\label{hid:source.hidapi.read}\pysiglinewithargsret{\sphinxbfcode{read}}{\emph{hid}}{}
Read from a hid device and returns the read bytes.
\begin{description}
\item[{Throws:}] \leavevmode
CommError: Error during communication with device
InvalidHandle: Handle to USB-device not valid
\end{description}
\paragraph{Notes}
\begin{itemize}
\item {}
Will print an error if no data was read.
\end{itemize}
Read buffer of nReadBuffer length
\end{fulllineitems}
\index{read\_timeout() (source.hidapi method)}
\begin{fulllineitems}
\phantomsection\label{hid:source.hidapi.read_timeout}\pysiglinewithargsret{\sphinxbfcode{read\_timeout}}{\emph{hid}, \emph{timeOut}}{}
Read from a hid device with a timeout and return the read bytes.
\begin{quote}\begin{description}
\item[{Parameters}] \leavevmode
\textbf{\texttt{timeOut}} (\emph{\texttt{numeric \textgreater{}= 0}}) -- Milliseconds after which a timeout-error occurs if no
packet could be read.
\end{description}\end{quote}
\begin{description}
\item[{Throws:}] \leavevmode
CommError: Error during communication with device
InvalidHandle: Handle to USB-device not valid
\end{description}
Read buffer of nReadBuffer length
\end{fulllineitems}
\index{setNonBlocking() (source.hidapi method)}
\begin{fulllineitems}
\phantomsection\label{hid:source.hidapi.setNonBlocking}\pysiglinewithargsret{\sphinxbfcode{setNonBlocking}}{\emph{hid}, \emph{nonblock}}{}
Set the non blocking flag on the hid device connection.
\begin{quote}\begin{description}
\item[{Parameters}] \leavevmode
\textbf{\texttt{nonblock}} (\emph{\texttt{numeric in \{0,1\}}}) -- 0 disables nonblocking, 1 enables nonblocking
\end{description}\end{quote}
\begin{description}
\item[{Throws:}] \leavevmode
CommError: Error during communication with device
InvalidHandle: Handle to USB-device not valid
\end{description}
\begin{enumerate}
\setcounter{enumi}{2000}
\item {}
Check if pointer is (unexpectedly) already invalidated
\end{enumerate}
\end{fulllineitems}
\index{write() (source.hidapi method)}
\begin{fulllineitems}
\phantomsection\label{hid:source.hidapi.write}\pysiglinewithargsret{\sphinxbfcode{write}}{\emph{hid}, \emph{wmsg}, \emph{reportID}}{}
Write to a hid device.
\begin{description}
\item[{Throws:}] \leavevmode
CommError: Error during communication with device
InvalidHandle: Handle to USB-device not valid
\end{description}
\paragraph{Notes}
\begin{itemize}
\item {}
Will print an error if there is a mismatch between the buffer size and the
reported number of bytes written.
\end{itemize}
Append a 0 at the front for HID report ID
\end{fulllineitems}
\end{fulllineitems}
\phantomsection\label{usbBrickIO:module-source}\index{source (module)}
\section{usbBrickIO}
\label{usbBrickIO:usbbrickio}\label{usbBrickIO::doc}\index{usbBrickIO (class in source)}
\begin{fulllineitems}
\phantomsection\label{usbBrickIO:source.usbBrickIO}\pysiglinewithargsret{\sphinxstrong{class }\sphinxcode{source.}\sphinxbfcode{usbBrickIO}}{\emph{varargin}}{}~\begin{description}
\item[{\emph{List of methods}:}] \leavevmode\begin{itemize}
\item {}
{\hyperref[usbBrickIO:source.usbBrickIO.open]{\sphinxcrossref{\sphinxcode{open()}}}}
\item {}
{\hyperref[usbBrickIO:source.usbBrickIO.close]{\sphinxcrossref{\sphinxcode{close()}}}}
\item {}
{\hyperref[usbBrickIO:source.usbBrickIO.read]{\sphinxcrossref{\sphinxcode{read()}}}}
\item {}
{\hyperref[usbBrickIO:source.usbBrickIO.write]{\sphinxcrossref{\sphinxcode{write()}}}}
\item {}
{\hyperref[usbBrickIO:source.usbBrickIO.setProperties]{\sphinxcrossref{\sphinxcode{setProperties()}}}}
\end{itemize}
\end{description}
USB interface between MATLAB and the brick
\paragraph{Notes}
\begin{itemize}
\item {}
Uses the hid library implementation in hidapi.m
\item {}
The default parameters should always work when you try to connect to an EV3 brick,
so in nearly all use-cases, the constructor does not need any parameters (besides
`debug' eventually).
\end{itemize}
\index{debug (source.usbBrickIO attribute)}
\begin{fulllineitems}
\phantomsection\label{usbBrickIO:source.usbBrickIO.debug}\pysigline{\sphinxbfcode{debug}}
\emph{bool} -- If true, each open/close/read/write-call will be noted in the console.
Defaults to false.
\end{fulllineitems}
\index{vendorID (source.usbBrickIO attribute)}
\begin{fulllineitems}
\phantomsection\label{usbBrickIO:source.usbBrickIO.vendorID}\pysigline{\sphinxbfcode{vendorID}}
\emph{numeric} -- Vendor-ID of the USB device. Defaults to 0x694 (EV3 vendor ID).
\end{fulllineitems}
\index{productID (source.usbBrickIO attribute)}
\begin{fulllineitems}
\phantomsection\label{usbBrickIO:source.usbBrickIO.productID}\pysigline{\sphinxbfcode{productID}}
\emph{numeric} -- Product-ID of the USB device. Defaults to 0x0005 (EV3 product ID).
\end{fulllineitems}
\index{nReadBuffer (source.usbBrickIO attribute)}
\begin{fulllineitems}
\phantomsection\label{usbBrickIO:source.usbBrickIO.nReadBuffer}\pysigline{\sphinxbfcode{nReadBuffer}}
\emph{numeric} -- Read-buffer size in bytes. Defaults to 1024.
\end{fulllineitems}
\index{nWriteBuffer (source.usbBrickIO attribute)}
\begin{fulllineitems}
\phantomsection\label{usbBrickIO:source.usbBrickIO.nWriteBuffer}\pysigline{\sphinxbfcode{nWriteBuffer}}
\emph{numeric} -- Write-buffer size in bytes. Needs to be 1 Byte bigger than
actual packet. Defaults to 1025 (EV3 USB maximum packet size = 1024).
\end{fulllineitems}
\index{timeOut (source.usbBrickIO attribute)}
\begin{fulllineitems}
\phantomsection\label{usbBrickIO:source.usbBrickIO.timeOut}\pysigline{\sphinxbfcode{timeOut}}
\emph{numeric \textgreater{}= 0} -- Milliseconds after which a timeout-error occurs if no packet could be
read. Defaults to 10000.
\end{fulllineitems}
\paragraph{Examples}
\% Connecting via USB
commHandle = usbBrickIO(); \%
\% Connecting via USB with enabled debug output
commHandle = usbBrickIO(`debug', true); \%
\index{close() (source.usbBrickIO method)}
\begin{fulllineitems}
\phantomsection\label{usbBrickIO:source.usbBrickIO.close}\pysiglinewithargsret{\sphinxbfcode{close}}{\emph{brickIO}}{}
Closes the usb connection the brick through the hidapi interface.
\end{fulllineitems}
\index{open() (source.usbBrickIO method)}
\begin{fulllineitems}
\phantomsection\label{usbBrickIO:source.usbBrickIO.open}\pysiglinewithargsret{\sphinxbfcode{open}}{\emph{brickIO}}{}
Opens the usb connection to the brick through the hidapi interface.
\end{fulllineitems}
\index{read() (source.usbBrickIO method)}
\begin{fulllineitems}
\phantomsection\label{usbBrickIO:source.usbBrickIO.read}\pysiglinewithargsret{\sphinxbfcode{read}}{\emph{brickIO}}{}
Reads data from the brick through usb using the hidapi interface and returns the data in uint8 format.
\end{fulllineitems}
\index{setProperties() (source.usbBrickIO method)}
\begin{fulllineitems}
\phantomsection\label{usbBrickIO:source.usbBrickIO.setProperties}\pysiglinewithargsret{\sphinxbfcode{setProperties}}{\emph{brickIO}, \emph{varargin}}{}
Sets multiple usbBrickIO properties at once using MATLAB's inputParser.
The syntax is as follows: commHandle.setProperties(`propertyName1',
propertyValue1, `propertyName2', propertyValue2, ...). Valid, optional properties
are: debug, vendorID, productID, nReadBuffer, nWriteBuffer, timeOut.
See also USBBRICKIO.DEBUG, USBBRICKIO.VENDORID, USBBRICKIO.PRODUCTID,
USBBRICKIO.NREADBUFFER, USBBRICKIO.NWRITEBUFFER, USBBRICKIO.TIMEOUT
\end{fulllineitems}
\index{write() (source.usbBrickIO method)}
\begin{fulllineitems}
\phantomsection\label{usbBrickIO:source.usbBrickIO.write}\pysiglinewithargsret{\sphinxbfcode{write}}{\emph{brickIO}, \emph{wmsg}}{}
Writes data to the brick through usb using the hidapi interface.
\begin{quote}\begin{description}
\item[{Parameters}] \leavevmode
\textbf{\texttt{wmsg}} (\emph{\texttt{uint8 array}}) -- Data to be written to the brick via usb
\end{description}\end{quote}
\end{fulllineitems}
\end{fulllineitems}
\phantomsection\label{btBrickIO:module-source}\index{source (module)}
\section{btBrickIO}
\label{btBrickIO:btbrickio}\label{btBrickIO::doc}\index{btBrickIO (class in source)}
\begin{fulllineitems}
\phantomsection\label{btBrickIO:source.btBrickIO}\pysiglinewithargsret{\sphinxstrong{class }\sphinxcode{source.}\sphinxbfcode{btBrickIO}}{\emph{varargin}}{}~\begin{description}
\item[{\emph{List of methods}:}] \leavevmode\begin{itemize}
\item {}
{\hyperref[btBrickIO:source.btBrickIO.open]{\sphinxcrossref{\sphinxcode{open()}}}}
\item {}
{\hyperref[btBrickIO:source.btBrickIO.close]{\sphinxcrossref{\sphinxcode{close()}}}}
\item {}
{\hyperref[btBrickIO:source.btBrickIO.read]{\sphinxcrossref{\sphinxcode{read()}}}}
\item {}
{\hyperref[btBrickIO:source.btBrickIO.write]{\sphinxcrossref{\sphinxcode{write()}}}}
\item {}
{\hyperref[btBrickIO:source.btBrickIO.setProperties]{\sphinxcrossref{\sphinxcode{setProperties()}}}}
\end{itemize}
\end{description}
Bluetooth interface between MATLAB and the brick
\paragraph{Notes}
\begin{itemize}
\item {}
Connects to the bluetooth module on the host through a serial
connection. Hence be sure that a serial connection to the bluetooth
module can be made. Also be sure that the bluetooth module has been paired
to the brick before trying to connect.
\item {} \begin{description}
\item[{Usage is OS-dependent:}] \leavevmode\begin{itemize}
\item {}
Windows: the deviceName- \& channel-properties are needed for connection. The implementation is based on the Instrument Control toolbox.
\item {}
Linux (and potentially Mac): serialPort-property is needed for connection. The implementation is based on MATLAB's serial port implementation.
\end{itemize}
\end{description}
\item {}
For general information, see also \sphinxcode{BrickIO}.
\end{itemize}
\index{debug (source.btBrickIO attribute)}
\begin{fulllineitems}
\phantomsection\label{btBrickIO:source.btBrickIO.debug}\pysigline{\sphinxbfcode{debug}}
\emph{bool} -- If true, each open/close/read/write-call will be shown in the console.
Defaults to false.
\end{fulllineitems}
\index{serialPort (source.btBrickIO attribute)}
\begin{fulllineitems}
\phantomsection\label{btBrickIO:source.btBrickIO.serialPort}\pysigline{\sphinxbfcode{serialPort}}
\emph{string} -- Path to the serial-port object. Only needed when using MATLAB's
serial class (i.e. on linux/mac). Defaults to `/dev/rfcomm0'.
\end{fulllineitems}
\index{deviceName (source.btBrickIO attribute)}
\begin{fulllineitems}
\phantomsection\label{btBrickIO:source.btBrickIO.deviceName}\pysigline{\sphinxbfcode{deviceName}}
\emph{string} -- Name of the BT-device = the brick. Only needed when using the
Instrument Control toolbox (i.e. on windows). Defaults to `EV3'.
\end{fulllineitems}
\index{channel (source.btBrickIO attribute)}
\begin{fulllineitems}
\phantomsection\label{btBrickIO:source.btBrickIO.channel}\pysigline{\sphinxbfcode{channel}}
\emph{numeric \textgreater{} 0} -- BT-channel of the connected BT-device. Only needed when using
the Instrument Control toolbox (i.e. on windows). Defaults to 1.
\end{fulllineitems}
\index{timeOut (source.btBrickIO attribute)}
\begin{fulllineitems}
\phantomsection\label{btBrickIO:source.btBrickIO.timeOut}\pysigline{\sphinxbfcode{timeOut}}
\emph{numeric \textgreater{}= 0} -- seconds after which a timeout-error occurs if no packet could be
read. Defaults to 10.
\end{fulllineitems}
\index{backend (source.btBrickIO attribute)}
\begin{fulllineitems}
\phantomsection\label{btBrickIO:source.btBrickIO.backend}\pysigline{\sphinxbfcode{backend}}
\emph{`serial'\textbar{}'instrumentControl'} -- Backend this implementation is based on. Is
automatically chosen depending on the OS. Defaults to `serial' on linux/mac
systems, and to `instrumentControl' on windows systems.
\end{fulllineitems}
\paragraph{Examples}
\% Connecting on windows
commHandle = btBrickIO(`deviceName', `MyEV3', `channel', 1); \%
\% Connecting on windows using MATLABs default serial port implementation for testing
commHandle = btBrickIO(`deviceName', `MyEV3', `channel', 1, `backend', `serial'); \%
\% Connecting on mac/linux
commHandle = btBrickIO(`serPort', `/dev/rfcomm0'); \%
\index{close() (source.btBrickIO method)}
\begin{fulllineitems}
\phantomsection\label{btBrickIO:source.btBrickIO.close}\pysiglinewithargsret{\sphinxbfcode{close}}{\emph{brickIO}}{}
Closes the bluetooth connection the brick using fclose.
\end{fulllineitems}
\index{open() (source.btBrickIO method)}
\begin{fulllineitems}
\phantomsection\label{btBrickIO:source.btBrickIO.open}\pysiglinewithargsret{\sphinxbfcode{open}}{\emph{brickIO}}{}
Opens the bluetooth connection to the brick using fopen.
\end{fulllineitems}
\index{read() (source.btBrickIO method)}
\begin{fulllineitems}
\phantomsection\label{btBrickIO:source.btBrickIO.read}\pysiglinewithargsret{\sphinxbfcode{read}}{\emph{brickIO}}{}
Reads data from the brick through bluetooth via fread and returns the data in uint8 format.
\end{fulllineitems}
\index{setProperties() (source.btBrickIO method)}
\begin{fulllineitems}
\phantomsection\label{btBrickIO:source.btBrickIO.setProperties}\pysiglinewithargsret{\sphinxbfcode{setProperties}}{\emph{brickIO}, \emph{varargin}}{}
Sets multiple btBrickIO properties at once using MATLAB's inputParser.
The syntax is as follows: commHandle.setProperties(`propertyName1',
propertyValue1, `propertyName2', propertyValue2, ...). Valid, optional properties
are: debug, serPort, deviceName, channel, timeout.
See also BTBRICKIO.DEBUG, BTBRICKIO.SERIALPORT, BTBRICKIO.DEVICENAME,
BTBRICKIO.CHANNEL, BTBRICKIO.TIMEOUT
\end{fulllineitems}
\index{write() (source.btBrickIO method)}
\begin{fulllineitems}
\phantomsection\label{btBrickIO:source.btBrickIO.write}\pysiglinewithargsret{\sphinxbfcode{write}}{\emph{brickIO}, \emph{wmsg}}{}
Writes data to the brick through bluetooth via fwrite.
\begin{quote}\begin{description}
\item[{Parameters}] \leavevmode
\textbf{\texttt{wmsg}} (\emph{\texttt{uint8 array}}) -- Data to be written to the brick via bluetooth
\end{description}\end{quote}
\end{fulllineitems}
\end{fulllineitems}
\subsection{USB}
\label{CommunicationLayer:usb}
\subsection{Bluetooth}
\label{CommunicationLayer:bluetooth}
\renewcommand{\indexname}{MATLAB Module Index}
\begin{theindex}
\def\bigletter#1{{\Large\sffamily#1}\nopagebreak\vspace{1mm}}
\bigletter{s}
\item {\texttt{source}}, \pageref{usbBrickIO:module-source}
\end{theindex}
\renewcommand{\indexname}{Index}
\printindex
......
......@@ -7,33 +7,45 @@
\contentsline {section}{\numberline {1.2}Examples}{3}{section.1.2}
\contentsline {section}{\numberline {1.3}EV3}{3}{section.1.3}
\contentsline {paragraph}{Notes}{4}{paragraph*.5}
\contentsline {paragraph}{Example}{4}{paragraph*.18}
\contentsline {paragraph}{Example}{5}{paragraph*.18}
\contentsline {paragraph}{Notes}{5}{paragraph*.20}
\contentsline {paragraph}{Example}{5}{paragraph*.21}
\contentsline {paragraph}{Example}{5}{paragraph*.23}
\contentsline {paragraph}{Notes}{5}{paragraph*.25}
\contentsline {paragraph}{Example}{5}{paragraph*.26}
\contentsline {paragraph}{Example}{6}{paragraph*.26}
\contentsline {paragraph}{Example}{6}{paragraph*.28}
\contentsline {paragraph}{Example}{6}{paragraph*.30}
\contentsline {paragraph}{Example}{6}{paragraph*.33}
\contentsline {section}{\numberline {1.4}Motor}{6}{section.1.4}
\contentsline {section}{\numberline {1.4}Motor}{7}{section.1.4}
\contentsline {paragraph}{Notes}{7}{paragraph*.37}
\contentsline {paragraph}{Notes}{8}{paragraph*.51}
\contentsline {paragraph}{Notes}{8}{paragraph*.54}
\contentsline {paragraph}{Notes}{9}{paragraph*.54}
\contentsline {paragraph}{Example}{9}{paragraph*.56}
\contentsline {paragraph}{Notes}{9}{paragraph*.59}
\contentsline {paragraph}{Notes}{9}{paragraph*.61}
\contentsline {paragraph}{Example}{9}{paragraph*.62}
\contentsline {paragraph}{Notes}{10}{paragraph*.61}
\contentsline {paragraph}{Example}{10}{paragraph*.62}
\contentsline {paragraph}{Notes}{10}{paragraph*.64}
\contentsline {paragraph}{Notes}{10}{paragraph*.66}
\contentsline {section}{\numberline {1.5}Sensor}{10}{section.1.5}
\contentsline {paragraph}{Notes}{10}{paragraph*.69}
\contentsline {paragraph}{Notes}{11}{paragraph*.69}
\contentsline {paragraph}{Notes}{13}{paragraph*.75}
\contentsline {paragraph}{Example}{13}{paragraph*.77}
\contentsline {section}{\numberline {1.6}CommandLayer}{13}{section.1.6}
\contentsline {subsection}{\numberline {1.6.1}Command}{13}{subsection.1.6.1}
\contentsline {subsection}{\numberline {1.6.2}CommunicationInterface}{13}{subsection.1.6.2}
\contentsline {section}{\numberline {1.7}CommunicationLayer}{13}{section.1.7}
\contentsline {subsection}{\numberline {1.7.1}USB}{13}{subsection.1.7.1}
\contentsline {subsection}{\numberline {1.7.2}Bluetooth}{13}{subsection.1.7.2}
\contentsline {chapter}{Index}{15}{section*.80}
\contentsline {paragraph}{Example}{14}{paragraph*.77}
\contentsline {section}{\numberline {1.6}hidapi}{14}{section.1.6}
\contentsline {paragraph}{Notes}{14}{paragraph*.80}
\contentsline {paragraph}{Example}{15}{paragraph*.88}
\contentsline {paragraph}{Notes}{15}{paragraph*.90}
\contentsline {paragraph}{Notes}{15}{paragraph*.92}
\contentsline {paragraph}{Notes}{15}{paragraph*.94}
\contentsline {paragraph}{Notes}{16}{paragraph*.97}
\contentsline {paragraph}{Notes}{16}{paragraph*.102}
\contentsline {paragraph}{Notes}{16}{paragraph*.104}
\contentsline {paragraph}{Notes}{17}{paragraph*.106}
\contentsline {paragraph}{Notes}{17}{paragraph*.110}
\contentsline {section}{\numberline {1.7}usbBrickIO}{18}{section.1.7}
\contentsline {paragraph}{Notes}{18}{paragraph*.113}
\contentsline {paragraph}{Examples}{18}{paragraph*.120}
\contentsline {section}{\numberline {1.8}btBrickIO}{19}{section.1.8}
\contentsline {paragraph}{Notes}{19}{paragraph*.128}
\contentsline {paragraph}{Examples}{20}{paragraph*.135}
\contentsline {chapter}{MATLAB Module Index}{21}{section*.141}
\contentsline {chapter}{Index}{23}{section*.142}
......@@ -6,42 +6,52 @@ from tempfile import mkstemp
from shutil import move
TMP_FILE_STR = '%TEMP-FILE FOR BUILDING DOCUMENTATION'
DOCUMENTED_CLASSES = ['Motor', 'Sensor', 'EV3', 'usbBrickIO', 'btBrickIO'] # If a new class shall be documented, it needs to be added to this list
def preprocess():
"""Preprocesses data for building documentation
Prerequisites: Has to be inside toolboxFile/docs.
TODO: Fixes the following bugs: ...
The MATLAB Sphinx extension takes veeery (or even infinitely?) long
to build the documentation if a class contains an enumeration.
Fixes the following problems:
- Comment out enumerations (The MATLAB Sphinx
extension takes veeery (or even infinitely?) long to build the
documentation if a class contains an enumeration)
- Insert comments for creating a list of methods a class contains (Names of
relevant methods taken from corresponding .rst-file. This is necessary
as the MATLAB Sphinx Extension has no functionality for creating compact
method lists.:( )
-> After creating the documentation, the changes are unmade (postprocess())
Prerequisites:
- Has to be inside toolboxFile/docs
- comments in the MATLAB source files shouldn't include the keywords
'classdef' and 'enumeration'
"""
code_dir = os.path.abspath('../source')
files = _matlab_files(os.listdir(code_dir))
files = _matlab_files(os.listdir(code_dir)) # Get list of all toolbox source files
documented_methods = _find_documented_methods()
documented_methods = _find_documented_methods() # Get names of all documented methods from .rst-files
n_files = len(files)
for n, file_name in enumerate(files):
# print("Preprocessing file {0} [{1}|{2}]".format(file_name, n+1, n_files))
try:
fh, abs_path = mkstemp()
with open(code_dir + "/" + file_name, 'r') as f:
with open(abs_path, 'w') as ftemp:
content = f.readlines()
if content[0] == '%TEMP-FILE FOR BUILDING DOCUMENTATION\n':
if content[0] == TMP_FILE_STR + '\n':
raise RuntimeError('Found already preprocessed file: ' + file_name)
try:
for i, line in enumerate(content): # Worst runtime ever
for i, line in enumerate(content): # Worst runtime ever: Iterate over entire file line by line
if _ignore_line(line) is False:
if 'classdef' in line:
if 'classdef' in line: # Insert method-list string in relevant class docs
class_name = line.replace(' ', '').split('%')[0].split('<')[0].split('classdef')[1]
try:
methods = documented_methods[class_name]
line = line.replace('\n', '') + ' %TEMP-FILE FOR BUILDING DOCUMENTATION\n'
line = line.replace('\n', '') + ' ' + TMP_FILE_STR + '\n'
_write_lines(content[:i], ftemp)
_write_lines([line], ftemp)
......@@ -57,8 +67,8 @@ def preprocess():
move(abs_path, code_dir + "/" + file_name)
raise StopIteration
elif 'enumeration' in line:
ftemp.write('%TEMP-FILE FOR BUILDING DOCUMENTATION\n')
elif 'enumeration' in line: # Comment out enumeration
ftemp.write(TMP_FILE_STR + '\n')
_write_lines(content[:i], ftemp)
for j, enum_line in enumerate(content[i:]):
ftemp.write(" %"+enum_line)
......@@ -67,15 +77,19 @@ def preprocess():
close(fh)
remove(code_dir + "/" + file_name)
move(abs_path, code_dir + "/" + file_name)
# At this point, entire file has been processed: continue outer loop
# Hackily implemented by raising an exception
raise StopIteration
except StopIteration:
except StopIteration: # This exception is like a 'continue' for the outer loop when inside an inner loop
continue
except IOError:
pass
def postprocess():
"""Postprocesses data after building documentation
This function reverses the changes done by preprocess() and calls
postprocess_html_files afterwards.
"""
code_dir = os.path.abspath('../source')
files = _matlab_files(os.listdir(code_dir))
......@@ -83,30 +97,25 @@ def postprocess():
n_files = len(files)
for n, file_name in enumerate(files):
# print("Postprocessing file {0} [{1}|{2}]".format(file_name, n+1, n_files))
try:
fh, abs_path = mkstemp()
with open(code_dir + "/" + file_name, 'r') as f:
with open(abs_path, 'w') as ftemp:
content = f.readlines()
#if content[0] != '%TEMP-FILE FOR BUILDING DOCUMENTATION\n':
# continue
try:
for i, line in enumerate(content): # Worst runtime ever
if 'classdef' in line and '%TEMP-FILE FOR BUILDING DOCUMENTATION' in line:
class_name = line.replace(' ', '').split('%')[0].split('<')[0].split('classdef')[1]
print(class_name)
try:
n_methods = len(documented_methods[class_name])
line = line.replace(TMP_FILE_STR, '')
line = line.replace(' '+TMP_FILE_STR, '')
_write_lines(content[:i], ftemp)
_write_lines([line], ftemp)
_write_lines(content[i+n_methods+5:], ftemp)
except KeyError:
ignore_class = True
continue
close(fh)
......@@ -123,9 +132,8 @@ def postprocess():
close(fh)
remove(code_dir + "/" + file_name)
move(abs_path, code_dir + "/" + file_name)
# At this point, entire file has been processed: continue outer loop
# Hackily implemented by raising an exception
raise StopIteration
raise StopIteration # At this point, entire file has been processed: continue outer loop
except StopIteration:
continue
except IOError:
......@@ -134,9 +142,21 @@ def postprocess():
postprocess_html_files()
def postprocess_html_files():
documented_classes = ['Motor', 'Sensor', 'EV3', 'usbBrickIO', 'btBrickIO']
""" Postprocesses the created doc html-files
Some formatting and internal errors occurs when the HTML-files are created.
The following bugs have been found and are being fixed by this function:
- Replace ` with ' (This is necessary to make code examples
copy-pastable. During the creation of the html-files ' has been replaced
by ` for some reason.)
- Delete module name from class documentation (Sphinx wrongly interprets
the file-name of the toolbox as the module name, which it would be if it
were dealing with Python)
- Replace wrong hrefs by internal links (Some would-be-internal links
wrongly point to some ominous 'source.html'-file)
"""
for file_name in documented_classes:
for file_name in DOCUMENTED_CLASSES:
current_file = os.path.abspath('_build/html/' + file_name + '.html')
try:
fh, abs_path = mkstemp()
......@@ -145,8 +165,6 @@ def postprocess_html_files():
content = f_old.readlines()
for i, line in enumerate(content):
# Replace ` with '
# This is necessary to make code examples copy-pastable. During the
# creation of the html-files, ' has been replaced by ` for some reason. :(
if('&#8216' in line or '&#8217' in line):
line = line.replace('&#8216;', '\'').replace('&#8217;', '\'')
......@@ -155,6 +173,7 @@ def postprocess_html_files():
if(ugly_module_string in line):
line = line.replace(ugly_module_string, '')
# Replace wrong hrefs by internal links
wrong_href = 'source.html'
if(wrong_href in line):
line = line.replace(wrong_href, '')
......@@ -167,6 +186,7 @@ def postprocess_html_files():
print('WARNING: Couldn''t postprocess html-file ' + current_file)
continue
## Helper functions
def _ignore_line(line) -> bool:
return (line.startswith('%') or line == '\n' or line == '')
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment