Skip to the content
2 layers66 × 99 mmNucleo32TNC, the printed circuit board in 3D

The Nucleo TNC is a breadboard implementation of the Mobilinkd TNC3 using a STM32L432KC Nucleo32 board. This TNC faithfully implements the audio section and EEPROM storage of the TNC3. It omits the battery charging and Bluetooth components of the TNC3. It presents as a KISS TNC over a USB serial port. This repository contains the build instructions, KiCAD schematics, and firmware source code.

Size
66 × 99 mm
Copper layers
2
Thickness
1.6 mm
Parts
54
Nets
52
Pads
155
Tracks, vias
187, 3
Pours
4
Routed
Yes
KiCad
KiCad 5 (file 20171130)
Created
29 Jul 2018
Updated
23 Jul 2023

Overview

Nucleo32TNC is an open-source printed circuit board by mobilinkd, from the mobilinkd/NucleoTNC repository on GitHub, published under the GPL-3.0 licence. It is a 2-layer board of 66 × 99 mm with 54 parts on 52 nets, routed with 187 tracks and 3 vias.

It is built around the MCP6004-E/P, 24LC32A/P and BAT85, with the SJ-43515TS among its other parts. Its parts include 22 resistors, 13 capacitors, 6 diodes, 2 ICs and 2 transistors.

Main components

4

README

README.md

NucleoTNC Firmware

Source code for STM32L432KC Nucleo32-based TNC (PCB & breadboard version).

http://www.mobilinkd.com/2019/06/24/nucleotnc/

Building the Firmware

Use Eclipse with CDT and the GNU MCU Eclipse plugins.

If you are porting this to another build platform, you will need to build the firmware using the same compiler and linker options. As with most firmware projects, there is a linker script with defines the memory layout for for the Flash and SRAM.

Blaze Dependency

There is a new dependency as of 2.4.3 with the addition of the Kalman filter. The firmware has a dependency on the Blaze C++ math library.

text
mkdir blaze
ln -s /usr/include/blaze blaze/

This also requires (for now) that the firmware be built with exceptions enabled.

Example GCC Command-line

Below are example compilation and linking lines for reference:

