Skip to content

Commit 114aa7a

Browse files
authored
Merge pull request #790 from adafruit/add-fruitjam
Add Adafruit Fruit Jam - Mini RP2350 Computer
2 parents f4788c0 + 5e76adc commit 114aa7a

File tree

8 files changed

+50
-25
lines changed

8 files changed

+50
-25
lines changed

.github/workflows/build-clang-doxy.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -592,7 +592,7 @@ jobs:
592592
strategy:
593593
fail-fast: false
594594
matrix:
595-
arduino-platform: ["picow_rp2040_tinyusb", "picow_rp2350_tinyusb"]
595+
arduino-platform: ["picow_rp2040_tinyusb", "picow_rp2350_tinyusb", "fruit_jam_tinyusb"]
596596
steps:
597597
- name: "skip if unwanted"
598598
continue-on-error: true
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
2+
3+
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
2+
3+

platformio.ini

Lines changed: 21 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,10 @@ lib_deps =
8989
adafruit/Adafruit SSD1306
9090
https://github.com/tyeth/omron-devhub_d6t-arduino.git
9191
https://github.com/pstolarz/OneWireNg.git
92+
; COMMENT OUT FOR RP2040/RP2350 BOARDS
9293
https://github.com/milesburton/Arduino-Temperature-Control-Library.git
94+
; AND UNCOMMENT FOR RP2040/RP2350 BOARDS
95+
; https://github.com/pstolarz/Arduino-Temperature-Control-Library.git
9396
https://github.com/Sensirion/arduino-sht.git
9497
https://github.com/Sensirion/arduino-i2c-scd4x.git
9598
https://github.com/Sensirion/arduino-i2c-sen5x.git
@@ -126,19 +129,15 @@ lib_compat_mode = strict
126129
lib_archive = no ; debug timer issues see https://community.platformio.org/t/choose-usb-stack-as-tiny-usb/22451/5
127130
lib_ignore = OneWire, USBHost
128131

129-
[common:rp2040]
132+
; Common build environment for Arduino-Pico platforms
133+
[common:arduinopico]
130134
platform = https://github.com/maxgerhardt/platform-raspberrypi.git#develop
131-
; platform_packages =
132-
; framework-arduinopico @ symlink:///Users/tyeth/Projects/arduino-pico
133-
; framework-arduinopico@https://github.com/earlephilhower/arduino-pico.git#master
134-
board = rpipicow
135+
platform_packages = framework-arduinopico@https://github.com/earlephilhower/arduino-pico.git
135136
framework = arduino
136137
board_build.core = earlephilhower
137138
board_build.filesystem_size = 0.5m
138-
build_flags = -DUSE_TINYUSB
139-
; Once https://github.com/platformio/platformio-core > 6.1.11 these can be removed
140139
lib_ignore = WiFiNINA, WiFi101, Adafruit Zero DMA Library, OneWire
141-
lib_compat_mode = soft ; can be strict once pio detects SleepyDog on RP2040
140+
lib_compat_mode = soft ; can be stricter once pio detects SleepyDog on RP2040
142141

143142

144143
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; Individual Board Definitions ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
@@ -546,16 +545,20 @@ board_build.partitions = min_spiffs.csv
546545

547546

548547
[env:raspberypi_picow]
549-
extends = common:rp2040
548+
extends = common:arduinopico
549+
board = rpipicow
550+
build_flags =
551+
-DUSE_TINYUSB
550552

551553
[env:raspberypi_picow_debug_port_only]
552-
extends = common:rp2040
554+
extends = common:arduinopico
555+
board = rpipicow
553556
build_flags =
554557
-DUSE_TINYUSB
555558
-DDEBUG_RP2040_PORT=Serial
556559

557560
[env:raspberypi_picow_debug]
558-
extends = common:rp2040
561+
extends = common:arduinopico
559562
; platform = https://github.com/maxgerhardt/platform-raspberrypi.git
560563
; platform_packages =
561564
; framework-arduinopico @ symlink:///Users/tyeth/Projects/arduino-pico
@@ -597,7 +600,7 @@ build_flags =
597600

598601

599602
[env:raspberypi_pico2w]
600-
extends = common:rp2040
603+
extends = common:arduinopico
601604
platform = https://github.com/maxgerhardt/platform-raspberrypi.git#develop
602605
platform_packages =
603606
framework-arduinopico@https://github.com/earlephilhower/arduino-pico.git
@@ -610,11 +613,7 @@ build_flags =
610613
; -DPICO_CYW43_SUPPORTED=1
611614

612615
[env:raspberypi_pico2w_debug]
613-
extends = common:rp2040
614-
platform = https://github.com/maxgerhardt/platform-raspberrypi.git#develop
615-
platform_packages =
616-
framework-arduinopico@https://github.com/earlephilhower/arduino-pico.git
617-
; ; framework-arduinopico @ symlink:///Users/tyeth/Projects/arduino-pico
616+
extends = common:arduinopico
618617
board = rpipico2w
619618
build_type = debug
620619
framework = arduino
@@ -654,3 +653,8 @@ build_flags =
654653
; ; No USB stack
655654
; build_flags = -DPIO_FRAMEWORK_ARDUINO_NO_USB
656655
; -DPIO_FRAMEWORK_ARDUINO_ENABLE_IPV6
656+
657+
[env:adafruit_fruitjam]
658+
board = adafruit_fruitjam
659+
lib_ignore = WiFi, WiFi101, Adafruit Zero DMA Library
660+
build_flags = -DUSE_TINYUSB -DADAFRUIT_FRUITJAM_RP2350

