Any hope for f-strings on SAMD21 processors?

CircuitPython on hardware including Adafruit's boards, and CircuitPython libraries using Blinka on host computers.

Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.
Locked
User avatar
rickrump
 
Posts: 77
Joined: Sat Jan 16, 2010 1:54 pm

Any hope for f-strings on SAMD21 processors?

Post by rickrump »

Could someone explain what is special about the SAMD21 chip that prevents CircuitPython from supporting f-strings on it?

Any hope for the future?

Thanks,

Rick

User avatar
mikeysklar
 
Posts: 9547
Joined: Mon Aug 01, 2016 8:10 pm

Re: Any hope for f-strings on SAMD21 processors?

Post by mikeysklar »

Rick,

I don't know why the SAMD21 has been excluded from CircuitPython f-strings.

Would it be an option for your to utilize an nRF52840 or ESP32* based board where it is supported?

https://github.com/adafruit/circuitpython/issues/4723

User avatar
alpierce
 
Posts: 157
Joined: Mon May 13, 2013 2:44 am

Re: Any hope for f-strings on SAMD21 processors?

Post by alpierce »

I have been able to use fstrings on a Feather M0 Express. Maybe not available on non Express boards due to memory limitations?

User avatar
tannewt
 
Posts: 3051
Joined: Thu Oct 06, 2016 8:48 pm

Re: Any hope for f-strings on SAMD21 processors?

Post by tannewt »

The SAMD21 has limited flash space for including new features in CircuitPython. The non-Express versions are extra crunched because 64k of the flash is used for the file system.

User avatar
rickrump
 
Posts: 77
Joined: Sat Jan 16, 2010 1:54 pm

Re: Any hope for f-strings on SAMD21 processors?

Post by rickrump »

Thank you all for your comments. Time to move away from SAMD21 processors for future projects. But I have three FeatherWings in the Feather M0 based project I have been refining for several years. I was hoping to migrate from Arduino code to CircuitPython, but based on your comments I will keep that project as is and suffer with Arduino code. Any new projects I will source a processor with much more flash for hopefully be more future-proof to run CircuitPython.

Thanks again!

Rick

User avatar
tannewt
 
Posts: 3051
Joined: Thu Oct 06, 2016 8:48 pm

Re: Any hope for f-strings on SAMD21 processors?

Post by tannewt »

If you really really need f-strings, then you could build your own CircuitPython with it included. You will have to turn off other features that you aren't using though.

Build instructions are here: https://learn.adafruit.com/building-circuitpython

User avatar
rickrump
 
Posts: 77
Joined: Sat Jan 16, 2010 1:54 pm

Re: Any hope for f-strings on SAMD21 processors?

Post by rickrump »

Thanks! Good idea!

Locked
Please be positive and constructive with your questions and comments.

Return to “Adafruit CircuitPython”