Есть LCD дисплей от стабилизатора “Ресанта” на чипе TM1726.
Нужна библиотека для создания конструкций на Ардуино.
Подобный дисплей , но светодиодный на TM1640 подключал. А с этим проблема.
Есть LCD дисплей от стабилизатора “Ресанта” на чипе TM1726.
Нужна библиотека для создания конструкций на Ардуино.
Подобный дисплей , но светодиодный на TM1640 подключал. А с этим проблема.
ее нет в природе.
Это пример из datasheet
The following is a C51 microcontroller TM1726 memory filled with 0xA5 and
displayed as an example of C program
//MCU:AT89S52
//MCU Crystal:11.0592MHZ
// Development environment:Keil uVision3
#include<REG52.H>
#include<intrins.h>
#define uint unsigned int
#define uchar unsigned char
sbit SDA=P1^0; // Configures the SDA data line
sbit SCL=P1^1; // Define the SCL clock line
//*******************************************************
void delay(uint z) //n Ms delay subroutine
{
uint x,y;
for(x=z;x>0;x–)
for(y=112;y>0;y–);
}
//*******************************************************
void start() //START Signal
{
SCL=1; //SCL High level of
SDA=1; // SDA To a falling edge
SDA=0;
}
//*******************************************************
void stop() //STOP Signal
{
nop();nop();
SDA=0;
SCL=1; // SCL is high when
nop();nop();nop();
SDA=1; // SDA to a falling edge
LCD Driver Control of a Dedicated Circuit 1726
www.titanmec.com 8
nop();nop();
}
//*******************************************************
void ack() // Response signal
{
SDA=1;
nop();
while(SDA); // 8 signal, waiting for the chip bus down
SCL=0; // Host is given a rising edge
SCL=1;
SCL=0;
SDA=0; // The current state of the release of the chip input
}
//*******************************************************
void write(uchar date8) // Writing a byte subroutine
{
uchar i,j;
j=date8;
SCL=0; // SCL is low
for(i=0;i<8;i++)
{
if(j&0x01) // Level of detection of SDA
SDA=1;
else
SDA=0;
SCL=0;
SCL=1; //SCL rising edge, data is written
SCL=0;
j>>=1;
}
}
//********************************************************
void send_cmd(uchar temp) //
Send the display control command subroutine
LCD Driver Control of a Dedicated Circuit 1726
www.titanmec.com 9
{
start(); // The start signal
write(temp); // Write an 8-bit command, low front, high in the
ack(); // Response signal
stop(); // Stop signal
}
//********************************************************
void send_data(uchar cmd,uchar d1) // Write memory subroutine
{
uchar num;
start(); // The start signal
write(cmd); // Write an 8-bit command, low front, high in the
ack(); // Response signal for(num=0;num<18;num++)
// Written to memory data
{
write(d1); // Written data
ack(); // Response signal
}
stop(); // Stop signal
}
//********************************************************
void init() // MCU initialization
{
P1=0XFF;
}
//********************************************************
void main(void) // Main
{
init(); // Initialization
send_data(0xC0, 0xA5); // Set the first address, and write data
send_cmd(0x27); // Set the first address, and write the data set
display control command: 1/3BIAS, LINE mode, drive a 5V LCD screen.
while(1); // Circular wait
}
//******************** The end of the process ***************************
Адаптировать для Ардуино у меня мозгов не хватает
Посмотрел даташит, вроде ничего там особо заумного нету. Зайдите в "Ищу исполнителя, попробуйте заказать, наверняка кто-то откликнется. Особенно, если дисплей сможете как-то предоставить, чтобы было на чём отлаживаться.
Спасибо. ИИ помог. Дисплей принимает данные. Теперь осталось что бы показывал то что нужно. Думаю дальше разберусь.
avanes13 вроде как правило хорошего тона гласит, нашел способ сам, выложи ответ…
можете у вашего ИИ спросить так ли это ?
но перед этим вам надо научиться код вставлять конечно…
Первая тема на форуме. Научусь. То что сделал еще очень сырое.
Петрович всегда дельный совет даёт))