切换到宽版
  • 1882阅读
  • 16回复

买了老王家的12864,不想飞线打样了pcb [复制链接]

上一主题 下一主题
离线dxf888
 

发帖
184
M币
462
专家
2
粉丝
24

第一次打样,线路检查了几次,没想到丝印搞错了,电源与地标反了

这是9665屏的pcb打算自己热转印
本文内容包含图片或附件,获取更多资讯,请 登录 后查看;或者 注册 成为会员获得更多权限
离线dxf888

发帖
184
M币
462
专家
2
粉丝
24
只看该作者 1楼 发表于: 12-02
#include<avr/io.h>
#include<avr/interrupt.h>
#include<avr/pgmspace.h>
#include<util/delay.h>
#define uint unsigned int
#define uchar unsigned char
#define a01 PORTD|=0x01
#define a00 PORTD&=0xfe
#define sda1 PORTD|=0x08
#define sda0 PORTD&=0xf7
#define sck1 PORTD|=0x20
#define sck0 PORTD&=0xdf
#define rst1 PORTD|=0x02
#define rst0 PORTD&=0xfd
const prog_char zifu[]={
0x00,0xE0,0x10,0x08,0x08,0x10,0xE0,0x00,0x00,0x0F,0x10,0x20,0x20,0x10,0x0F,0x00,/*"0",0*/
0x00,0x10,0x10,0xF8,0x00,0x00,0x00,0x00,0x00,0x20,0x20,0x3F,0x20,0x20,0x00,0x00,/*"1",1*/
0x00,0x70,0x08,0x08,0x08,0x88,0x70,0x00,0x00,0x30,0x28,0x24,0x22,0x21,0x30,0x00,/*"2",2*/
0x00,0x30,0x08,0x88,0x88,0x48,0x30,0x00,0x00,0x18,0x20,0x20,0x20,0x11,0x0E,0x00,/*"3",3*/
0x00,0x00,0xC0,0x20,0x10,0xF8,0x00,0x00,0x00,0x07,0x04,0x24,0x24,0x3F,0x24,0x00,/*"4",4*/
0x00,0xF8,0x08,0x88,0x88,0x08,0x08,0x00,0x00,0x19,0x21,0x20,0x20,0x11,0x0E,0x00,/*"5",5*/
0x00,0xE0,0x10,0x88,0x88,0x18,0x00,0x00,0x00,0x0F,0x11,0x20,0x20,0x11,0x0E,0x00,/*"6",6*/
0x00,0x38,0x08,0x08,0xC8,0x38,0x08,0x00,0x00,0x00,0x00,0x3F,0x00,0x00,0x00,0x00,/*"7",7*/
0x00,0x70,0x88,0x08,0x08,0x88,0x70,0x00,0x00,0x1C,0x22,0x21,0x21,0x22,0x1C,0x00,/*"8",8*/
0x00,0xE0,0x10,0x08,0x08,0x10,0xE0,0x00,0x00,0x00,0x31,0x22,0x22,0x11,0x0F,0x00,/*"9",9*/
0x00,0x00,0x00,0xC0,0xC0,0x00,0x00,0x00,0x00,0x00,0x00,0x30,0x30,0x00,0x00,0x00,/*":",10*/
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00};/*" ",14*/
const prog_char hanz[]={
0x80,0x80,0x80,0x80,0x80,0x80,0x80,0x80,0x80,0x80,0x80,0x80,0x80,0x80,0x80,0x00,
0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,/*"一",0*/
0x00,0x00,0x08,0x08,0x08,0x08,0x08,0x08,0x08,0x08,0x08,0x08,0x08,0x00,0x00,0x00,
0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x10,0x00,/*"二",1*/
0x00,0x04,0x84,0x84,0x84,0x84,0x84,0x84,0x84,0x84,0x84,0x84,0x84,0x04,0x00,0x00,
0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x20,0x00,/*"三",2*/
0x00,0xFC,0x04,0x04,0x04,0xFC,0x04,0x04,0x04,0xFC,0x04,0x04,0x04,0xFC,0x00,0x00,
0x00,0x7F,0x28,0x24,0x23,0x20,0x20,0x20,0x20,0x21,0x22,0x22,0x22,0x7F,0x00,0x00,/*"四",3*/
0x00,0x02,0x42,0x42,0x42,0xC2,0x7E,0x42,0x42,0x42,0x42,0xC2,0x02,0x02,0x00,0x00,
0x40,0x40,0x40,0x40,0x78,0x47,0x40,0x40,0x40,0x40,0x40,0x7F,0x40,0x40,0x40,0x00,/*"五",4*/
0x20,0x20,0x20,0x20,0x20,0x20,0x21,0x22,0x2C,0x20,0x20,0x20,0x20,0x20,0x20,0x00,
0x00,0x40,0x20,0x10,0x0C,0x03,0x00,0x00,0x00,0x01,0x02,0x04,0x18,0x60,0x00,0x00,/*"六",5*/
0x00,0x00,0x00,0xFE,0x82,0x82,0x82,0x82,0x82,0x82,0x82,0xFE,0x00,0x00,0x00,0x00,
0x00,0x00,0x00,0xFF,0x40,0x40,0x40,0x40,0x40,0x40,0x40,0xFF,0x00,0x00,0x00,0x00,/*"日",6*/
0x00,0x00,0x00,0xBE,0x2A,0x2A,0x2A,0xEA,0x2A,0x2A,0x2A,0x3E,0x00,0x00,0x00,0x00,
0x00,0x44,0x42,0x49,0x49,0x49,0x49,0x7F,0x49,0x49,0x49,0x49,0x41,0x40,0x00,0x00,/*"星",7*/
0x00,0x04,0xFF,0x24,0x24,0x24,0xFF,0x04,0x00,0xFE,0x22,0x22,0x22,0xFE,0x00,0x00,
0x88,0x48,0x2F,0x09,0x09,0x19,0xAF,0x48,0x30,0x0F,0x02,0x42,0x82,0x7F,0x00,0x00};/*"期",8*/
void writecom(uchar com) //a0=1写数据,a0=0写命令
{
uchar i;
a00;  
for(i=0;i<8;i++)
{
  if(com&0x80)
   sda1;
  else
   sda0;
  sck0;
  com<<=1;
  sck1;      
}
}
void writedat(uchar dat)
{
uchar i;
a01;  
for(i=0;i<8;i++)
{
  if(dat&0x80)
   sda1;
  else
   sda0;
  sck0;
  dat<<=1;
  sck1;      
}
}
void xy(uchar l,uchar h)
{
writecom(0xb0|l);
writecom(0x10|(h>>4));
writecom(h&0x0f);
}
void zif(uchar a,uchar b,uchar c)
{
uchar d;
xy(a,b*8);
for(d=0;d<8;d++)
writedat(pgm_read_byte(zifu+c*16+d));
xy(a+1,b*8);
for(d=8;d<16;d++)
writedat(pgm_read_byte(zifu+c*16+d));
}
void hz(uchar a,uchar b,uchar c)
{
uchar d;
xy(a,b*16);
for(d=0;d<16;d++)
writedat(pgm_read_byte(hanz+c*32+d));
xy(a+1,b*16);
for(d=16;d<32;d++)
writedat(pgm_read_byte(hanz+c*32+d));
}
void qingping(void)
{
uchar a,b;
for(b=0;b<8;b++)
{
  xy(b,0);
  for(a=0;a<132;a++)
  {
  writedat(0);
  }
}
}
void init(void)
{
DDRD|=0x2f;
rst0;
_delay_ms(10);
rst1;
_delay_ms(10);
writecom(0x2f);
writecom(0xf8);//升压倍数选择
writecom(0x26);//粗调对比度
writecom(0x81);//微调对比度命令
writecom(0x18);//微调对比度
writecom(0xa2);//1/9偏压比
writecom(0xc8);//行扫描顺序从上到下
writecom(0xa0);//列扫描顺序从左到右
writecom(0x40);//起始行从第一行开始
writecom(0xaf);//开显示
qingping();
}
int main(void)
{
init();
zif(0,0,0);
zif(0,1,1);
zif(0,2,2);
zif(0,3,3);
zif(0,4,4);
zif(0,5,5);
zif(0,6,6);
zif(0,7,7);
zif(0,8,8);
zif(0,9,9);
hz(2,0,0);
hz(2,1,1);
hz(2,2,2);
hz(2,3,3);
hz(2,4,4);
hz(2,5,5);
while(1);
}
atmega8的驱动
本帖最近打赏记录:共1条打赏M币+20
2545889167 M币 +20 - 12-02
离线flkflk