src/Wippersnapper_Boards.h

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -223,6 +223,12 @@
223223
#define USE_TINYUSB
224224
#define USE_STATUS_LED
225225
#define STATUS_LED_PIN LED_BUILTIN
226+
#elif defined(ARDUINO_ADAFRUIT_FRUITJAM_RP2350)
227+
#define BOARD_ID "fruitjam"
228+
#define USE_TINYUSB
229+
#define USE_STATUS_NEOPIXEL
230+
#define STATUS_NEOPIXEL_PIN PIN_NEOPIXEL
231+
#define STATUS_NEOPIXEL_NUM 5
226232
#else
227233
#warning "Board type not identified within Wippersnapper_Boards.h!"
228234
#endif

src/Wippersnapper_Networking.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,8 @@
2323

2424
#if defined(ADAFRUIT_METRO_M4_EXPRESS) || \
2525
defined(ADAFRUIT_METRO_M4_AIRLIFT_LITE) || defined(ADAFRUIT_PYPORTAL) || \
26-
defined(ADAFRUIT_PYPORTAL_M4_TITANO) || defined(USE_AIRLIFT)
26+
defined(ADAFRUIT_PYPORTAL_M4_TITANO) || defined(USE_AIRLIFT) || \
27+
defined(ADAFRUIT_FRUITJAM_RP2350)
2728
#include "network_interfaces/Wippersnapper_AIRLIFT.h"
2829
/** Nina-FW (adafruit fork) networking class */
2930
typedef Wippersnapper_AIRLIFT Wippersnapper_WiFi;

src/network_interfaces/Wippersnapper_AIRLIFT.h

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
* please support Adafruit and open-source hardware by purchasing
1212
* products from Adafruit!
1313
*
14-
* Copyright (c) Brent Rubell 2020-2021 for Adafruit Industries.
14+
* Copyright (c) Brent Rubell 2020-2025 for Adafruit Industries.
1515
*
1616
* MIT license, all text here must be included in any redistribution.
1717
*
@@ -32,7 +32,9 @@
3232
#define AIRLIFT_CONNECT_TIMEOUT_MS 20000 /*!< Connection timeout (in ms) */
3333
#define AIRLIFT_CONNECT_RETRY_DELAY_MS 200 /*!< delay time between retries. */
3434

35+
#ifndef SPIWIFI
3536
#define SPIWIFI SPI /*!< Instance of SPI interface used by an AirLift. */
37+
#endif
3638

3739
extern Wippersnapper WS;
3840
/****************************************************************************/
@@ -49,9 +51,13 @@ class Wippersnapper_AIRLIFT : public Wippersnapper {
4951
*/
5052
/**************************************************************************/
5153
Wippersnapper_AIRLIFT() : Wippersnapper() {
52-
_ssPin = SPIWIFI_SS; // 10;
53-
_ackPin = SPIWIFI_ACK; // 7;
54-
_rstPin = SPIWIFI_RESET; // 5; // should be 7 on PyPortals
54+
_ssPin = SPIWIFI_SS;
55+
_ackPin = SPIWIFI_ACK;
56+
#ifdef ESP32_RESETN
57+
_rstPin = ESP32_RESETN; // FruitJam
58+
#else
59+
_rstPin = SPIWIFI_RESET;
60+
#endif // ESP32_RESETN
5561
#ifdef ESP32_GPIO0
5662
_gpio0Pin = ESP32_GPIO0;
5763
#else
@@ -236,7 +242,7 @@ class Wippersnapper_AIRLIFT : public Wippersnapper {
236242
*/
237243
/********************************************************/
238244
void getMacAddr() {
239-
uint8_t mac[6] = {0x00, 0x00, 0x00, 0x00, 0x00, 0x00};
245+
byte mac[6] = {0};
240246
WiFi.macAddress(mac);
241247
memcpy(WS._macAddr, mac, sizeof(mac));
242248
}

src/provisioning/tinyusb/Wippersnapper_FS.cpp

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,9 @@
2828
defined(ARDUINO_ADAFRUIT_FEATHER_ESP32S3_REVTFT) || \
2929
defined(ARDUINO_ADAFRUIT_FEATHER_ESP32S2_REVTFT) || \
3030
defined(ARDUINO_ADAFRUIT_QTPY_ESP32S3_N4R2) || \
31-
defined(ARDUINO_XIAO_ESP32S3)
31+
defined(ARDUINO_XIAO_ESP32S3) || \
32+
defined(ADAFRUIT_FRUITJAM_RP2350)
33+
3234
#include "Wippersnapper_FS.h"
3335
#include "print_dependencies.h"
3436
// On-board external flash (QSPI or SPI) macros should already

0 commit comments

Comments
 (0)