Skip to content

Commit a12144c

Browse files
Juliana MashonJuliana Mashon
Juliana Mashon
authored and
Juliana Mashon
committed
Updated README and cleaned up file comments
1 parent 3f3575a commit a12144c

File tree

1 file changed

+21
-13
lines changed

1 file changed

+21
-13
lines changed

README.md

+21-13
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,14 @@ bot.get_token("email", "password")
7373

7474
### Configure function output verbosity
7575

76+
Set the level of verbosity of function outputs to change the level of information shown when functions are called.
77+
78+
| Verbosity | Example using `e_stop()` |
79+
| :--- | :--- |
80+
| `0` The function will return with no output. | No output. |
81+
| `1` The name of the function will be output. | `e_stop called` |
82+
| `2` The name of the function will be output with additional information about the return value. | `Triggered device emergency stop at: 2024-08-21 11:16:18.547813` |
83+
7684
## :compass: Functions
7785

7886
```
@@ -106,7 +114,7 @@ sidecar-starter-pack/
106114
### authentication.py
107115

108116
| class `Authentication()` | Description |
109-
| --- | --- |
117+
| :--- | :--- |
110118
| `get_token()` | [API] Get FarmBot authorization token. Server is "https://my.farm.bot" by default. |
111119
| `check_token()` | [API] Ensure the token persists throughout sidecar. |
112120
| `request_handling()` | [API] Handle errors associated with different endpoint errors. |
@@ -118,7 +126,7 @@ sidecar-starter-pack/
118126
### basic_commands.py
119127

120128
| class `BasicCommands()` | Description |
121-
| --- | --- |
129+
| :--- | :--- |
122130
| `wait()` | [BROKER] Pauses execution for a certain number of milliseconds. |
123131
| `e_stop()` | [BROKER] Emergency locks (E-stops) the Farmduino microcontroller and resets peripheral pins to OFF. |
124132
| `unlock()` | [BROKER] Unlocks a locked (E-stopped) device. |
@@ -128,7 +136,7 @@ sidecar-starter-pack/
128136
### broker.py
129137

130138
| class `BrokerConnect()` | Description |
131-
| --- | --- |
139+
| :--- | :--- |
132140
| `connect()` | [BROKER] Establish persistent connection to send messages via message broker. |
133141
| `disconnect()` | [BROKER] Disconnect from the message broker. |
134142
| `publish()` | [BROKER] Publish messages containing CeleryScript via the message broker. |
@@ -140,15 +148,15 @@ sidecar-starter-pack/
140148
### camera.py
141149

142150
| class `Camera()` | Description |
143-
| --- | --- |
151+
| :--- | :--- |
144152
| `calibrate_camera()` | [BROKER] Performs camera calibration. This action will reset camera calibration settings. |
145153
| `take_photo()` | [BROKER] Takes a photo using the device camera and uploads it to the web app. |
146154
<!--- | `photo_grid()` | [BROKER] Returns metadata object about point grid required to perform a scan of the full garden. | --->
147155

148156
### information.py
149157

150158
| class `Information()` | Description |
151-
| --- | --- |
159+
| :--- | :--- |
152160
| `get_info()` | [API] Get information about a specific endpoint. |
153161
| `set_info()` | [API] Change information contained within an endpoint. |
154162
| `safe_z()` | [API] Returns the highest safe point along the z-axis. |
@@ -168,15 +176,15 @@ sidecar-starter-pack/
168176
### jobs.py
169177

170178
| class `JobHandling()` | Description |
171-
| --- | --- |
179+
| :--- | :--- |
172180
| `get_job()` | [BROKER] Retrieves the status or details of the specified job. |
173181
| `set_job()` | [BROKER] Initiates or modifies job with given parameters. |
174182
| `complete_job()` | [BROKER] Marks job as completed and triggers any associated actions. |
175183

176184
### messages.py
177185

178186
| class `MessageHandling()` | Description |
179-
| --- | --- |
187+
| :--- | :--- |
180188
| `log()` | [API] Sends new log message via the API. Requires the page to be refreshed before appearing. |
181189
| `message()` | [BROKER] Sends new log message via the message broker. |
182190
| `debug()` | [BROKER] Sends debug message used for developer information or troubleshooting. |
@@ -185,7 +193,7 @@ sidecar-starter-pack/
185193
### movements.py
186194

187195
| class `MovementControls()` | Description |
188-
| --- | --- |
196+
| :--- | :--- |
189197
| `move()` | [BROKER] Moves to the specified (x, y, z) coordinate. |
190198
| `set_home()` | [BROKER] Sets the current position as the home position for a specific axis. |
191199
| `find_home()` | [BROKER] Moves the device to the home position for a specified axis. |
@@ -196,7 +204,7 @@ sidecar-starter-pack/
196204
### peripherals.py
197205

198206
| class `Peripherals()` | Description |
199-
| --- | --- |
207+
| :--- | :--- |
200208
| `control_servo()` | [BROKER] Set servo angle between 0-100 degrees. |
201209
| `control_peripheral()` | [BROKER] Set peripheral value (ON/OFF or slider value from 0-255) and mode (digital or analog). |
202210
| `toggle_peripheral()` | [BROKER] Toggles the state of a specific peripheral between 'on' (100%) and 'off' (0%). |
@@ -206,25 +214,25 @@ sidecar-starter-pack/
206214
### resources.py
207215

208216
| class `Resources()` | Description |
209-
| --- | --- |
217+
| :--- | :--- |
210218
| `mark_coord()` | [BROKER] Marks (x, y, z) coordinate with specified label. |
211-
<!--- | `sort_points()` | [BROKER] Sorts list of points (e.g., plants, weeds) based on specified criteria. | --->
212219
| `sequence()` | [BROKER] Executes a predefined sequence. |
213220
| `get_seed_tray_cell()` | [BROKER] Identifies and returns the location of specified cell in the seed tray. |
214221
| `detect_weeds()` | [BROKER] Scans the garden to detect weeds. |
215222
| `lua()` | [BROKER] Executes custom Lua code snippets to perform complex tasks or automations. |
216223
| `if_statement()` | [BROKER] Performs conditional check and executes actions based on the outcome. |
217224
| `assertion()` | [BROKER] Evaluates an expression. |
225+
<!--- | `sort_points()` | [BROKER] Sorts list of points (e.g., plants, weeds) based on specified criteria. | --->
218226

219227
### tools.py
220228

221229
| class `ToolControls()` | Description |
222-
| --- | --- |
223-
<!--- | `verify_tool()` | [BROKER] Verifies if tool is mounted to UTM via tool verification pin and MOUNTED TOOL field in FarmBot’s state tree. | --->
230+
| :--- | :--- |
224231
| `mount_tool()` | [BROKER] Mounts the given tool and pulls it out of assigned slot. |
225232
| `dismount_tool()` | [BROKER] Dismounts the currently mounted tool into assigned slot. |
226233
| `water()` | [BROKER] Moves to and waters plant based on age and assigned watering curve. |
227234
| `dispense()` | [BROKER] Dispenses user-defined amount of liquid in milliliters. |
235+
<!--- | `verify_tool()` | [BROKER] Verifies if tool is mounted to UTM via tool verification pin and MOUNTED TOOL field in FarmBot’s state tree. | --->
228236

229237
## :toolbox: Developer Info
230238

0 commit comments

Comments
 (0)