I have now used the #include <SoftwareSerial.h> with this ini file on platformIO
To make it work I load code over usb interface then switch to USB to ttl dongle and read rx tx over serial monitor.
I would like to use //#include <DigiCDC.h> //serial monitor
But this one i cant get to work. Does not detect com port
[env:attiny88]
platform = atmelavr
board = attiny88
framework = arduino
board_build.f_cpu = 16000000L
build_flags = -DCLOCK_SOURCE=18 -Wno-narrowing
upload_protocol = micronucleus
lib_deps =
featherfly/SoftwareSerial@^1.0
Code:
// this works, must use USB to ttl adapter and tx is Rx on the out and inpins
const byte rxPin = 3 ; // RX is D3 - on TTL it is TX
const byte txPin = 4 ; // TX is D4 - on TTL it is RX
SoftwareSerial mySerial(rxPin, txPin);
void setup() {
pinMode(rxPin, INPUT);
pinMode(txPin, OUTPUT);
mySerial.begin(9600);
mySerial.println("Initializing...");
}
void loop (){
mySerial.println("Test\n");
delay(1000);
}