Where/how can I find compile options for me attiny cores?

I want to program a brand new AT1616. I let JLCPCB assembly a 10x15mm pcb for me.

Currently I can build but the maximum size is 32kb acording to arduino-cli so: Conclusion I must set the cpu: parameter correctly. I completely forgot what to type in CLI to find me the correct syntax and avaiable core options and all.

Ofcourse being a bit crafty, I figured to open up the IDE and put it in verbose mode. So in no time I got me.

megaTinyCore:megaavr:atxy6:chip=1616,
clock=20internal,
bodvoltage=1v8,
bodmode=disabled,
eesave=enable,millis=enabled,
resetpin=UPDI,
startuptime=8,
wiremode=mors,
printf=default,
PWMmux=A_default,
attach=allenabled,
WDTtimeout=disabled,
WDTwindow=disabled

So I compile with these settings and it seem to work.

However I would like to know what to type in CLI to find me these options. So I dont have to use the IDE :see_no_evil:

Secondly: which of these can I leave out? I do want to make use of micros()

Kind regards :coffee:

Bas

Can't you just export the compiled binary in the IDE and then upload it with a separate command outside of the IDE?

e.g. I am using AVRDUDESS for the upload

I do al work in VS Code. This includes compiling and uploading using arduino-CLI. Just one press on F6 :smiley: With atmega's it is really simple because you don't have to set any arguments at al. You just specify that you are using a nano or uno and you're good.

If I start a new project, I always use a python script which assembles a folder for me. This includes certain default files I want to use as well as locally copied libraries I can pick. The script also assembles me build.py and upload.py. But obviously this does not work yet for attinies.

I only use the IDE to reverse engineer me things like attiny build scripits. I also still use the board manager to install cores n all. But I need to start learning me to go full CLI.

Bas

Use the arduino-cli board details command:

$ arduino-cli board details --fqbn megaTinyCore:megaavr:atxy6

Board name:                ATtiny3226/3216/1626/1616/1606/826/816/806/426/416/406                                       
FQBN:                      megaTinyCore:megaavr:atxy6                                                                   
Board version:             2.6.8                                                                                        

Identification properties: board=atxy6                                                                                  

Package name:              megaTinyCore                                                                                 
Package maintainer:        Spence Konde                                                                                 
Package URL:               http://drazzy.com/package_drazzy.com_index.json                                              
Package website:           https://github.com/SpenceKonde/megaTinyCore                                                  

Platform name:             megaTinyCore                                                                                 
Platform category:         Contributed                                                                                  
Platform architecture:     megaavr                                                                                      
Platform URL:              https://SpenceKonde.github.io/megaTinyCore/megaTinyCore-2.6.8.tar.bz2                        
Platform file name:        megaTinyCore-2.6.8.tar.bz2                                                                   
Platform size (bytes):     827571                                                                                       
Platform checksum:         SHA-256:33c6c68f5f5dfff1de02113c968ad08dabc2cedddd78b1f9b004d91e0183de9f                     

Required tool: DxCore:avr-gcc                                                         7.3.0-atmel3.6.1-azduino6                                                                                                  
Required tool: DxCore:avrdude                                                         6.3.0-arduino17or18                                                                                                        
Required tool: arduino:arduinoOTA                                                     1.3.0                                                                                                                      
Required tool: megaTinyCore:python3                                                   3.7.2-post1                                                                                                                

Option:        Chip                                                                                                                                                                                               chip                 
               ATtiny3226                                                             ✔                                                                                                                           chip=3226            
               ATtiny3216                                                                                                                                                                                         chip=3216            
               ATtiny1626                                                                                                                                                                                         chip=1626            
               ATtiny1616                                                                                                                                                                                         chip=1616            
               ATtiny1606                                                                                                                                                                                         chip=1606            
               ATtiny826                                                                                                                                                                                          chip=826             
               ATtiny816                                                                                                                                                                                          chip=816             
               ATtiny806                                                                                                                                                                                          chip=806             
               ATtiny426                                                                                                                                                                                          chip=426             
               ATtiny416                                                                                                                                                                                          chip=416             
               ATtiny406                                                                                                                                                                                          chip=406             
