Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - OS

Pages: [1]
1
OLEDs / Re: NHD-0220CW-AG3 Character set
« on: March 28, 2017, 07:15:05 AM »
Hi again.
Luckily I found my mistake why I could not write data to CGRAM.
In the function data_write() the RW signal was wrong, RW_HIGH should be RW_LOW.  ::)


Unfortunately we really need to set more than 8 individual characters, minimum 13 chars.

Is there a possibility to get a display with a modified software (modified font set)?

Best regards.
OS

2
OLEDs / NHD-0220CW-AG3 Character set
« on: March 28, 2017, 02:49:57 AM »
Hello.
We are using a NHD-0220CW-AG3 (in 4-bit Parallel 6800 interface) with the character set of ROM C.
Is it possible to overwrite the first 8 character of ROM C to add individual character?

I tried it in this way, but did not succeed. I only got strange signs on the display.

Code: [Select]

void data_write (uchar c)
{//high byte
  PORTA = (c & 0xF0);
  DC_HIGH;
  RW_HIGH;
  E_HIGH;
  wait(LCD_WAIT);
  E_LOW; //data latched
 
  //low byte
  PORTA = (((c & 0x0F) << 4));
  DC_HIGH;
  RW_HIGH;
  E_HIGH;
  wait(LCD_WAIT);
  E_LOW; //data latched
}

void command (uchar c)
{//high byte
  PORTA = (c & 0xF0);
  DC_LOW;
  RW_LOW;
  E_HIGH;
  wait(LCD_WAIT);
  E_LOW; //data latched
 
  //low byte
  PORTA = (((c & 0x0F) << 4));
  DC_LOW;
  RW_LOW;
  E_HIGH;
  wait(LCD_WAIT);
  E_LOW; //data latched
}

set_newCharToFont(void)
{
  command(0x40); //0x40 -> pos of first char in CGRAM
  data_write(0x08); //1   8
  data_write(0x10); //2   10
  data_write(0x08); //3   8
  data_write(0x00); //4   0
  data_write(0x05); //5   5
  data_write(0x07); //6   7
  data_write(0x05); //7   5
  data_write(0x00); //8   0
}

void show_char(uchar num)
{
  command(0x01); //clear display
  command(0x02); //return home
  data(num); //1 -> Read data in ROM C at pos num
}


in main.c:

set_newCharToFont();
show_char(0);



One more question:
If we need more than 8 new character in the font, would it be possible to get a display with a customized software, which contains the needed characters?

Best regards,
OS

3
OLEDs / Re: NDH-0220CW: cursor not visible with text
« on: December 07, 2016, 05:08:45 AM »
Ok, I found out a new thing: it is possible to show a character and a cursor at one position at the same time.  ;D

But one more question: Is it possible to deactivate the auto increment of the cursor? I want to move the cursor independet from the characters written.

Thanks.

4
OLEDs / Re: NDH-0220CW: cursor not visible with text
« on: December 07, 2016, 03:41:55 AM »
Hi again.

I think my problem is done. It seams as if I had a wrong idear of how the cursor works.
It is not possible to show a character and a cursor at one position at the same time, is this correct?

Kind regards.

5
OLEDs / Re: NDH-0220CW: cursor not visible with text
« on: December 07, 2016, 03:21:58 AM »
Hello.

One more notice: When I send command(0x01) to clear the display, the text is erased but the cursor is visible again (at first position).

What am I doing wrong?


6
OLEDs / Re: NDH-0220CW: cursor not visible with text
« on: December 06, 2016, 03:06:46 AM »
Hello.

In the init function it is " command(0x0C); //fund. com. set: display ON:0C".

Later I send command(0x0E) for turning the cursor on. That works fine.
Moving the Cursor with command(0x14) works also fine.
When I call the function send_output(); the text is visible but the cursor disapeared.

Code: [Select]
void send_output(void)
{
  uint i=0;
  //command(0x01); //clear display
  command(0x02); //return home
  for(i=0;i<20;i++)
  {
    data(Line1[i]); //write Line1
  }
  command(0xC0); //line 2
  for(i=0;i<20;i++)
  {
    data(Line2[i]); //write Line2
  }
}


This is the hole init function:
Code: [Select]
E_LOW; //RES_HIGH; //RES = 1; //reset HIGH inactive
  wait(LCD_WAIT);//delayms(1); //delay
  command(0x2A); //fundamental command set: function set: RE ON
  command(0x71); //extended command set: function selection A
  data(0x00); // disable internal VDD regulator (2.8V I/O). data(0x5C) = enable regulator (5V I/O)
  command(0x28); //fundamental command set: function set:RE OFF
  command(0x08); //fund. com. set: display: display off, cursor off, blink off
  command(0x2A); //fundamental command set: function set: RE ON
  command(0x79); //extended com. set: OLED: "OLED command set" enabled (S.10)
  command(0xD5); //OLED command set: set display clock divide ratio/oscillator frequency
  command(0x70); //value: set display clock divide ratio/oscillator frequency
  command(0x78); //extended com. set: OLED: "OLED command set" disabled
  command(0x08); //(RE ON)fund.com. set: extended function set: 5-dot,no inverting of corsor,2-lines)
  command(0x06); //(RE ON)fund.com. set: COM SEG direction
  command(0x72); //ext. com.set: function selection B
  data(0x00);    //selectROM A, CGRAM
  command(0x2A); //fundamental command set: function set: RE ON
  command(0x79); //extended com. set: OLED: "OLED command set" enabled (S.10)
  command(0xDA); //OLED command set: set SEG pins hardware configuration
  command(0x10); //set SEG pins hardware configuration
  command(0xDC); //OLED command set: function selection C
  command(0x00); //function selection C: internal VSL + GPIO input disabled
  command(0x81); //OLED command set: set contrast control
  command(0xf0); //set contrast control: 0xf0
  command(0xD9); //OLED command set:set phase length
  command(0xF1); //set phase length: 0xf1
  command(0xDB); //OLED command set: set VCOMH deselect level
  command(0x40); //set VCOMH deselect level
  command(0x78); //extended com. set: OLED: "OLED command set" disabled
  command(0x28); //fundamental command set: function set:RE OFF
  command(0x06); //fundamental command set: cursor/blink moves right //BPIE
  command(0x01); //fund. com. set: clear display
  command(0x80); //fund. com. set: set DDRAM address to 0x00
  command(0x0C); //fund. com. set: display ON:0C
  wait(LCD_WAIT);//delayms(100); //delay

7
OLEDs / NDH-0220CW: cursor not visible with text
« on: December 05, 2016, 05:13:14 AM »
Hello.

It is my first OLED charakter display. I can turn on the cursor an move it to left and right. But when I send text, the cursor is not visible anymore. Is this correct?

Thanks.

Pages: [1]