• 0
jamesW

PMOD MTDS text font sizes

Question

Hi, I'd like to use different font sizes on the MTDS display. MtdsDefs.h defines a number of font sizes, but none of these, other than hfntConsole, seem to work.

Interestingly, two different errors occur when trying to render text using these fonts, depending on the font size selected.

The fonts hfntMedium, hfntLarge & hfntXLarge cause the display to go into a re-sync state. I had a look through the MTDS libs and it's MtdsWaitUntilShieldDone(), called by mtds.cpp, which times out and throws an lSyncError.

The fonts hfntXSmall & hfntSmall don't cause an error, but no text is rendered to the display.

Share this post


Link to post
Share on other sites

6 answers to this question

Recommended Posts

  • 0

Hi @jamesW,

Welcome to the Digilent Forums!

1) Please give more detail about the project set up. I.E.  Microcontroller or FPGA? 

2) Are you able to run the MtdsDemo1 which uses the fntMedium?

thank you,

Jon

Share this post


Link to post
Share on other sites
  • 0

Hi Jon, Thanks for the reply. See answers, below -

1) I have the display working with the FRDM-K64F microcontroller. All is functioning well and I have been able to implement everything I need, except changing the font size.

2) I have tried running MtdsDemo1 on an Arduino Uno (i.e. using the standard code in the Arduino IDE, downloaded from the Digilent website). Looking through this sketch, it looks like it only sets the font size to hfntMedium and does not attempt to render out any text using this font.

I looked at the return value from mtds.GetFont(hds) after setting the font to hfntMedium and it correctly returns 0xC3300003 (which, according to MtdsDefs.h, is the correct value). So, the Set/GetFont calls work fine - it's only when you try to render with these fonts that an error occurs. 

I've attached a shortened version of MtdsDemo1, where I've modified test21 (there are only two tests in this version - 1 & 21). Basically, it renders out some text using hfntConsole, then sets the font to hfntMedium and then tries to render this. Doing so causes the display to reset, as described in the original post.

 

 

MtdsDemo1_short.ino

Share this post


Link to post
Share on other sites
  • 0

Hi @jamesW,

In the  MTDS Library Programmer's Reference Manual found  here:  MTDS\Documentation in the section Font Objects it states that "Version 1 of the MTDS display device firmware only provides a single font, hfntConsole. Future versions of the system may provide additional built-in fonts and provide the ability to load fonts from files stored on the SD card.". Currently we do not have an ETA for the next version of  firmware for the MTDS.

thank you,

Jon

 

 

Share this post


Link to post
Share on other sites
  • 0
On 2/19/2019 at 3:05 PM, jpeyron said:

Hi @jamesW,

In the  MTDS Library Programmer's Reference Manual found  here:  MTDS\Documentation in the section Font Objects it states that "Version 1 of the MTDS display device firmware only provides a single font, hfntConsole. Future versions of the system may provide additional built-in fonts and provide the ability to load fonts from files stored on the SD card.". Currently we do not have an ETA for the next version of  firmware for the MTDS.

thank you,

Jon

 

 

Jon, I also have a need for different font sizes. It would be very nice to have this feature available as well as the ability to load custom fonts from the SD card. Thanks for considering this and let us know if it can be provided. BTW is there a way to easily update the MTDS firmware in the 2.8" MTDS? Thanks.

Jeff 

Share this post


Link to post
Share on other sites
  • 0

Hi @JeffJ,

Unfortunately we are not aware of an easy way to update the firmware. I will pass on your suggestion for different fonts to our content team.

best regards,

Jon

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now