发帖
213
M币
55
专家
0
粉丝
9
只看该作者 2楼 发表于: 12-02
既然打样,应该把cpu也做上,用不到的管脚引出来,你这样浪费了一块pcb
在线温力口

发帖
59454
M币
176135
专家
532
粉丝
859
只看该作者 3楼 发表于: 12-02
怎么我的电脑显示不全图片????
离线2545889167

发帖
13124
M币
20590
专家
301
粉丝
4706
只看该作者 4楼 发表于: 12-02
这么简单的板子 不拼版满10*10真的是赚了板厂了
本帖最近打赏记录:共1条打赏M币+1
hbozyq M币 +1 我恨不得拼十款 12-07
p
离线2545889167

发帖
13124
M币
20590
专家
301
粉丝
4706
只看该作者 5楼 发表于: 12-02
既然打样,应该把cpu也做上,用不到的管脚引出来,你这样浪费了一块pcb
+1008611
本帖最近打赏记录:共1条打赏M币+3
ljlun M币 +3 我很贊同 12-03
p
离线dxf888

发帖
184
M币
462
专家
2
粉丝
24
只看该作者 6楼 发表于: 12-03
2545889167这么简单的板子 不拼版满10*10真的是赚了板厂了
      
首件20包邮,用了双11红包,自己没花钱,拼板得加钱

发帖
50
M币
929
专家
2
粉丝
54
只看该作者 7楼 发表于: 12-03
既然是打样为什么不找我,可以给你打折嘛
PCB供货商快速抄板 特价快板打样50一款 批量大批量350需要打这电话 13112732922赵生
离线netbeetle

发帖
599
M币
821
专家
3
粉丝
7
只看该作者 8楼 发表于: 12-03
这板做得真差,安装孔都破了。
离线dxf888

发帖
184
M币
462
专家
2
粉丝
24
只看该作者 9楼 发表于: 12-03
netbeetle这板做得真差,安装孔都破了。
      
便宜没好货