精华内容
下载资源
问答
  • 光立方代码
    2022-05-21 15:25:18
    void LED(int level, int row, int column, byte red, byte green, byte blue){
        //****LED Routine****LED Routine****LED Routine****LED Routine
    //This is where it all starts
    //This routine is how LEDs are updated, with the inputs for the LED location and its R G and B brightness levels
    // First, check and make sure nothing went beyond the 
    更多相关内容
  • 光立方代码

    2015-01-18 01:04:05
    很详细的光立方代码,可供想做光立方的朋友参考
  • 基于CPLD,用VHDL语言编程,实现了一个8*8*8的光立方控制
  • 8阶光立方代码

    2019-04-08 16:53:49
    采用层共阴极、束共阳极的方式连接全部512个LED,每层64 个灯,共8层。单层8位并行控制数据由Arduino的数字端口IO1~IO8输入(IO0空),8个锁存器的锁存使能端LE1~LE8由3-8线译码器的8线并行输出数据控制,译码器的三...
  • 4×4光立方VHDL代码

    2020-11-28 17:34:35
    无聊的时候自己动手编写的控制光立方代码。本资源通过使用VHDL代码实现控制4×4光立方逐个点亮实现流水灯功能。
  • 借鉴LED点阵控制原理,将光立方可以看做是8个8*8点阵屏的层叠一起,用8个引脚来当充当各层8*8点阵的“开关”(每层共阴)。再将64个灯阳极连到573的输出引脚上,每个573控制8列LED。驱动采用了74hc573暂存的方法,来...
  • DIY 8X8X8光立方-程序代码.zip
  • 444光立方
  • 光立方代码

    2017-09-03 18:25:18
    光立方代码,对于c语言初学者这是一个很好的课题,既锻炼了对硬件的动手操作能力,也锻炼了,软件的设计,编写,调试的能力。这是一个对初学者综合能力的考验。如果你能独立完成光立方的制作,是对自己能力的一次...
  • STM32F030光立方程序,含标准库。
  • void main() { End=sizeof(table); IO_Interrupt_UART_Init(); while(1) { if(Anm>End)Anm=0; Segs=Segs_tab[Anm1]; switch (Mode) { case 0:Out=table[Anm1+Anm];... //清除TF1标志
  • 光立方制作过程图文详解,看完就能动手制作 光立方的bom表 光立方演示视频(动画1,源代码见附件) 光立方演示视频(动画2,源代码见附件) 附件包含光立方的详细制作过程,源代码
  • 光立方程序代码

    2015-10-06 21:46:17
    光立方程序代码,好好看的
  • 2维光立方代码生成软件,MFC代码,5X5,可根据自己要求进行扩展
  • 4×4×4光立方_光立方_

    2021-10-01 13:02:26
    炫酷多彩光立方,可以自行组装,里面包含原理图和PCB
  • 4*4*4光立方keil源程序

    2018-01-11 15:04:18
    第一次上传,此程序可以直接用的,欢迎更改,相互交流
  • 3.3 C语言程序#include#define uchar unsigned charvoid delay100ms(uchar data1ms){uchar i,j,m;for(i=0;ifor(j=0;j<110;j++)for(m=0;m<100;m++);}void disp(uchar ceng,uchar lie1,uchar lie2 ){delay100ms...

    3.3 C语言程序

    #include

    #define uchar unsigned char

    void delay100ms(uchar data1ms)

    {uchar i,j,m;

    for(i=0;i

    for(j=0;j<110;j++)

    for(m=0;m<100;m++)

    ;

    }

    void disp(uchar ceng,uchar lie1,uchar lie2 )

    {

    delay100ms(7);

    P1=ceng;

    P2=lie1;

    P0=lie2;

    }

    void main(void)

    {unsigned char hang,shu1;

    unsigned char code C1[][16]={

    {0x07,0x0B,0x0D,0x0E,0x0E,0x0C,0x08,0x00,0x00,0x08,0x0C,0x0E,0x0C,0x08,0x00,0x00},

    {0x08,0x0C,0x0E,0x0C,0x08,0x00,0x00,0x08,0x0C,0x0E,0x0C,0x08,0x00,0x00,0x08,0x0C},

    {0x0E,0x0E,0x0E,0x0E,0x0E,0x0E,0x0E,0x0E,0x0E,0x0E,0x0E,0x0E,0x0E,0x0E,0x0E,0x0E},

    {0x0C,0x08,0x00,0x00,0x08,0x0C,0x0E,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00},

    {0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x08,0x0C,0x0E,0x0F,0x0E,0x0C,0x08,0x00},

    {0x00,0x00,0x00,0x00,0x00,0x0D,0x0D,0x0D,0x05,0x09,0x09,0x09,0x0D,0x0D,0x0D,0x05},

    {0x09,0x09,0x09,0x00,0x09,0x09,0x09,0x09,0x09,0x09,0x09,0x09,0x09,0x09,0x09,0x09},

    {0x09,0x09,0x09,0x09,0x09,0x09,0x09,0x09}

    };

    unsigned char code L1[][16]={

    {0xFF,0xFF,0xFF,0xFF,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x96,0x96,0x96,0x96,0x96},

    {0x96,0x96,0x33,0x33,0x33,0x33,0x33,0x33,0x33,0xCC,0xCC,0xCC,0xCC,0xCC,0xCC,0xCC},

    {0x01,0x03,0x07,0x0F,0x8E,0x8C,0x88,0x80,0x00,0x00,0x00,0x10,0x30,0x70,0x70,0x60},

    {0x60,0x60,0x60,0x60,0x60,0x60,0x60,0xCC,0x0F,0x33,0x66,0xCC,0xF0,0x33,0x66,0xCC},

    {0x66,0x33,0xF0,0xCC,0x66,0x33,0xF0,0xCC,0xCC,0xCC,0xCC,0xCC,0x60,0x60,0x60,0x60},

    {0xE8,0x74,0x32,0x11,0x00,0x06,0x66,0x60,0x60,0x60,0x00,0x00,0x06,0x66,0x60,0x60},

    {0x60,0x00,0x00,0x00,0x80,0x40,0x20,0x20,0x20,0x60,0x62,0x60,0x30,0x10,0x80,0xC0},

    {0x60,0x60,0x60,0x60,0x64,0x60,0x30,0x10}

    // {0x01,0x02,0x04,0x08,0x80,0x40,0x20,0x10,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00},//列扫描

    };

    unsigned char code L2[][16]={

    {0xFF,0xFF,0xFF,0xFF,0x06,0x06,0x06,0x06,0x06,0x06,0x06,0x69,0x69,0x69,0x69,0x69},

    {0x69,0x69,0xCC,0xCC,0xCC,0xCC,0xCC,0xCC,0xCC,0x33,0x33,0x33,0x33,0x33,0x33,0x33},

    {0x00,0x00,0x00,0x00,0x00,0x08,0x88,0xC8,0xE8,0xF0,0x71,0x31,0x11,0x10,0x04,0x06},

    {0x06,0x06,0x06,0x06,0x06,0x06,0x06,0x33,0xF0,0xCC,0x66,0x33,0x0F,0xCC,0x66,0x33},

    {0x66,0xCC,0x0F,0x33,0x66,0xCC,0x0F,0x33,0x33,0x33,0x33,0x33,0x06,0x06,0x06,0x06},

    {0x8E,0x47,0x23,0x11,0x00,0x00,0x00,0x06,0x06,0x06,0x66,0x60,0x00,0x00,0x06,0x06},

    {0x06,0x66,0x60,0x00,0x08,0x0C,0x06,0x66,0x06,0x06,0x06,0x06,0x03,0x01,0x00,0x08},

    {0x04,0x64,0x06,0x06,0x06,0x06,0x03,0x01}

    // {0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x02,0x04,0x08,0x80,0x40,0x20,0x10}

    };

    while(1)

    {

    for(hang=0;hang<8;hang++)

    {for(shu1=0;shu1<16;shu1++)

    disp(C1[hang][shu1],L1[hang][shu1],L2[hang][shu1]);

    }

    // for(hang=0;hang<1;hang++)

    // {

    // for(shu1=0;shu1<16;shu1++)

    // {shu2=0;

    // disp(C1[shu2][shu2],L1[hang][shu1],L2[hang][shu1]);

    // }

    // }

    }

    }

    展开全文
  • 本文为您讲解基于51单片机的4*4*4光立方程序实现原理及程序代码。LED光立方的复位电路、时钟电路、每层LED灯电路控制逻辑,系统总原理图,工作流程及相关C语言源码实现。希望能够对你学习了解LED光立方程序编写及LED...

    本文为您讲解基于51单片机的4*4*4光立方程序实现原理及程序代码。LED光立方的复位电路、时钟电路、每层LED灯电路控制逻辑,系统总原理图,工作流程及相关C语言源码实现。希望能够对你学习了解LED光立方程序编写及LED立方实体制作起到一定的帮助指导作用。

    3.1单片机资源分配情况

    将4*4*4的LED光立方分层4层,分别由单片机的P1.0,P1.1,P1.2,P1.3,四个口来控制每一层,且给低电平有效,再有P0口和P1的总共16个口来控制16列,给高电平有效,P0和P1口加上位排阻,再给每一列加三极管放大,三极管的基极接单片机的P0和P1口,集电极接5V电源,发射极接每一列。这样就可以通过控制每个口的输出信号来控制每个的亮灭。

    3.2复位电路

    通过某种方式,是单片机内部各类寄存器的值变为出事状态的操作称为复位。单片机的复位是通过外部电路来实现的,复位引脚RET通过一个施密特触发器与复位电路相连接,施密特触发器用作噪声抑制,伟哥机器周期的S5P2时刻,复位电路采样一次施密特输出电平,获得内部复位操作所需要的信号。单片机的时钟电路正常工作后,CPU在RET/VPD引脚上连续采集到两个机器周期的高电平后就可以完成复位操作了,但实际应用时,复位电平的脉冲宽度一般大于1ms。复位电路通常采用上电复位、手动按键复位和看门狗复位三种方式,本次采用的是上电复位方式。

    5addba8c846d6a5462c617a4cefd350a.png

    3.3时钟电路

    单片机的各个功能部件的运行都是是时钟控制信号为基准,一拍一拍的工作。因此时钟频率直接影响单片机的速度,时钟电路的质量也直接影响单片机

    系统的可靠性和稳定性。常用的时钟电路设计为内部时钟方式,单片机内部有一个由反向放大器构成的震荡电路,芯片上的XTAL1和XTAL2分别为震荡电路的输入和输出端。只要在这两个引脚上接一个石英晶体振荡器和两个微调电容就构成内部方式的振荡器电路,有振荡器产生自激振荡,便构成一个完整的震荡信号发生器。

    一般选用石英晶体振荡器。此电路在加电大约延迟10ms后振荡器起振,在XTAL2引脚产生幅度为3V左右的正弦波时钟信号,其振荡频率主要由石英晶振的频率确定。电路中两个电容C1、C2的作用有两个:一是帮助振荡器起振;二是对振荡器的频率进行微调。本系统的C1、C2的值为33pf。

    单片机在工作时,有内部振荡器产生或由外直接输入的送至内部控制逻辑单元的时钟信号的周期称为时钟周期。其大小是时钟信号频率的倒数,f表示。图2中的时钟频率为12MHz,即f=12MHz,则时钟周期为1/12us。

    附注: 三极管可以不接,只是会影响光源亮度。

    c2d9db6d1e05610a13c15a178957314b.png

    3.4系统的工作原理图

    光立方一、二层:

    6679aed18bbc4a9d1b8f99ae89a1551e.png

    光立方三、四层:

    c305e5ff4513c59ee0ee135b29cd756c.png

    单片机口点连接:

    8118e01ed3a4c6a9aab116d2316c8c77.png

    三极管放大电路:

    304c34b893a28622267839feb5711a33.png

    36c65d6feb8c78dffaa4c324802522af.png

    总原理图:

    68fefef20d8157f2929626037a97487f.png

    3.5 焊接实物图

    bed65a506878ac0a1e4342e18d202ef4.png

    8f4f1c60ca72d417cd9327fc8c130801.png

    元器件清单:

    33a1022e40cced53397a12fb949ea616.png

    3.3 C语言程序

    #include

    #define uchar unsigned char

    void delay100ms(uchar data1ms)

    {uchar i,j,m;

    for(i=0;i

    for(j=0;j<110;j++)

    for(m=0;m<100;m++)

    ;

    }

    void disp(uchar ceng,uchar lie1,uchar lie2 )

    {

    delay100ms(7);

    P1=ceng;

    P2=lie1;

    P0=lie2;

    }

    void main(void)

    {unsigned char hang,shu1;

    unsigned char code C1[][16]={

    {0x07,0x0B,0x0D,0x0E,0x0E,0x0C,0x08,0x00,0x00,0x08,0x0C,0x0E,0x0C,0x08,0x00,0x00},

    {0x08,0x0C,0x0E,0x0C,0x08,0x00,0x00,0x08,0x0C,0x0E,0x0C,0x08,0x00,0x00,0x08,0x0C},

    {0x0E,0x0E,0x0E,0x0E,0x0E,0x0E,0x0E,0x0E,0x0E,0x0E,0x0E,0x0E,0x0E,0x0E,0x0E,0x0E},

    {0x0C,0x08,0x00,0x00,0x08,0x0C,0x0E,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00},

    {0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x08,0x0C,0x0E,0x0F,0x0E,0x0C,0x08,0x00},

    {0x00,0x00,0x00,0x00,0x00,0x0D,0x0D,0x0D,0x05,0x09,0x09,0x09,0x0D,0x0D,0x0D,0x05},

    {0x09,0x09,0x09,0x00,0x09,0x09,0x09,0x09,0x09,0x09,0x09,0x09,0x09,0x09,0x09,0x09},

    {0x09,0x09,0x09,0x09,0x09,0x09,0x09,0x09}

    };

    unsigned char code L1[][16]={

    {0xFF,0xFF,0xFF,0xFF,0x60,0x60,0x60,0x60,0x60,0x60,0x60,0x96,0x96,0x96,0x96,0x96},

    {0x96,0x96,0x33,0x33,0x33,0x33,0x33,0x33,0x33,0xCC,0xCC,0xCC,0xCC,0xCC,0xCC,0xCC},

    {0x01,0x03,0x07,0x0F,0x8E,0x8C,0x88,0x80,0x00,0x00,0x00,0x10,0x30,0x70,0x70,0x60},

    {0x60,0x60,0x60,0x60,0x60,0x60,0x60,0xCC,0x0F,0x33,0x66,0xCC,0xF0,0x33,0x66,0xCC},

    {0x66,0x33,0xF0,0xCC,0x66,0x33,0xF0,0xCC,0xCC,0xCC,0xCC,0xCC,0x60,0x60,0x60,0x60},

    {0xE8,0x74,0x32,0x11,0x00,0x06,0x66,0x60,0x60,0x60,0x00,0x00,0x06,0x66,0x60,0x60},

    {0x60,0x00,0x00,0x00,0x80,0x40,0x20,0x20,0x20,0x60,0x62,0x60,0x30,0x10,0x80,0xC0},

    {0x60,0x60,0x60,0x60,0x64,0x60,0x30,0x10}

    // {0x01,0x02,0x04,0x08,0x80,0x40,0x20,0x10,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00},//列扫描

    };

    unsigned char code L2[][16]={

    {0xFF,0xFF,0xFF,0xFF,0x06,0x06,0x06,0x06,0x06,0x06,0x06,0x69,0x69,0x69,0x69,0x69},

    {0x69,0x69,0xCC,0xCC,0xCC,0xCC,0xCC,0xCC,0xCC,0x33,0x33,0x33,0x33,0x33,0x33,0x33},

    {0x00,0x00,0x00,0x00,0x00,0x08,0x88,0xC8,0xE8,0xF0,0x71,0x31,0x11,0x10,0x04,0x06},

    {0x06,0x06,0x06,0x06,0x06,0x06,0x06,0x33,0xF0,0xCC,0x66,0x33,0x0F,0xCC,0x66,0x33},

    {0x66,0xCC,0x0F,0x33,0x66,0xCC,0x0F,0x33,0x33,0x33,0x33,0x33,0x06,0x06,0x06,0x06},

    {0x8E,0x47,0x23,0x11,0x00,0x00,0x00,0x06,0x06,0x06,0x66,0x60,0x00,0x00,0x06,0x06},

    {0x06,0x66,0x60,0x00,0x08,0x0C,0x06,0x66,0x06,0x06,0x06,0x06,0x03,0x01,0x00,0x08},

    {0x04,0x64,0x06,0x06,0x06,0x06,0x03,0x01}

    // {0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x02,0x04,0x08,0x80,0x40,0x20,0x10}

    };

    while(1)

    {

    for(hang=0;hang<8;hang++)

    {for(shu1=0;shu1<16;shu1++)

    disp(C1[hang][shu1],L1[hang][shu1],L2[hang][shu1]);

    }

    // for(hang=0;hang<1;hang++)

    // {

    // for(shu1=0;shu1<16;shu1++)

    // {shu2=0;

    // disp(C1[shu2][shu2],L1[hang][shu1],L2[hang][shu1]);

    // }

    // }

    }

    }

    展开全文
  • 此程序用于由单片机控制的8*8*8光立方,点亮全灯已测试led的坏坏,非常实用。注明:此程序为开源转载,如有不妥请联系本人处理
  • void shandian(char v){char i,j;uchar a[64];for(i=0;i<64;i++)a[i]=tab_shandian[64*21+i];for(i=0;i<22;i++)zhen(tab_shandian+64*i,v);for(i=0;i<22;i++){for(j=0;j<...(~tab_sha...

    void shandian(char v){char i,j;uchar a[64];for(i=0;i<64;i++)a[i]=tab_shandian[64*21+i];for(i=0;i<22;i++)zhen(tab_shandian+64*i,v);for(i=0;i<22;i++){for(j=0;j<64;j++)a[j]=a[j]&(~tab_shandian[64*i+j]);zhen(a,v);}}void cut(){uchar a[64]={0};char i;for(i=0;i<4;i++){a[i*8+7]=0xff;a[(7-i)*8+7]=0xff;zhen(a,8);}zhen(a,30);for(i=3;i>=0;i--){a[i*8+7]=0;a[(7-i)*8+7]=0;zhen(a,8);}}void shensuo(uchar v){char i,j;uchar a[64]={0};for(i=0;i<64;i++)a[i]=0xff;for(i=0;i<7;i++){move(a,0,0,1);zhen(a,v);}for(i=0;i<7;i++){move(a,0,1,1);for(j=0;j<64;j++)a[j]|=0x01;zhen(a,v);}for(i=0;i<7;i++){move(a,2,0,1);zhen(a,v);}for(i=0;i<7;i++){move(a,2,1,1);for(j=0;j<8;j++)a[j]|=0xff;zhen(a,v);}for(i=7;i>0;i--){for(j=0;j<8;j++)a[j*8+i]=0;zhen(a,v);}for(i=1;i<8;i++){for(j=0;j<8;j++)a[j*8+i]|=0xff;zhen(a,v);}}void linkpc1(char v){uchar i,a[64]={0};for(i=0;i<7;i++)a[7*8+i]=0xff;for(i=0;i<8;i++){move(a,2,0,1);zhen(a,v);}}void link00(){uchar a[64]={0};char i;for(i=10;i>7;i--){zhen(bianxing_table+i*64,70);}produce_cube(a,6);move(a,1,1,1);move(a,0,1,1);zhen(a,110);produce_cube(a,8);zhen(a,110);}void link_jb0(char v){uchar a[64]={0};char i;for(i=0;i<64;i++){a[i]=0x80;zhen(a,v);}}int STC_ADC(){uchar i;ADC_RES=0;ADC_RESL=0;ADC_CONTR=0x88;i=3;while(i--);while(1) {if(ADC_CONTR&0x10) break;}ADC_CONTR=0x80;return(ADC_RESL+ADC_RES<<2);}short sqrt_16( unsigned long M) {unsigned int N,i;unsigned long tmp,ttp; if(M==0) return 0;N=0;tmp=(M>>30); M<<=2;if(tmp>1) {N++; tmp-=N;}for(i=15;i>0;i--) {N<<=1; tmp<<=2;tmp+=(M>>30); ttp=N;ttp=(ttp<<1)+1;M<<=2;if(tmp>=ttp) {tmp-=ttp;N++;} }return N;}void FFT(){int xdata i,bb,j,k,p;int max,a[6];int xdata TR,TI,temp;for(i=0; i<64;i++){Real[BRTable[i]]=STC_ADC();Image[i]=0;}for(i=1;i<=6;i++) { bb=1;bb<<=(i-1); for(j=0;j<=bb-1;j++) { p=1;p<<=(6-i); p=p*j;for(k=j;k<64;k=k+2*bb) { key_amenu_scan(); key_out_scan();TR = Real[k]; TI = Image[k];temp=Real[k+bb];Real[k]=Real[k]+((Real[k+bb]*cos_tabb[p])>>7)+((Image[k+bb]*sin_tabb[p])>>7);Image[k]=Image[k]-((Real[k+bb]*sin_tabb[p])>>7)+((Image[k+bb]*cos_tabb[p])>>7);Real[k+bb]=TR-((Real[k+bb]*cos_tabb[p])>>7)-((Image[k+bb]*sin_tabb[p])>>7);Image[k+bb]=TI+((temp*sin_tabb[p])>>7)-((Image[k+bb]*cos_tabb[p])>>7); Real[k]>>=1; Image[k]>>=1; Real[k+bb]>>=1; Image[k+bb]>>=1; } }}max=0;for(i=0;i<6;i++){a[i]=sqrt_16((Real[i+1]*Real[i+1]+Image[i+1]*Image[i+1])>>1);if(a[i]<2 ) a[i]=0;elsea[i]-=2;if(max7){max/=7;for(i=0;i<6;i++){a[i]/=max;}}for(i=0;i<6;i++)c[i]=a[i];}void disp() interrupt 1{TR0=0;TH0=(65536-2500)/256;TL0=(65536-2500)%256;if(num>=(amenu-1))num=0;elsenum++;if(b[num]c[num])b[num]--;if(b[num]>8)b[num]=8;if(amenu==1)fun(table1+num*8);else if(amenu==2)fun(table2+num*8);else if(amenu==3)fun(table3+num*8);else if(amenu==4)fun(table4+num*8);else if(amenu==5)fun(table5+num*8);elsefun(table6+num*8); P3=tuku1[b[num]];TR0=1;}/**********初始化函数*****************/void init(){/***********I/O口初始化*************/P1M1=1; //p1.0口高阻输入P1ASF=1; P3M0=0xff; //P3口推挽输出P2M0=0xff;P0M0=0xff;P4SW = 0x31;TMOD=0x01;TH0=(65536-4000)/256; TL0=(65536-4000)%256;EA=1; ET0=1; TR0=0; menu=0;out=0;amenu=0;num=0;}/*************主函数******************/void main(){int i,j;char go;delay(800);init(); //初始化函数呼吸灯P2=0xff;P0=0;P2=0x80;P3=1;while(!menu){for(i=0;i<400;i++){key_menu_scan();if(menu)break;P0=0x80;delay1(i);P0=0;delay1(400-i);if(i<200){j=2;while(j--){P0=0x80;delay1(i);P0=0;delay1(400-i);}}}for(i=0;i<401;i++){if(menu)break; key_menu_scan();P0=0x80;delay1(400-i);P0=0;delay1(i);if(i>200){j=2;while(j--){P0=0x80;delay1(400-i);P0=0;delay1(i);}}}}P3M0=0x00;///开机扫描turn_on(10);H_scan(20);V_scan(20);W_scan(20);/主菜单选项while(1){hy(number+37*8,2);while(!amenu){W_side(number+(36+menu)*8,1,45);}switch(menu){case 1://音谱显示delay(400);while(!out){TR0=1;FFT();} TR0=0;break;case 2://动画显示delay(400);amenu=0;//menu=1;go=1;cut();while(go){for(i=0;i<10;i++)hy(number+27*8+i*8,3);if(out)go=1;elsego=0;}go=1;while(go){zimu(number,19,12,1);if(out)go=1;elsego=0;}go=1;while(go){fn(4);if(out)go=1;elsego=0;}go=1;while(go){out=0;flash0(2);if(out)go=1;elsego=0;}go=1;while(go){linkpc1(10);pc1(4,3);if(out)go=1;elsego=0;}go=1;while(go){leitu(yc_table,5,2); if(out)go=1;elsego=0;}go=1;while(go){denghuo(3);if(out==1)go=1;elsego=0;}go=1;while(go){water1(1,2,10);water1(2,4,10);water1(4,3,10);water1(7,1,10);water1(5,6,10); water2(0,2,7,1,9);water2(2,4,7,7,9);water2(4,7,7,1,9);water2(3,6,7,7,9);water2(4,1,6,6,9);water2(7,3,1,2,9);water3(0,4,7,4,5,1,9);water3(7,7,0,0,0,7,9);water3(0,6,6,6,5,1,9);water3(6,7,0,0,2,2,9);water3(3,3,6,6,2,2,9);if(out)go=1;elsego=0;}go=1;while(go){clc();link_pingmian1(1);pingmian1(8,3);if(out)go=1;elsego=0;}go=1;while(go){for(i=0;i<7;i++)print(tab_print+i*8,1);for(i=7;i<11;i++)print(tab_print+i*8,0);if(out)go=1;elsego=0;}go=1;while(go){clc();link_jb0(1);jb0(10,3);if(out)go=1;elsego=0;}go=1;while(go){yinchu(yc_table,5,9);if(out)go=1;elsego=0;}go=1;while(go){clc();link_jb0(1);jb0(10,3);if(out)go=1;elsego=0;}go=1;while(go){link(9);xuanzhuantiao(1,8,4);xuanzhuantiao(0,8,4);if(out)go=1;elsego=0;}go=1;while(go){xuanzhuantiao2(3,3);if(out)go=1;elsego=0;}go=1;while(go){qumianxuanzhuan(1,10,4);qumianxuanzhuan(0,10,4);if(out)go=1;elsego=0;}go=1;while(go){qumianxuanzhuan2(13,4);if(out)go=1;elsego=0;}go=1;while(go){xuanzhuantiao(1,4,4);xuanzhuantiao(1,3,5);xuanzhuantiao(1,2,6);xuanzhuantiao(1,1,7);if(out)go=1;elsego=0;}go=1;while(go){donghua(bianxing_table,11,1,24);xzcube();donghua(y_table,6,5,5);donghua(x_table,6,5,5);donghua(z_table,6,5,5);link00();if(out)go=1;elsego=0;}go=1;while(go){shensuo(5);if(out)go=1;elsego=0;}go=1;while(go){donghua(sin_cube_table,14,22,5);if(out)go=1;elsego=0;}go=1;while(go){for(i=0;i<3;i++)for(j=0;j<3;j++)cube(0,j,6);for(i=0;i<3;i++)for(j=0;j<3;j++)cube(1,j,6);if(out)go=1;elsego=0;}go=1; while(go){donghua(hart_table,2,10,32);if(out)go=1;elsego=0;}go=1;while(go){for(i=2;i>0;i--)shandian(i);if(out)go=1;elsego=0;}go=1;while(go){szfc0(10);if(out)go=1;elsego=0;}go=1;while(go){rain(1,10,9);rain(0,10,9);if(out)go=1;elsego=0;}break;case 3://夜灯模式delay(200);LED();break;}out=0;amenu=0;menu=1;}}

    2936547a77771607184bbd002cfb94bb.png

    展开全文
  • LED光立方(魔幻)全套代码+设计图,全方位指导,内容详细。
  • 4*4*4光立方

    2014-07-17 17:28:40
    这个是我自己写的4*4*4的光立方代码,以及取模软件。现在全部共享出来,方便大家学习。博客里面有具体的项目讲解。
  • 本文给大家介绍了一个利用595芯片所写的光立方程序。
  • 光立方代码 原理图

    2012-10-27 13:34:27
    值得一看啊,是光缆立法代码,数码自家上找到的,
  • 借鉴LED点阵控制原理,将光立方可以看做是8个8*8点阵屏的层叠一起,用8个引脚来当充当各层8*8点阵的“开关”(每层共阴)。再将64个灯阳极连到573的输出引脚上,每个573控制8列LED。驱动采用了74hc573暂存的方法,来...
  • 4x4x4光立方代码

    2014-06-09 00:21:00
    采用51单片机作为核心板,led以每一层为单位,采用共阳接法,
  • LED光立方 包含光立方的源代码及原理图,LED显示 3D光立方,课题材料,毕业设计
  • 4*4*4光立方制作分享

    2022-06-11 15:52:38
    光立方顾名思义就是会发光的立方体,光立方的基本原理是利用人眼的暂留效应,利用单片机控制LED灯快速的闪烁,显示出一个完整的图案。

空空如也

空空如也

1 2 3 4 5 ... 20
收藏数 8,565
精华内容 3,426
关键字:

光立方代码