Forum - MCS Electronics

 

FAQFAQ SearchSearch RegisterRegister Log inLog in

Display 3000 2.1"

 
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    www.mcselec.com Forum Index -> BASCOM-AVR Archive
View previous topic :: View next topic  
Author Message
Duval JP

Bascom Member



Joined: 22 Jun 2004
Posts: 1198
Location: France

france.gif
PostPosted: Thu Jan 17, 2008 7:25 pm    Post subject: Display 3000 2.1" Reply with quote

hello,
I discover the Display3000, it nice but I have a problem, the line is difficult to draw, I have a solution but it is a little bit heavy: draw dot by dot.

I explain to draw a line the X1, Y1 coordinate must be in the upper left corner, and the X2, Y2 in the lower right corner.

My problem is to make an analogic clock so I need to have the center of circle X1, Y1 and I dont find the method to draw the line for 7 hours for example

Bascom 9.0, atmega128
Many thanks

JP
Back to top
View user's profile Visit poster's website
AdrianJ

Bascom Expert



Joined: 16 Jan 2006
Posts: 2483
Location: Queensland

australia.gif
PostPosted: Thu Jan 17, 2008 10:05 pm    Post subject: Reply with quote

In fact all lines are drawn dot-by-dot, you just need a good way of figuring out where the dots go. Lookup "Bresenham algorithm" on the net. This is the standard line drawing technique.
_________________
Adrian Jansen
Computer language is a framework for creativity
Back to top
View user's profile Visit poster's website
Arera

Bascom Member



Joined: 23 Sep 2007
Posts: 386
Location: Wuppertal, Germany

germany.gif
PostPosted: Fri Feb 29, 2008 12:21 pm    Post subject: Reply with quote

Hi JP,

I using a D072 2.1" display since monday. Itīs great!
Why donīt you use the commands from display3000?
Include a few .bas files from display3000 into your prog, and draw a line:

call ldc_draw (x1,y1, x2,y2, [thickness], [color])

Read the display3000 software-manual!
Back to top
View user's profile
Display posts from previous:   
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    www.mcselec.com Forum Index -> BASCOM-AVR Archive All times are GMT + 1 Hour
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You cannot download files in this forum