1.. _boardname_linkname: 2 3SparkFun MicroMod board Processor 4################################# 5 6Overview 7******** 8 9MicroMod is a solderless, modular interface ecosystem that uses the M.2 standard 10to mix and match your choice of processor with specific Function Boards or 11stand-alone Carrier Boards. A MicroMod processor board is approximately 22x22 mm, 12and can insert into any MicroMod carrier board. More information can be found in 13the `Micromod specification website`_. 14 15All Micromod board targets support the following hardware features: 16 17- USB host mode compliant to 2.0 specification 18- GPIO 19- 2 UART 20- 2 I2C 21- 2 SPI 22- 2 ADC 23- 2 PWM 24- Watchdog Timer (WDT) 25 26.. figure:: img/sparkfun_micromod.webp 27 :align: center 28 :alt: Sparkfun Micromod board 29 30 Sparkfun Micromod board (Credit: https://www.sparkfun.com) 31 32Zephyr currently supports the following SoCs: 33 34- ``micromod/nrf52840`` 35 36SparkFun MicroMod nRF52840 board Processor 37########################################## 38 39Overview 40******** 41 42The ``micromod/nrf52840`` board target features the nRF52840 SoC 43from Nordic Semiconductor, the SparkFun MicroMod nRF52840 Processor offers 44a powerful combination of ARM Cortex-M4 CPU and 2.4 GHz Bluetooth transceiver 45in the MicroMod form-factor. More information can be found in 46the `Micromod nRF52840 guide`_. 47 48Hardware 49******** 50 51The ``micromod/nrf52840`` board target supports the following 52hardware features: 53 54- ARM Cortex-M4 CPU with floating point unit (FPU) 55 56 - 1MB internal Flash 57 - 256kB internal RAM 58 59- Integrated 2.4GHz radio with support for Bluetooth Low Energy (BLE) and ieee802154 60- USB 2.0 full speed (12 Mbps) controller 61- QSPI with 128Mb flash memory 62- ARM TrustZone Cryptocell 310 security subsystem 63- USB host mode compliant to 2.0 specification 64- GPIO 65- 2 UART 66- 2 I2C 67- 2 SPI 68- 2 ADC 69- 2 PWM 70- Watchdog Timer (WDT) 71 72Supported Features 73================== 74 75The Zephyr ``micromod/nrf52840`` board target supports the following hardware 76features: 77 78+-----------+------------+-------------------------------------+ 79| Interface | Controller | Driver/Component | 80+===========+============+=====================================+ 81| NVIC | on-chip | nested vector interrupt controller | 82+-----------+------------+-------------------------------------+ 83| SYSTICK | on-chip | system clock | 84+-----------+------------+-------------------------------------+ 85| RADIO | on-chip | Bluetooth, | 86| | | ieee802154 | 87+-----------+------------+-------------------------------------+ 88| UART | on-chip | serial port | 89+-----------+------------+-------------------------------------+ 90| GPIO | on-chip | gpio | 91+-----------+------------+-------------------------------------+ 92| PINMUX | on-chip | pinmux | 93+-----------+------------+-------------------------------------+ 94| FLASH | on-chip | flash | 95+-----------+------------+-------------------------------------+ 96| SPI | on-chip | spi | 97+-----------+------------+-------------------------------------+ 98| I2C | on-chip | i2c | 99+-----------+------------+-------------------------------------+ 100| USB | on-chip | usb | 101+-----------+------------+-------------------------------------+ 102| QSPI | on-chip | nordic,nrf-qspi | 103+-----------+------------+-------------------------------------+ 104 105 106Connections and IOs 107=================== 108 109LED 110--- 111 112* Led0 (blue) = P0.13 113 114Micromod header 115--------------- 116 117* micromod_1_uart = uart0 118* micromod_2_uart = uart1 119* micromod_0_i2c = i2c0 120* micromod_1_i2c = i2c1 121* micromod_0_spi = spi2 122* micromod_header compatible with ``sparkfun,micromod-gpio`` 123 124Programming and Debugging 125************************* 126 127Applications for the ``micromod/nrf52840`` board target can be 128built, flashed, and debugged in the usual way. See 129:ref:`build_an_application` and :ref:`application_run` for more details on 130building and running. 131 132Flashing 133======== 134 135Follow the instructions in the :ref:`nordic_segger` page to install 136and configure all the necessary software. Further information can be 137found in :ref:`nordic_segger_flashing`. Then build and flash 138applications as usual (see :ref:`build_an_application` and 139:ref:`application_run` for more details). 140 141The flashing tool will depend on the carrier used along with the board. 142In the case of `Sparkfun asset tracking carrier`_, it is possible to use 143the SWD interface along with a J-Link. 144 145Here is an example for the :zephyr:code-sample:`hello_world` application. 146 147First, run your favorite terminal program to listen for output. 148 149.. code-block:: console 150 151 $ minicom -D <tty_device> -b 115200 152 153Replace :code:`<tty_device>` with the port where the board nRF52840 DK 154can be found. For example, under Linux, :code:`/dev/ttyACM0`. 155 156Then build and flash the application in the usual way. 157 158.. zephyr-app-commands:: 159 :zephyr-app: samples/hello_world 160 :board: micromod/nrf52840 161 :goals: build flash 162 163Debugging 164========= 165 166Refer to the :ref:`nordic_segger` page to learn about debugging Nordic boards with a 167Segger IC. 168 169In case of using a Nordic Segger Jlink, it is possible to configure the app to use Segger Real 170Time Transfer (RTT) for debugging. In this case, build your app with the 171:ref:`RTT snippet <snippet-rtt-console>`. 172 173Testing the on-board LED 174************************ 175 176There is a sample that allow you to test the LED on the board is working properly 177with Zephyr: 178 179* :zephyr:code-sample:`blinky` 180 181You can build and flash the example to make sure Zephyr is running correctly on 182your board. The button and LED definitions can be found in 183:zephyr_file:`boards/sparkfun/micromod/micromod_nrf52840.dts`. 184 185Testing the 128Mb qspi memory flash 186*********************************** 187 188The ``micromod/nrf52840`` board target has a built-in NOR flash memory connected 189to the qspi interface. It can be tested with the samples/drivers/jesd216 app. 190 191.. zephyr-app-commands:: 192 :zephyr-app: samples/drivers/jesd216 193 :board: micromod/nrf52840 194 :goals: build flash 195 196References 197********** 198 199.. target-notes:: 200 201.. _Micromod specification website: https://www.sparkfun.com/micromod 202.. _Sparkfun asset tracking carrier: https://www.sparkfun.com/products/17272 203.. _Micromod nRF52840 guide: https://learn.sparkfun.com/tutorials/micromod-nrf52840-processor-hookup-guide 204.. _J-Link Software and documentation pack: https://www.segger.com/jlink-software.html 205.. _nRF52840 Product Specification: http://infocenter.nordicsemi.com/pdf/nRF52840_PS_v1.0.pdf 206