Page 43 - 2
P. 43

라 오렌지보드.


                                                     1)  마이크로 컨트롤러: ATmega328P
                                                     2)  동작전압: DC 5V
                                                     3)  입력전압: DC 7~15V
                                                     4) USB  입력전압: DC 5V
                                                     5)  디지털 입 출력 핀/    : 14EA(6 개의 PWM    출력 포함)
                                                     6)  아날로그 입력 핀: 6EA
                                                     7)  클럭속도: 16MHz




            7.  회로 설계하기
              가 전체 회로도.






































            8.  소프트웨어 작성하기


            #include <Servo.h>


            Servo myservo;


            //L293  연결
              const int motorA1   = 5; // Pin 2 of L293
              const int motorA2   = 6; // Pin 7 of L293
              const int motorB1   = 10; // Pin 10 of L293
              const int motorB2   = 9;  // Pin 14 of L293
            //Led  연결
              const int lights = 12;


                                                         - 43 -
   38   39   40   41   42   43   44   45   46   47   48