Option:        Clock                                                                                                                                                                                              clock                
               20 MHz internal                                                        ✔                                                                                                                           clock=20internal     
               16 MHz internal                                                                                                                                                                                    clock=16internal     
               10 MHz internal                                                                                                                                                                                    clock=10internal     
               8 MHz internal                                                                                                                                                                                     clock=8internal      
               5 MHz internal                                                                                                                                                                                     clock=5internal      
               4 MHz internal                                                                                                                                                                                     clock=4internal      
               2 MHz internal                                                                                                                                                                                     clock=2internal      
               1 MHz internal                                                                                                                                                                                     clock=1internal      
               20 MHz internal - tuned                                                                                                                                                                            clock=20internaltuned
               16 MHz internal - tuned                                                                                                                                                                            clock=16internaltuned
               12 MHz internal - tuned                                                                                                                                                                            clock=12internaltuned
               10 MHz internal - tuned                                                                                                                                                                            clock=10internaltuned
               8 MHz internal - tuned                                                                                                                                                                             clock=8internaltuned 
               6 MHz internal - tuned                                                                                                                                                                             clock=6internaltuned 
               5 MHz internal - tuned                                                                                                                                                                             clock=5internaltuned 
               4 MHz internal - tuned                                                                                                                                                                             clock=4internaltuned 
               1 MHz internal - tuned                                                                                                                                                                             clock=1internaltuned 
               20 MHz external clock                                                                                                                                                                              clock=20extclock     
               16 MHz external clock                                                                                                                                                                              clock=16extclock     
               12 MHz external clock                                                                                                                                                                              clock=12extclock     
               10 MHz external clock                                                                                                                                                                              clock=10extclock     
               8 MHz external clock                                                                                                                                                                               clock=8extclock      
               24 MHz internal - tuned, overclocked                                                                                                                                                               clock=24internaltuned
               25 MHz internal - tuned, overclocked                                                                                                                                                               clock=25internaltuned
               30 MHz internal - tuned, overclocked, may be unstable, req. 20 MHz fuse                                                                                                                             clock=30internaltuned
               32 MHz internal - tuned, 2-series, overclocked, may be unstable, req. 20 MHz fuse                                                                                                                             clock=32internaltuned
               24 MHz external clock - overclocked                                                                                                                                                                clock=24extclock     
               25 MHz external clock - overclocked                                                                                                                                                                clock=25extclock     
               30 MHz external clock - overclocked, may be unstable                                                                                                                                               clock=30extclock     
               32 MHz external clock - overclocked, may be unstable                                                                                                                                               clock=32extclock     
Option:        millis()/micros() Timer                                                                                                                                                                            millis               
               Enabled (default timer)                                                ✔                                                                                                                           millis=enabled       
               Disabled (saves flash)                                                                                                                                                                             millis=disabled      
               TCA0 (default on 0-series)                                                                                                                                                                         millis=timera        
               TCD0 (1-series only, default there)                                                                                                                                                                millis=timerd        
               TCB0 (breaks tone() and Servo)                                                                                                                                                                     millis=timerb0       
               TCB1 (3216, 1616, 2-series only)                                                                                                                                                                   millis=timerb1       
               RTC (no micros)                                                                                                                                                                                    millis=rtc           
               RTC w/w32.768 kHz ext. crystal (1/2-series only, no micros)                                                                                                                                        millis=rtcxtal       
               RTC w/w32.768 kHz ext. oscillator (1/2-series only, no micros)                                                                                                                                     millis=rtcxosc       
Option:        Startup Time                                                                                                                                                                                       startuptime          
               8ms                                                                    ✔                                                                                                                           startuptime=8        
               0ms                                                                                                                                                                                                startuptime=0        
               1ms                                                                                                                                                                                                startuptime=1        
               2ms                                                                                                                                                                                                startuptime=2        
               4ms                                                                                                                                                                                                startuptime=4        
               16ms                                                                                                                                                                                               startuptime=16       
               32ms                                                                                                                                                                                               startuptime=32       
               64ms                                                                                                                                                                                               startuptime=64       
Option:        BOD Voltage Level (burn bootloader req'd)                                                                                                                                                          bodvoltage           
               1.8V (5 MHz or less)                                                   ✔                                                                                                                           bodvoltage=1v8       
               2.6V (10 MHz or less)                                                                                                                                                                              bodvoltage=2v6       
               4.2V (20 MHZ or less)                                                                                                                                                                              bodvoltage=4v2       
               2.1V (Unofficial)                                                                                                                                                                                  bodvoltage=2v1       
               2.9V (Unofficial)                                                                                                                                                                                  bodvoltage=2v9       
               3.3V (Unofficial)                                                                                                                                                                                  bodvoltage=3v3       
               3.7V (Unofficial)                                                                                                                                                                                  bodvoltage=3v7       
               4.0V (Unofficial)                                                                                                                                                                                  bodvoltage=4v0       
Option:        BOD Mode when Active/Sleeping (burn bootloader req'd)                                                                                                                                              bodmode              
               Disabled/Disabled                                                      ✔                                                                                                                           bodmode=disabled     
               Enabled/Enabled                                                                                                                                                                                    bodmode=enabled      
               Enabled/Sampled (1 kHz)                                                                                                                                                                            bodmode=ensampfast   
               Enabled/Sampled (125 Hz)                                                                                                                                                                           bodmode=ensampslow   
               Sampled/Sampled (1 kHz)                                                                                                                                                                            bodmode=sampledfast  
               Sampled/Sampled (125 Hz)                                                                                                                                                                           bodmode=sampledslow  
               Sampled/Disabled (1 kHz)                                                                                                                                                                           bodmode=sampdisfast  
               Sampled/Disabled (125 Hz)                                                                                                                                                                          bodmode=sampdisslow  
               Enabled hold wakeup/Disabled                                                                                                                                                                       bodmode=endisholdwake
Option:        Save EEPROM (burn bootloader req'd)                                                                                                                                                                eesave               
               EEPROM retained                                                        ✔                                                                                                                           eesave=enable        
               EEPROM not retained                                                                                                                                                                                eesave=disable       
Option:        UPDI/Reset Pin Function (burn bootloader req'd)                                                                                                                                                    resetpin             
               UPDI (no reset pin)                                                    ✔                                                                                                                           resetpin=UPDI        
               UPDI w/reset on PB4 (2-series only)                                                                                                                                                                resetpin=UPDIaltrst  
Option:        printf()                                                                                                                                                                                           printf               
               Default (doesn't print floats, 1.4k flash use)                         ✔                                                                                                                           printf=default       
               Full, 2.6k, prints floats                                                                                                                                                                          printf=full          
               Minimal, 1.1k flash used                                                                                                                                                                           printf=minimal       
Option:        Wire (Wire.h/I2C) Library mode                                                                                                                                                                     wiremode             
               Master or Slave (saves flash and RAM)                                  ✔                                                                                                                           wiremode=mors        
               Master and Slave                                                                                                                                                                                   wiremode=mands       
Option:        WDT timeout (burn bootloader req'd. Cannot be disabled at runtime if set here)                                                                                                                             WDTtimeout           
               Disabled (recommended)                                                 ✔                                                                                                                           WDTtimeout=disabled  
               Window remains open for 8 Seconds                                                                                                                                                                  WDTtimeout=8seconds  
               Window remains open for 4 Seconds                                                                                                                                                                  WDTtimeout=4seconds  
               Window remains open for 2 Seconds                                                                                                                                                                  WDTtimeout=2seconds  
               Window remains open for 1 Second                                                                                                                                                                   WDTtimeout=1second   
               Window remains open for 500 milliseconds                                                                                                                                                           WDTtimeout=500msec   
               Window remains open for 250 milliseconds                                                                                                                                                           WDTtimeout=250msec   
               Window remains open for 125 milliseconds                                                                                                                                                           WDTtimeout=125msec   
Option:        WDT window (if desired. burn bootloader req'd. Cannot be disabled at runtime if set here)                                                                                                                             WDTwindow            
               No delay before window "opens"                                         ✔                                                                                                                           WDTwindow=disabled   
               8 Second before window "opens"                                                                                                                                                                     WDTwindow=8seconds   
               4 Second before window "opens"                                                                                                                                                                     WDTwindow=4seconds   
               2 Second before window "opens"                                                                                                                                                                     WDTwindow=2seconds   
               1 Second before window "opens"                                                                                                                                                                     WDTwindow=1second    
               500 millisecond before window "opens"                                                                                                                                                              WDTwindow=500msec    
               250 millisecond before window "opens"                                                                                                                                                              WDTwindow=250msec    
               125 millisecond before window "opens"                                                                                                                                                              WDTwindow=125msec    
               62.5 millisecond before window "opens"                                                                                                                                                             WDTwindow=63msec     
Option:        PWM pins (advanced, see core documentation)                                                                                                                                                        PWMmux               
               PB0-2, PA3-5, 1-series: PC0/1 (default)                                ✔                                                                                                                           PWMmux=A_default     
               PB0-2, PA3-5. No TCD PWM even on 1-series.                                                                                                                                                         PWMmux=default       
               PB0-2 (buffered), 1-series: PC0/1                                                                                                                                                                  PWMmux=A_buffered    
               PB0-2 (buffered), 1-series: PA4/5                                                                                                                                                                  PWMmux=D_buffered    
               PB0-2 (buffered). No TCD PWM even on 1-series.                                                                                                                                                     PWMmux=buffered      
               PB0,1,5, PA3-5, 1-series: PC0/1                                                                                                                                                                    PWMmux=U6_A          
               PB0,1,5, PA3-5. No TCD PWM even on 1-series.                                                                                                                                                       PWMmux=U6            
               PB0,1,5 (buffered), 1-series: PA4/5                                                                                                                                                                PWMmux=U3_D          
               PB0,1,5 (buffered), 1-series: PC0/1                                                                                                                                                                PWMmux=U3_A          
               PB0,1,5 (buffered). No TCD PWM even on 1-series.                                                                                                                                                   PWMmux=U3            
               PB3-5 PA3-5, 1-series: PC0/1                                                                                                                                                                       PWMmux=I6_A          
               PB3-5, PA3-5. No TCD PWM even on 1-series.                                                                                                                                                         PWMmux=I6            
               PB3-5 (buffered), 1-series: PA4/5                                                                                                                                                                  PWMmux=I3_D          
               PB3-5 (buffered), 1-series: PC0/1                                                                                                                                                                  PWMmux=I3_A          
               PB3-5 (buffered). No TCD PWM even on 1-series.                                                                                                                                                     PWMmux=I3            
               PB3-5, PC3, PA4/5, 1-series: PC0/1                                                                                                                                                                 PWMmux=SC6_A         
               PB3-5, PC3, PA4/5. No TCD PWM even on 1-series.                                                                                                                                                    PWMmux=SC6           
Option:        attachInterrupt Mode                                                                                                                                                                               attach               
               On all pins, with new implementation.                                  ✔                                                                                                                           attach=allenabled    
               Only enabled ports                                                                                                                                                                                 attach=manual        
               Old version, (may fix bugs)                                                                                                                                                                        attach=oldversion    
Programmers:   ID                                                                     Name                                                                                                                       
               serialupdi                                                             SerialUPDI - 230400 baud                                                                                                   
               serialupdi460k                                                         SerialUPDI - FAST: 4.5v+ 460800 baud (CH340 - and maybe some others)                                                       
               medbg                                                                  Xplained Mini (mEDBG, debug chip: ATmega32u4)                                                                              
               nedbg                                                                  Curiosity Nano (nEDBG, debug chip: ATSAMD21E18)                                                                            
               edbg                                                                   Xplained Pro (EDBG, debug chip: AT32UC3A4256)                                                                              
               serialupdi57k                                                          SerialUPDI - SLOW: 57600 baud                                                                                              
               serialupdi921k_wd1                                                     SerialUPDI - TURBO: 4.5v+ 921600 baud w/write delay, (adapters that support it and are not CH340, many fall back to 115200)
               jtag2updi                                                              jtag2updi                                                                                                                  
               snap_updi                                                              MPLAB SNAP (UPDI mode)                                                                                                     
               pickit4_updi                                                           PICkit4 (UPDI mode)                                                                                                        
               atmelice_updi                                                          Atmel-ICE                                                                                                                  
               serialupdi921k                                                         SerialUPDI - TURBO: 4.5v+ 921600 baud (CH340 (and maybe some others) only)                                                 
               serialupdi230k_wd1                                                     SerialUPDI - 230400 baud w/write delay, 2.7V+ (Linux/MacOS: other adapters, Win: maybe some adapters)                      
               serialupdi460k_wd1                                                     SerialUPDI - FAST: 4.5v+ 460800 baud w/write delay (other non-CH340 adapters, often slower than 230k, esp. on Windows)     
1 Like

Great, thank you. This is the forgotton line I was looking for.

This :white_check_mark:marks also anwsers my 2nd question, what options must one set. :ok_hand:

Regards, :coffee:

Bas

You are welcome. I'm glad if I was able to be of assistance.

Regards,
Per

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.