Skip to content

Commit cd52616

Browse files
authored
Add warning about setting up pins in custom firmware
1 parent fa38921 commit cd52616

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

programming/sr/ruggeduinos/custom_firmware.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,11 @@ If you're using completely custom firmware, you'll need to tell the kit to ignor
2525
[Extension of the SR firmware](#extension) {#extension}
2626
------------------------------
2727

28+
<div class="warning">
29+
Because the API sets all pins to inputs when the robot is initialised, you cannot set pin modes in the setup function as these will be overridden.
30+
In order to setup pins you can either create a function on the ruggeduino that you call after your robot is initialised or use the [python functions](/docs/programming/sr/ruggeduinos/) to setup the pins.
31+
</div>
32+
2833
You may wish to extend the SR firmware with additional functionality.
2934
This will allow you to continue using the commands already provided by the SR firmware (e.g. `digital_read()`),
3035
which means any existing robot code you have won't need modifying very much.

0 commit comments

Comments
 (0)