Skip to content
/ hd-mcu Public

bluetooth supported mcu for harley davidson 99-03 with raspberry pi pico

License

Notifications You must be signed in to change notification settings

ozgend/hd-mcu

Repository files navigation

hd-mcu

bluetooth supported mcu for harley davidson 99-03 with raspberry pi pico

this is not a ecu but a diy -and for fun- project for a monitoring hardware via an mcu since there is no can-bus support for 99-03 models. it replaces the default turn signal module (tsm) to provide monitoring features for battery voltage, rpm, voes, ignition, and external thermo sensors via bluetooth to the mobile application. it does not involve a reverse engineering for the original hd-tsm module.

  • programmable idle timeout for turn signal
  • pcb provides signal switching via h-bridge module or mosfet + oc
  • built-in battery voltage sensor
  • built-in rpm reader
  • built-in temperature sensor via rpi-pico
  • aux inputs for ignition and voes signals (may require custom ignition module ie. ultima/dyna 2000i)
  • vehicle information with editable fields for maintenance records
  • external 6x thermocpouler raiser for max6670
  • supports up to 8x thermocpouler sensors for various purposes

icon

supported features

  • hardware serial
    • raw ft232 usb serial
  • bluetooth serial
    • raw bluetooth serial (hc-06 @ 9600 bps)
    • mobile app
  • obd2/canbus - for 2004+ models
    • available pids
  • polling/broadcasting
    • reduced power consumption
    • reduced cpu clock usage
  • turn signal flasher module
    • left/right turn signal flasher
    • hazard flasher
    • flash on startup
    • adjustable flash rate
  • supported sensor inputs
    • multiplexed thermocouples
      • up to 8 thermocouples
    • direct sensor inputs
      • uptime counter (onboard)
      • voltage sensor (onboard)
      • temperature sensor (onboard)
      • rpm sensor (optional)
      • speed sensor (optional)
      • aux *2 (optional, ignition, voes ...etc)
    • tpms
      • 433mhz receiver implementation
      • tpms decoder / man-i or man-ii (tbd)

software

mobile app

  • platform

    • react 18.2.0
    • react-native: 0.73.2
  • react-native

    • android
    • ios

mobile app ui

back

mcu firmware

hardware

main tsm assembly

  • 12v-5v buck converter / switching regulator
  • raspberry pi pico
  • hc-06 bluetooth module
  • tsm - (option-1) - with mosfet extension board
  • tsm - (option-2) - l298n h-bridge driver module
  • 5v super capacitor
  • 5805 voltage regulator
  • 33k resistor
  • 10k resistor
  • 7.5k resistor
  • 4.7k resistor
  • 1k resistor
  • 1n4001 diode

thermocouple sensors (optional)

it would be good to monitor oil temperature as well as both cylinder combustion and exhausts output temperature. (x5)

  • cd4051 multiplexer
  • max6675 thermocouple digitizer
    • datasheet
    • k-type thermocouple (maximum of 8)
  • use raiser module for up to 6x thermocouples

pcb

front front

back back

blueprint raw

setup & building & installing

  • initialization

    git clone
    npm run install
  • cook everything

    npm run build
  • create mcu firmware

    npm build:mcu
  • flash firmware to pico

    npm run flash:mcu -- /dev/tty.usbmodem2XXX
  • create mobile app

    • create local build

      npm run build:app
    • create distributable bundle .apk

      nom run bundle:app