text
arm-none-eabi-g++ -mcpu=cortex-m4 -mthumb -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -O2 -fmessage-length=0 -fsigned-char -ffunction-sections -fdata-sections -fno-inline-functions -fsingle-precision-constant -fstack-usage -fstrict-aliasing -ffast-math -Wall -Wextra -Wlogical-op -Wfloat-equal -g -D__FPU_PRESENT=1 -DUSE_HAL_DRIVER -DARM_MATH_CM4 -DSTM32L432xx -D__weak=__attribute__((weak)) -DNUCLEOTNC=1 -I../Inc -I../Drivers/STM32L4xx_HAL_Driver/Inc -I/home/rob/workspace/Nucleo_L432KC_TNC/Inc -I/home/rob/workspace/Nucleo_L432KC_TNC/Drivers/STM32L4xx_HAL_Driver/Inc -I/home/rob/workspace/Nucleo_L432KC_TNC/Drivers/CMSIS/Include -I/home/rob/workspace/Nucleo_L432KC_TNC/Drivers/CMSIS/Device/ST/STM32L4xx/Include -I/home/rob/workspace/Nucleo_L432KC_TNC/Middlewares/Third_Party/FreeRTOS/Source/include -I/home/rob/workspace/Nucleo_L432KC_TNC/Middlewares/Third_Party/FreeRTOS/Source/CMSIS_RTOS -I/home/rob/workspace/Nucleo_L432KC_TNC/Middlewares/Third_Party/FreeRTOS/Source/portable/GCC/ARM_CM4F -I/home/rob/workspace/Nucleo_L432KC_TNC/TNC -I/usr/arm-none-eabi/include -std=gnu++1z -fabi-version=9 -fno-exceptions -fno-rtti -fno-use-cxa-atexit -fno-threadsafe-statics -Wno-register -c -o TNC/HdlcFrame.o ../TNC/HdlcFrame.cpp 
arm-none-eabi-g++ -mcpu=cortex-m4 -mthumb -mfloat-abi=softfp -mfpu=fpv4-sp-d16 -O2 -fmessage-length=0 -fsigned-char -ffunction-sections -fdata-sections -fno-inline-functions -fsingle-precision-constant -fstack-usage -fstrict-aliasing -ffast-math -Wall -Wextra -Wlogical-op -Wfloat-equal -g -T /home/rob/workspace/Nucleo_L432KC_TNC/STM32L432KC_FLASH.ld -Xlinker --gc-sections -Wl,-Map,firmware.map --specs=nano.specs -o firmware.elf Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal.o Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_adc.o Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_adc_ex.o Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_cortex.o Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_crc.o Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_crc_ex.o Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_dac.o Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_dac_ex.o Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_dma.o Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_dma_ex.o Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_flash.o Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_flash_ex.o Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_flash_ramfunc.o Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_gpio.o Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_i2c.o Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_i2c_ex.o Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_opamp.o Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_opamp_ex.o Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_pwr.o Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_pwr_ex.o Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_rcc.o Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_rcc_ex.o Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_rng.o Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_rtc.o Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_rtc_ex.o Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_tim.o Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_tim_ex.o Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_uart.o Drivers/STM32L4xx_HAL_Driver/Src/stm32l4xx_hal_uart_ex.o Middlewares/Third_Party/FreeRTOS/Source/CMSIS_RTOS/cmsis_os.o Middlewares/Third_Party/FreeRTOS/Source/croutine.o Middlewares/Third_Party/FreeRTOS/Source/event_groups.o Middlewares/Third_Party/FreeRTOS/Source/list.o Middlewares/Third_Party/FreeRTOS/Source/portable/GCC/ARM_CM4F/port.o Middlewares/Third_Party/FreeRTOS/Source/portable/MemMang/heap_4.o Middlewares/Third_Party/FreeRTOS/Source/queue.o Middlewares/Third_Party/FreeRTOS/Source/tasks.o Middlewares/Third_Party/FreeRTOS/Source/timers.o Src/arm_fir_f32.o Src/arm_fir_fast_q15.o Src/arm_fir_init_f32.o Src/arm_fir_init_q15.o Src/arm_fir_interpolate_init_q15.o Src/arm_fir_interpolate_q15.o Src/arm_offset_q15.o Src/arm_q15_to_float.o Src/freertos.o Src/main.o Src/stm32l4xx_hal_msp.o Src/stm32l4xx_hal_timebase_TIM.o Src/stm32l4xx_it.o Src/system_stm32l4xx.o TNC/AFSKModulator.o TNC/AFSKTestTone.o TNC/Afsk1200Demodulator.o TNC/AfskDemodulator.o TNC/AudioInput.o TNC/AudioLevel.o TNC/DCD.o TNC/Demodulator.o TNC/FilterCoefficients.o TNC/Fsk9600Demodulator.o TNC/Fsk9600Modulator.o TNC/Goertzel.o TNC/Golay24.o TNC/HdlcDecoder.o TNC/HdlcFrame.o TNC/IOEventTask.o TNC/Kiss.o TNC/KissHardware.o TNC/KissTask.o TNC/LEDIndicator.o TNC/Log.o TNC/M17.o TNC/M17Demodulator.o TNC/M17Encoder.o TNC/M17Modulator.o TNC/ModulatorTask.o TNC/NullPort.o TNC/PortInterface.o TNC/SerialPort.o newlib/_exit.o newlib/_sbrk.o newlib/_syscalls.o startup/startup_stm32l432xx.o 

All of the macros defined on the compiler line are important in order to properly build the firmware.

Installing firmware

Firmware can be installed via the storage interface (drag & drop), the on-board ST/LINK port, or via USB DFU.

Drag & Drop

For the NucleoTNC, the easiest way to install firmware is to copy the firmware file to the TNC directly. The NucleoTNC will show up as a storage device when plugged in. Just copy the firmware.bin file into the shared folder. The firmware will automatically install, the NucleoTNC will reset, and the new firmware will be running.

