Hi!
This is my first attempt into the Midibox world.
I have been working with displays for a long time, I really love it, I’m a ‘display addicted’ ;D
You can see some photos of my ‘babies’ here: http://www.modtv.com.br/mr_kholl/kholl_displays.htm
(Noritake’s Dot Matrix VFD 258x128 and 128x32, Blue HD44780’s 20x4 and 8x2, Blue T6963’s 240x128 and Planar’s EL 240x128 (my favourite)
I have plans to build a LC project, and since it’s my first Midibox project, i decided to use two 40x2 Character VFD’s, so, next time I will try to use dot matrix displays.
You can see the two VFD’s inside the red mark (PS: All images are thumbnails.).
According to Noritake, the U-Series is a LCD drop replacement, it means that you can replace your lcd for this vfd without any changes in your code. In fact it’s works well, the functions are quite compatible.
Well, I made the wiring for the core module and did the first test:
Ops…something is wrong (note the weird spacing):
LCD Sendmessage in MIOS Studio:
“Testing MIDIBOX”
“ABCDEFGHIJKLMNOPQRSTUVWXYZ”
I decided to made the wiring for the PC Parallel port just to test if the VFD is a really true replacement.
Well, started Smartie, picked the HD44780 driver, and voilá, worked perfectly! (including animations), note that it ran without any special config, just plug and play.
I have been talking with SmashTV, jimp, ultra, fossi.bs, SoundDuke, seppoman (sorry if i forgot someone) about this problem in the chat, and I would like to thank them very much for the support!
After several suggestions I did the tests below:
1. Core assembly Check:
Ok
2. LCD wiring Check:
Ok
3. CPU mode Check:
8bit mode as well
4. LCD Init sequence Check:
It’s Original LCD Init code from mios_clcd.inc
movlw 0x08 ; Display Off
rcall MIOS_CLCD_Cmd
movlw 0x0c ; Display On
rcall MIOS_CLCD_Cmd
movlw 0x06 ; Entry Mode
rcall MIOS_CLCD_Cmd
movlw 0x01 ; Clear Display
call MIOS_CLCD_Cmd
bcf MIOS_LCD_TIMEOUT1, 7, BANKED ; everything ok, make sure that LCD_TIMEOUT, bit 7 is cleared
movlw 0x38 ; select 8-bit interface again
BIFSET MIOS_CLCD_PIN_E, 7, BANKED, movlw 0x28 ; select 4-bit interface again
rcall MIOS_CLCD_Cmd
movlw 0x0c
rcall MIOS_CLCD_Cmd
movlw 0x00 ; set cursor to zero pos
rgoto MIOS_CLCD_CursorSet
According to a doc from Noritake it’s the suggested Init procedure: So, I changed the original code and recompiled the MIOS:
movlw 260 ; 260 ms delay
call MIOS_Delay
movlw 0x38 ; select 8-bit interface again
rcall MIOS_CLCD_Cmd
movlw 0x38 ; select 8-bit interface again
rcall MIOS_CLCD_Cmd
movlw 0x02 ; brightness 50%
rcall MIOS_CLCD_Data
movlw 0x08 ; Display Off
rcall MIOS_CLCD_Cmd
movlw 0x01 ; Clear Display
call MIOS_CLCD_Cmd
movlw 2 ; 2 ms delay
call MIOS_Delay
movlw 0x0c ; Display On
rcall MIOS_CLCD_Cmd
movlw 0x06 ; Entry Mode
rcall MIOS_CLCD_Cmd
Guess what?? nothing happened, still same spacing problem, note that it’s my first try in MIOS, so I changed the brightness param to 50% just to check if I was changing in the correct place, in fact, the brightness param worked! 5. _ lcd_interconnections_test_v1 _ application Test: Pins about 4.58v 6. _ lcd_benchmark _ application Test: Result:
565 * 8 * 100ns
or
565? * 8 * 100ns
PS: the values wasn’t clear because the position/spacing problem.
- PrintChar test (One character per time):
I filled the grid with a sequence of PrintChar command, from ‘A’ to ‘Z’ character using 1ms and 400ms of delay…the result is still weird!
Checkout the videos:
400ms:
http://www.youtube.com/watch?v=7zf4Xy0EIss
1ms:
http://www.youtube.com/watch?v=4Dpj_ZRMtEk
…
Any help?
Thanks a lot!
Kholl.