tinygo icon indicating copy to clipboard operation
tinygo copied to clipboard

Troubles getting Pro Micro to run

Open JuLi0n21 opened this issue 7 months ago • 2 comments

Hello TinyGo team,

Im currently struggling getting this Pro Micro to run. (datasheet)

I managed to flash to the mcu using the arduino-leonardo configuration but it seems to be doing nothing at all.

i started with a blinky script migrated from code written in arduino IDE, which also detects the board as arduino-leonardo.

i saw and experienced the same issue described in this issue

tinygo code:

package main

import (
	"machine"
	"time"
)

func main() {
	rxLed := machine.Pin(17)
	txLed := machine.Pin(30)

	rxLed.Configure(machine.PinConfig{Mode: machine.PinOutput})
	txLed.Configure(machine.PinConfig{Mode: machine.PinOutput})

	for {
		rxLed.High()
		txLed.Low()
		time.Sleep(300 * time.Millisecond)

		rxLed.Low()
		txLed.High()
		time.Sleep(300 * time.Millisecond)
	}
}

original arduino code:

int RXLED = 17; 
int TXLED = 30; 

void setup() {
  
  pinMode(RXLED, OUTPUT);
  pinMode(TXLED, OUTPUT);
}

void loop() {
  digitalWrite(RXLED, HIGH);
  digitalWrite(TXLED, LOW);
  delay(300);
  digitalWrite(RXLED, LOW);
  digitalWrite(TXLED, HIGH);
  delay(300);
}

flash command: tinygo flash -target arduino-leonardo -no-debug main.go

i would be willing to create the missing pieces but i honestly dont even know where to start

JuLi0n21 avatar May 10 '25 11:05 JuLi0n21

@jespino How was this part when you were developing it? It seems that writing to the atmega32u4 on an arduino-leonardo removes the USBCDC, making recovery difficult.

sago35 avatar May 11 '25 23:05 sago35

I also found this where some more differences are noted, cant confirm its the actual same board since their seems to be many different version of the board

JuLi0n21 avatar May 12 '25 15:05 JuLi0n21