Skip to content

Commit ffec176

Browse files
authored
Merge pull request #509 from sparkfun/docs_updates
Update firmware_update.md
2 parents 621e091 + 5490e98 commit ffec176

File tree

1 file changed

+74
-35
lines changed

1 file changed

+74
-35
lines changed

docs/firmware_update.md

Lines changed: 74 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -272,12 +272,15 @@ As of writing, no additional releases of the NEO-D9S firmware have been made.
272272
The SparkFun RTK firmware is compiled using Arduino (currently v1.8.15). To compile:
273273

274274
1. Install [Arduino](https://www.arduino.cc/en/software).
275+
275276
2. Install ESP32 for Arduino. [Here](https://learn.sparkfun.com/tutorials/esp32-thing-hookup-guide#installing-via-arduino-ide-boards-manager) are some good instructions for installing it via the Arduino Boards Manager. **Note**: Use v2.0.2 of the core. **Note:** We use the 'ESP32 Dev Module' for pin numbering. Select the correct board under Tools->Board->ESP32 Arduino->ESP32 Dev Module.
277+
276278
3. Change the Partition table. Replace
277279

278280
```C:\Users\\[user name]\AppData\Local\Arduino15\packages\esp32\hardware\esp32\2.0.2\tools\partitions\app3M_fat9M_16MB.csv```
279281

280282
with the app3M_fat9M_16MB.csv [file](https://github.com/sparkfun/SparkFun_RTK_Firmware/blob/main/Firmware/app3M_fat9M_16MB.csv?raw=true) found in the [Firmware folder](https://github.com/sparkfun/SparkFun_RTK_Firmware/tree/main/Firmware). This will increase the program partition from a maximum of 1.9MB to 3MB.
283+
281284
4. From the Arduino IDE, set the core settings from the **Tools** menu:
282285

283286
A. Set the 'Partition Scheme' to *16M Flash (3MB APP/9MB FATFS)*. This will use the 'app3M_fat9M_16MB.csv' updated partition table.
@@ -301,28 +304,47 @@ You have not replaced the partition file correctly. See the 'Change Partition ta
301304
**Note:** You should click on the link next to each of the #includes at the top of RTK_Surveyor.ino within the Arduino IDE to open the library manager and download them. Getting them directly from Github also works but may not be 'official' releases.
302305

303306
Using the library manager in the Arduino IDE, for each of the libraries below:
307+
304308
1. Locate the library by typing the libary name into the search box
309+
305310
2. Click on the library
311+
306312
3. Select the version listed in the compile-rtk-firmware.yml file for the [main](https://github.com/sparkfun/SparkFun_RTK_Firmware/blob/main/.github/workflows/compile-rtk-firmware.yml) or the [release_candidate](https://github.com/sparkfun/SparkFun_RTK_Firmware/blob/release_candidate/.github/workflows/compile-rtk-firmware.yml) branch
313+
307314
4. Click on the Install button in the lower right
308315

309316
The RTK firmware requires the following libraries:
317+
310318
* [Arduino JSON](https://github.com/bblanchon/ArduinoJson)
319+
311320
* [ESP32Time](https://github.com/fbiego/ESP32Time)
321+
312322
* [ESP32 BleSerial](https://github.com/avinabmalla/ESP32_BleSerial)
323+
313324
* [ESP32-OTA-Pull](https://github.com/mikalhart/ESP32-OTA-Pull)
325+
314326
* Ethernet
327+
315328
* [JC_Button](https://github.com/JChristensen/JC_Button)
329+
316330
* [PubSub Client for MQTT](https://github.com/knolleary/pubsubclient)
331+
317332
* [SdFat](https://github.com/greiman/SdFat)
333+
318334
* [SparkFun LIS2DH12 Arduino Library](https://github.com/sparkfun/SparkFun_LIS2DH12_Arduino_Library)
335+
319336
* [SparkFun MAX1704x Fuel Gauge Arduino Library](https://github.com/sparkfun/SparkFun_MAX1704x_Fuel_Gauge_Arduino_Library)
337+
320338
* [SparkFun u-blox GNSS v3](https://github.com/sparkfun/SparkFun_u-blox_GNSS_v3)
339+
321340
* [SparkFun_WebServer_ESP32_W5500](https://github.com/SparkFun/SparkFun_WebServer_ESP32_W5500)
322341

323342
The following libraries are only available via GitHub:
343+
324344
* [AsyncTCP](https://github.com/me-no-dev/AsyncTCP) (not available via library manager)
345+
325346
* [ESPAsyncWebServer](https://github.com/me-no-dev/ESPAsyncWebServer) (not available via library manager)
347+
326348
* [SparkFun Micro OLED Breakout](https://github.com/sparkfun/SparkFun_Micro_OLED_Arduino_Library)
327349

328350
### Ubuntu 20.04
@@ -332,7 +354,9 @@ The following libraries are only available via GitHub:
332354
Execute the following commands to create the Linux virtual machine:
333355

334356
1. Using a browser, download the Ubuntu 20.04 Desktop image
357+
335358
2. virtualbox
359+
336360
1. Click on the new button
337361
2. Specify the machine Name, e.g.: Sparkfun_RTK_20.04
338362
3. Select Type: Linux
@@ -358,11 +382,17 @@ Execute the following commands to create the Linux virtual machine:
358382
23. Under 'Attached to:' select Bridged Adapter
359383
24. Click the OK button
360384
25. Click the Start button
361-
2. Install Ubuntu 20.04
362-
3. Log into Ubuntu
363-
4. Click on Activities
364-
5. Type terminal into the search box
365-
6. Optionally install the SSH server
385+
386+
3. Install Ubuntu 20.04
387+
388+
4. Log into Ubuntu
389+
390+
5. Click on Activities
391+
392+
6. Type terminal into the search box
393+
394+
7. Optionally install the SSH server
395+
366396
1. In the terminal window
367397
1. sudo apt install -y net-tools openssh-server
368398
2. ifconfig
@@ -381,7 +411,7 @@ Execute the following commands to create the build environment for the SparkFun
381411
1. sudo adduser $USER dialout
382412
2. sudo shutdown -r 0
383413

384-
Reboot to ensure that the dialout privilege is available to the user
414+
Reboot to ensure that the dialout privilege is available to the user
385415

386416
3. sudo apt update
387417
4. sudo apt install -y git gitk git-cola minicom python3-pip
@@ -393,8 +423,9 @@ Reboot to ensure that the dialout privilege is available to the user
393423
10. cd ~/SparkFun
394424
11. nano serial-port.sh
395425

396-
Insert the following text into the file:
426+
Insert the following text into the file:
397427

428+
```C++
398429
#!/bin/bash
399430
# serial-port.sh
400431
#
@@ -404,12 +435,14 @@ Insert the following text into the file:
404435
# 1: ttyUSBn
405436
#
406437
sudo minicom -b 115200 -8 -D /dev/$1 < /dev/tty
438+
```
407439

408440
12. chmod +x serial-port.sh
409441
13. nano new-firmware.sh
410442

411-
Insert the following text into the file:
443+
Insert the following text into the file:
412444

445+
```C++
413446
#!/bin/bash
414447
# new-firmware.sh
415448
#
@@ -424,12 +457,14 @@ Insert the following text into the file:
424457
0x8000 ~/SparkFun/RTK_Binaries/bin/RTK_Surveyor_Partitions_16MB.bin \
425458
0xe000 ~/SparkFun/RTK_Binaries/bin/boot_app0.bin \
426459
0x10000 $2
460+
```
427461

428462
14. chmod +x new-firmware.sh
429463
15. nano new-firmware-4mb.sh
430464

431-
Insert the following text into the file:
465+
Insert the following text into the file:
432466

467+
```C++
433468
#!/bin/bash
434469
# new-firmware-4mb.sh
435470
#
@@ -444,22 +479,23 @@ Insert the following text into the file:
444479
0x8000 ~/SparkFun/RTK_Binaries/bin/RTK_Surveyor_Partitions_4MB.bin \
445480
0xe000 ~/SparkFun/RTK_Binaries/bin/boot_app0.bin \
446481
0x10000 $2
482+
```
447483

448484
16. chmod +x new-firmware-4mb.sh
449485

450-
Get the SparkFun RTK Firmware sources
486+
Get the SparkFun RTK Firmware sources
451487

452488
17. mkdir ~/SparkFun/RTK
453489
18. cd ~/SparkFun/RTK
454490
19. git clone https://github.com/sparkfun/SparkFun_RTK_Firmware .
455491

456-
Get the SparkFun RTK binaries
492+
Get the SparkFun RTK binaries
457493

458494
20. mkdir ~/SparkFun/RTK_Binaries
459495
21. cd ~/SparkFun/RTK_Binaries
460496
22. git clone https://github.com/sparkfun/SparkFun_RTK_Firmware_Binaries.git .
461497

462-
Install the Arduino IDE
498+
Install the Arduino IDE
463499

464500
23. mkdir ~/SparkFun/arduino
465501
24. cd ~/SparkFun/arduino
@@ -468,9 +504,10 @@ Install the Arduino IDE
468504
27. cd arduino-1.8.15/
469505
28. sudo ./install.sh
470506

471-
Add the ESP32 support
507+
Add the ESP32 support
508+
509+
29. Arduino
472510

473-
29. arduino
474511
1. Click on File in the menu bar
475512
2. Click on Preferences
476513
3. Go down to the Additional Boards Manager URLs text box
@@ -481,7 +518,7 @@ Add the ESP32 support
481518
8. Click on File in the menu bar
482519
9. Click on Quit
483520

484-
Get the required external libraries, then add to the Sketchbook location from above
521+
Get the required external libraries, then add to the Sketchbook location from above
485522

486523
30. cd ~/Arduino/libraries
487524
31. mkdir AsyncTCP
@@ -492,13 +529,14 @@ Get the required external libraries, then add to the Sketchbook location from ab
492529
36. cd ESPAsyncWebServer
493530
37. git clone https://github.com/me-no-dev/ESPAsyncWebServer .
494531

495-
Connect the Config ESP32 port of the RTK to a USB port on the computer
532+
Connect the Config ESP32 port of the RTK to a USB port on the computer
496533

497534
38. ls /dev/ttyUSB*
498535

499-
Enable the libraries in the Arduino IDE
536+
Enable the libraries in the Arduino IDE
537+
538+
39. Arduino
500539

501-
39. arduino
502540
1. From the menu, click on File
503541
2. Click on Open...
504542
3. Select the ~/SparkFun/RTK/Firmware/RTK_Surveyor/RTK_Surveyor.ino file
@@ -520,9 +558,10 @@ Enable the libraries in the Arduino IDE
520558

521559
Load the required libraries
522560

523-
15. From the menu, click on Tools
524-
16. Click on Manage Libraries…
525-
17. For each of the following libraries:
561+
16. From the menu, click on Tools
562+
17. Click on Manage Libraries…
563+
18. For each of the following libraries:
564+
526565
1. Locate the library
527566
2. Click on the library
528567
3. Select the version listed in the compile-rtk-firmware.yml file for the [main](https://github.com/sparkfun/SparkFun_RTK_Firmware/blob/main/.github/workflows/compile-rtk-firmware.yml) or the [release_candidate](https://github.com/sparkfun/SparkFun_RTK_Firmware/blob/release_candidate/.github/workflows/compile-rtk-firmware.yml) branch
@@ -545,26 +584,26 @@ Enable the libraries in the Arduino IDE
545584
* SparkFun u-blox GNSS v3
546585
* SparkFun_WebServer_ESP32_W5500
547586

548-
18. Click on the Close button
587+
19. Click on the Close button
549588

550589
Select the terminal port
551590

552-
19. From the menu, click on Tools
553-
20. Click on Port, Select the port that was displayed in step 38 above
554-
21. Select /dev/ttyUSB0
555-
22. Click on Upload Speed
556-
23. Select 230400
591+
20. From the menu, click on Tools
592+
21. Click on Port, Select the port that was displayed in step 38 above
593+
22. Select /dev/ttyUSB0
594+
23. Click on Upload Speed
595+
24. Select 230400
557596

558597
Setup the partitions for the 16 MB flash
559598

560-
24. From the menu, click on Tools
561-
25. Click on Flash Size
562-
26. Select 16MB
563-
27. From the menu, click on Tools
564-
28. Click on Partition Scheme
565-
29. Click on 16M Flash (3MB APP/9MB FATFS)
566-
30. From the menu click on File
567-
31. Click on Quit
599+
25. From the menu, click on Tools
600+
26. Click on Flash Size
601+
27. Select 16MB
602+
28. From the menu, click on Tools
603+
29. Click on Partition Scheme
604+
30. Click on 16M Flash (3MB APP/9MB FATFS)
605+
31. From the menu click on File
606+
32. Click on Quit
568607

569608
40. cd ~/SparkFun/RTK/
570609
41. cp Firmware/app3M_fat9M_16MB.csv ~/.arduino15/packages/esp32/hardware/esp32/2.0.2/tools/partitions/app3M_fat9M_16MB.csv

0 commit comments

Comments
 (0)