ST/Link

The ST/Link port is a debug port exposed by the NucleoTNC. It can be used by Eclipse and other IDEs to directly upload the firmware to the TNC.

USB DFU

  1. Download the STM32CubeProgrammer. https://s3.amazonaws.com/mobilinkd/en.stm32cubeprog-1.4.0.zip This programmer will work on Linux, OS X, and Windows.

  2. Download the ELF file from the release (or that you have built from source).

  3. Run the STM32CubeProgrammer from the command-line. (Replace "firmware.elf" with the appropriate firmware filename.)

    ./STM32_Programmer_CLI -c port=USB1 -d firmware.elf -v -g 0x8000000

  4. When that is complete, the NucleoTNC will restart with the new firmware.


Important Note

If you regenerate the STM32 code, please note that the LL ADC driver in the 1.12.0 version of the HAL driver is buggy.

Drivers/STM32L4xx_HAL_Driver/Inc/stm32l4xx_ll_adc.h

This file has been modified to address the defect. If it is replaced by STM32CubeMX, please ensure that the defect has been fixed.

Details of the defect are available [on the ST community site](https://community.st.com/s/question/0D50X00009bLP0eSAG/adc-init-bug-with-optimization-o1-stm32l4 ADC init bug with optimization >= -O1).


TNC Build Instructions

Please go here: TNC Build Instructions

Parts

54
QtyValueFootprintReferences
6R470Resistor_THT:R_Axial_DIN0207_L6.3mm_D2.5mm_P7.62mm_HorizontalR2, R3, R19, R20, R21, R22
4MountingHoleMountingHole:MountingHole_3.2mm_M3_ISO14580_PadH1, H2, H3, H4
3100KResistor_THT:R_Axial_DIN0207_L6.3mm_D2.5mm_P7.62mm_HorizontalR5, R9, R11
32K2Resistor_THT:R_Axial_DIN0207_L6.3mm_D2.5mm_P7.62mm_HorizontalR4, R17, R18
20.1uFCapacitor_THT:C_Disc_D3.4mm_W2.1mm_P2.50mmC10, C11
216KResistor_THT:R_Axial_DIN0207_L6.3mm_D2.5mm_P7.62mm_HorizontalR10, R15
21nFCapacitor_THT:C_Disc_D6.0mm_W2.5mm_P5.00mmC6, C7
21uFCapacitor_THT:C_Disc_D6.0mm_W2.5mm_P5.00mmC1, C12
2220Resistor_THT:R_Axial_DIN0207_L6.3mm_D2.5mm_P7.62mm_HorizontalR6, R13
22N7000Package_TO_SOT_THT:TO-92_InlineQ1, Q2
230KResistor_THT:R_Axial_DIN0207_L6.3mm_D2.5mm_P7.62mm_HorizontalR7, R16
233nFCapacitor_THT:C_Disc_D6.0mm_W2.5mm_P5.00mmC5, C8
2470pFCapacitor_THT:C_Disc_D6.0mm_W2.5mm_P5.00mmC4, C9
2510Resistor_THT:R_Axial_DIN0207_L6.3mm_D2.5mm_P7.62mm_HorizontalR12, R14
2BAT85Diode_THT:D_DO-35_SOD27_P7.62mm_HorizontalD1, D2
110KResistor_THT:R_Axial_DIN0207_L6.3mm_D2.5mm_P7.62mm_HorizontalR1
110nFCapacitor_THT:C_Disc_D6.0mm_W2.5mm_P5.00mmC3
110uFCapacitor_THT:C_Disc_D6.0mm_W2.5mm_P5.00mmC13
12.2uFCapacitor_THT:C_Disc_D6.0mm_W2.5mm_P5.00mmC2
124LC32Package_DIP:DIP-8_W7.62mm_SocketU2
16K8Resistor_THT:R_Axial_DIN0207_L6.3mm_D2.5mm_P7.62mm_HorizontalR8
1AuxLED_THT:LED_D3.0mm_Horizontal_O3.81mm_Z2.0mmD6
1BLU LEDLED_THT:LED_D3.0mm_Horizontal_O3.81mm_Z2.0mmD5
1DCDLED_THT:LED_D3.0mm_Horizontal_O3.81mm_Z2.0mmD3
1LOGOKiCAD:LOGOG1
1MCP6004Package_DIP:DIP-14_W7.62mm_SocketU1
1NUCLEO-L432KCKiCAD:MODULE_NUCLEO-L432KCA1
1PTS645VL58-2 LFSButton_Switch_THT:SW_Tactile_SPST_Angled_PTS645Vx58-2LFSSW1
1SJ-43515TSKiCAD:CUI_SJ-43515TSJ1
1TXLED_THT:LED_D3.0mm_Horizontal_O3.81mm_Z2.0mmD4

The 53 most common of 54 parts.

Similar boards

  • 2 layers64 × 56.5 mmGEQ1 AusfB R3, the printed circuit board in 3D

    GEQ1 AusfB R3

    GiesbrechtElectronics/GEQ1

    Schematics, PCBs, BOM, etc for GEQ-1 Pocket Equalizer

    101 partsMIT
  • 2 layers66 × 99 mmNucleo32TNC, the printed circuit board in 3D

    Nucleo32TNC

    mobilinkd/NucleoTNC-KiCAD

    KiCAD files for NucleoTNC PCB and Enclosure

    54 parts5CERN-OHL-S-2.0
  • 2 layers144.1 × 181.4 mmQuadulator, the printed circuit board in 3D

    Quadulator

    GlobalSequence/quadulator

    Quadulator - A quad LFO/ADSR envelope generator for Eurorack synthesizers

    128 parts6
  • 2 layers100 × 100 mmEmg, the printed circuit board in 3D

    Emg

    Pai-88/emg-robotic-hand

    Single-channel surface-EMG front end (AD623 + driven-right-leg) on a Raspberry Pi Pico. Board fabricated and telemetry verified on hardware; analog front end and on-body EMG still in bring-up.

    40 parts1MIT
  • 2 layers63.5 × 63.5 mmMain pcb, the printed circuit board in 3D

    Main pcb

    peterkrull/quad

    Firmware, hardware and documentation for my autonomous quad copter project

    45 parts210GPL-3.0
  • 2 layers94.5 × 74.4 mmAx58100-stm32-ethercat, the printed circuit board in 3D

    Ax58100-stm32-ethercat

    MetalMusings/MyOwnEtherCATDevice

    Documentation accompanying the "Make My Own EtherCAT device" video serie on Youtube.

    184 parts93
  • 2 layers100 × 66.1 mmPicoWiFiModem, the printed circuit board in 3D

    PicoWiFiModem

    mecparts/PicoWiFiModem

    A Pico W based RS232 <-> WiFi modem with Hayes AT style commands and LED indicators

    39 parts64GPL-3.0
  • 2 layers32.1 × 41.2 mmIr signalgen lite, the printed circuit board in 3D

    Ir signalgen lite

    dilshan/ir-clone

    Open-source infrared remote control signal analysis and generating tool

    40 parts58MIT

Questions

How big is the Nucleo32TNC PCB?

It measures 66 × 99 mm and has 2 copper layers, 1.6 mm thick.

What parts does the Nucleo32TNC use?

54 parts, built around the MCP6004-E/P, 24LC32A/P, BAT85 and SJ-43515TS. The full list of its parts is on this page, with links to each part's symbol and footprint where PCBKit's library has them.

Where can I download the Nucleo32TNC KiCad files?

From the mobilinkd/NucleoTNC repository on GitHub, at the commit this page was made from: the board is PCB/KiCAD/Nucleo32TNC.kicad_pcb. PCBKit opens the board in the browser, with nothing to install.

Can I use the Nucleo32TNC design in my own project?

Its repository publishes it under the GPL-3.0 licence: you may reuse it on that licence's terms (keep the author's notice, and for a copyleft licence share your changes alike).