Forum - MCS Electronics

 

FAQFAQ SearchSearch RegisterRegister Log inLog in

EA DOGM204 nice 20x4 ultraslim display

 
Post new topic   Reply to topic    www.mcselec.com Forum Index -> Share your working BASCOM-AVR code here
View previous topic :: View next topic  
Author Message
EDC

Bascom Expert



Joined: 26 Mar 2014
Posts: 621

poland.gif
PostPosted: Mon Nov 04, 2019 4:55 pm    Post subject: EA DOGM204 nice 20x4 ultraslim display Reply with quote

Hello. I got such a display Very Happy
It is :
* extremely compact at 66 x 40 mm at the standard font size of 4.8 mm (4 x 10)
* ultra-flat at 2.0 mm without backlight or 5.8 mm including LED backlight
* 4-bit, 8-bit, SPI interface (2-/3-/4-wire) and IC (2-wire)
* typical power consumption of only 250A in full operation (LED white backlight as of 3mA)
* easy installation by simply soldering into the board
* A whole range of design variants can be supplied as of single units
* Changing background color

Unfortunatelly I dont have backlight yet so first Im using flashlight and then some Rainbowled`s Very Happy
Backlight will arrive soon I think.

I have modified "4_anypin.lib" with some needed initialisation, and then anyone can use Bascom`s dedicated functions like Lcd and Locate.

Remember to choose 20x4A because adressess for rows are &H00, &H20, &H40 and $H60

Library and datasheet attached.
Tested on the 3V3 circuit. Not tested with Xmega but oryginally "4_anypin.lib" support Xmega so it should work.



Code:
$regfile = "m1284def.dat"
$crystal = 16000000
$hwstack = 64
$swstack = 16
$framesize = 64
Config Submode = New

$lib "EADOGM204_4_anypin.lib"                               'four bits

Config Lcdpin = Pin , Rs = Porta.0 , E = Porta.1 , Db4 = Porta.4 , Db5 = Porta.5 , Db6 = Porta.6 , Db7 = Porta.7
Config Lcd = 20x4a                                          ' <<< A is important!

Lcdreset Alias Porta.2 : Set Lcdreset : Config Lcdreset = Output       'set HI

Macro Resetlcd
 Lcdreset = 0
 Waitms 10
 Lcdreset = 1
 Waitms 1
End Macro

Resetlcd : Initlcd : Cls

Locate 1 , 1 : Lcd "Hello World"
Locate 2 , 1 : Lcd " EADOGM204A"
Locate 3 , 1 : Lcd " BASCOM"
Locate 4 , 1 : Lcd "EDC"

End
Back to top
View user's profile Visit poster's website
albertsm

Administrator



Joined: 09 Apr 2004
Posts: 4824
Location: Holland

blank.gif
PostPosted: Tue Nov 05, 2019 9:32 pm    Post subject: Reply with quote

Hi EDC

Thanks for sharing. Indeed a nice LCD.
I see you use side lighting Smile

I used similar lcd. contrast is great.

thanks for taking the time to share!

_________________
Mark
Back to top
View user's profile Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic    www.mcselec.com Forum Index -> Share your working BASCOM-AVR code here 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