Poll
Question: Why fonts bigger than 6x13 crash the communication?
No idea. - 0 (0%)
Me neither - 0 (0%)
Same for me - 0 (0%)
Total Voters: 0

Pages: [1]   Go Down
Author Topic: DOGM128 - printed values not updated  (Read 397 times)
0 Members and 1 Guest are viewing this topic.
Offline Offline
Newbie
*
Karma: 0
Posts: 2
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hello
I have some issues regarding the library dogm128:
1) fonts bigger than 6x13 crash the communication between Processing and Arduino board, I need a reboot of the computer.
2) For some obscure reasons, printed values are not updated. I need to put them on a specific location (1st line) to have the expected value.
I didn't found any discussion about it on that forum and on the dogm128 site (http://code.google.com/p/dogm128/wiki/dogm128_arduino_shield)
Many thanks for your help

* BMP085_output.pde (9.19 KB - downloaded 2 times.)

* 00007.mov (122.37 KB, 11x123 - viewed 18 times.)
* BMP085_output.pde (9.19 KB - downloaded 3 times.)
Logged

Germany
Offline Offline
Edison Member
*
Karma: 100
Posts: 1217
If you believe something is right, you won't see what's wrong (David Straker).
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hi

Code:
void loop(void) {

dps.getTemperature(&Temperature);
dps.getPressure(&Pressure);
dps.getAltitude(&Altitude);
do{
  // The following part sould be done during the setup, but if I do so only the "pressure"
  // is displayed
  dogm.setFont(font_4x6);
  dogm.setXY(0,18);

The dogm.start() is missing just before the "do {"
The "picture" loop is fixed and has always the same structure:
Code:
  dogm.start();
  do {
    drawScreen();
  } while( dogm.next() );
The name ".start()" refers to the start of the picture loop, which starts the update of the screen.
This loop must be located in the "loop()" procedure. It does not make much sense to put it into the "setup()" part of the Arduino program.
I would also strongly recommend to put all graphics output to the dogm library into a separate procedure (e.g. drawScreen()).

Some fonts might crash (upload fails) on the MEGA2560 because of the "!!!" issue. This an issue of your bootloader, not an issue of the dogm128 library. The fonts 7x13, 7x14 and 8x16 do contain the binary code of !!! and will fail (http://code.google.com/p/arduino/issues/detail?id=392&can=1&q=2560).

Oliver


Logged

Offline Offline
Newbie
*
Karma: 0
Posts: 2
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Tank you very much Oliver.

I put the dogm.start() just before the "do {" and the sketch work as expected.
Didn't understood why, but it work !
Concerning the fonts that fail the upload, I will try to reflash the bootloader, but for now I don't have a programmer.

Regards
Logged

Pages: [1]   Go Up
Jump to: