Ks0247 keyestudio Pro Mini: Difference between revisions

From Keyestudio Wiki
Jump to navigation Jump to search
(Created page with "== Introduction == The processing center of keyestudio pro mini is Atmega328.It has 14 digital input/output pins (6 of which can be PWM output), 8 analog inputs, a 16MHz reson...")
 
 
(39 intermediate revisions by the same user not shown)
Line 1: Line 1:
[[image:KS0247.jpg|thumb|700px|right|Keyestudio Pro Mini ]]
<br>
== Introduction ==
== Introduction ==
The processing center of keyestudio pro mini is Atmega328.It has 14 digital input/output pins (6 of which can be PWM output), 8 analog inputs, a 16MHz resonator, a reset button, mounting holes and pins.
keyestudio Pro Mini is a small microcontroller board based on the ATmega328. ([http://ww1.microchip.com/downloads/en/DeviceDoc/Atmel-8271-8-bit-AVR-Microcontroller-ATmega48A-48PA-88A-88PA-168A-168PA-328-328P_datasheet_Complete.pdf datasheet]), intended for use on breadboards and when space is at a premium.<br>
[[File:KS0247 (1).jpg|thumb]]
It has 14 digital input/output pins (of which 6 can be used as PWM outputs), 8 analog inputs, a 16 MHz crystal oscillator, and a reset button. <br>
Note that the board is without an on-board USB to Serial connection. To program the Pro Mini, you will need an external USB to Serial module.<br>
The keyestudio pro mini can be powered via the pins 5V GND (DC 5V), or female headers Vin GND (DC 7-9V).<br>
 
<br>
==Features==
* Using ATmega328P-AU from Atmel 
* 14 digital input/output pins
* 8 analog input pins labeled A0 ~ A7
* TTL level serial pins RX/TX;
* 6 PWM pins (D3, D5, D6, D9, D10, D11)
* Support external DC 7-9V power supply
 
<br>
==TECH SPECS==
{| class="wikitable" cellpadding="1" cellspacing="1"
|-
! scope="row" | Microcontroller
|ATmega328P-AU
|-
! scope="row" | Operating Voltage
| 5V
|-
! scope="row" | Input Voltage (recommended)
| DC7-9V
|-
! scope="row" | Digital I/O Pins
| 14 (D0-D13) (of which 6 provide PWM output)
|-
! scope="row" | PWM Digital I/O Pins
| 6 (D3, D5, D6, D9, D10, D11)
|-
! scope="row" | Analog Input Pins
| 8 (A0-A7)
|-
! scope="row" | DC Current per I/O Pin
| 40 mA
|-
! scope="row" | Flash Memory
| 32 KB of which 2 KB used by bootloader
|-
! scope="row" | SRAM
| 2 KB
|-
! scope="row" | EEPROM
| 1 KB
|-
! scope="row" | Clock Speed
| 16 MHz
|-
! scope="row" | LED_BUILTIN
| D13
|-
|}
 
<br>
==Technical Details==
* '''Dimensions:''' 40mm x 18mm x 14mm
* '''Weight:''' 4.1g
<br>[[Image:KS0247 Details.jpg|700px|frameless]]<br>
<br>[[Image:KS0247 Front.jpg|700px|frameless]]<br>
 
<br>
==Element and Interfaces==
Here is an explanation of what every element and interface of the board does:
<br>[[Image:ks0247 pinout.jpg|800px|frameless]]<br>
 
<br>
==Specialized Functions of Some Pins==
* '''Serial communication:''' 0 (RX) and 1 (TX). Used to receive (RX) and transmit (TX) TTL serial data.
* '''PWM (Pulse-Width Modulation):''' D3, D5, D6, D9, D10, D11
* '''External Interrupts:''' D2 (interrupt 0) and D3 (interrupt 1).
* '''SPI communication:''' D10 (SS), D11 (MOSI), D12 (MISO), D13 (SCK).
* '''IIC communication:'''  A4 (SDA); A5(SCL)
 
<br>
==Detailed Use with ARDUINO Software as follows==
 
===Step1| Download the Arduino IDE===
When you get the board, first you should install the Arduino software and driver. <br>
We usually use the Windows software Arduino 1.5.6 version. You can download it from the link below: <br>
https://www.arduino.cc/en/Main/OldSoftwareReleases#1.5.x<br>
Or you can browse the ARDUINO website to download the latest version from this link, https://www.arduino.cc, pop up the following interface.
<br>[[Image:KS0313-1.png|600px|frameless]]<br>
 
Then click the '''SOFTWARE''' on the browse bar, you will have two options ONLINE TOOLS and DOWNLOADS.
<br>[[Image:KS0313-2.png|600px|frameless]]<br>
 
Click '''DOWNLOADS''', it will appear the latest software version of ARDUINO 1.8.5 shown as below. 
<br>[[Image:KS0313-3.png|600px|frameless]]<br>
 
In this software page, on the right side you can see the version of development software for different operating systems. ARDUINO has a powerful compatibility. You should download the software that is compatible with the operating system of your computer.<br>
We will take '''WINDOWS system''' as an example here. There are also two options under Windows system, one is installed version, the other is non-installed version.
For simple installed version, first click '''Windows Installer''', you will get the following page.<br>
<br>[[Image:KS0313-4.png|600px|frameless]]<br>
<br>[[Image:KS0313-5.png|600px|frameless]]<br>
 
This way you just need to click JUST DOWNLOAD, then click the downloaded file to install it. <br>
For non-installed version, first click Windows ZIP file, you will also get the pop-up interface as the above figure.<br>
Click JUST DOWNLOAD, and when the ZIP file is downloaded well to your computer, you can directly unzip the file and click the icon of ARDUINO software to start it.  <br>
 
<br>
====Installing Arduino (Windows)====
Install Arduino with the exe. Installation package downloaded well.
<br>[[File:Arduino Setup 1.jpg|800px|frameless|thumb]]<br>
 
Click“I Agree”to see the following interface.
<br>[[File:Arduino Setup 2.jpg|800px|frameless|thumb]]<br>
 
Click “Next”. Pop up the interface below.
<br>[[File:Arduino Setup 3.jpg|800px|frameless|thumb]]<br>
 
You can press Browse… to choose an installation path or directly type in the directory you want.<br>
Then click “Install” to initiate installation.
<br>[[File:Arduino Setup 4.jpg|800px|frameless|thumb]]<br>
 
Wait for the installing process, if appear the interface of Window Security, just continue to click Install to finish the installation.
<br>[[File:Arduino1.5.6- setup 5.png|800px|frameless|thumb]]<br>
 
<br>
====Introduction for Arduino IDE Toolbar====
Double-click the icon of Arduino software downloaded well, you will get the interface shown below.
<br>[[Image:Ks0313图片1.png|600px|frameless]]<br>
('''Note:''' if the Arduino software loads in the wrong language, you can change it in the preferences dialog. See [https://www.arduino.cc/en/Guide/Environment-Languages the environment page] for details.)
<br>[[Image:717.png|600px|frameless]]<br>
<br>
The functions of each button on the Toolbar are listed below:
<br>[[Image:IDE.png|600px|frameless]]<br>
 
{| class="wikitable" cellpadding="1" cellspacing="1"
|-
!scope="row" |[[Image:IDE 1.png|600px|frameless]] Verify/Compile
| Check the code for errors
|-
!scope="row" |[[Image:IDE 2.png|600px|frameless]] Upload
| Upload the current Sketch to the Arduino
|-
!scope="row" |[[Image:IDE 3.png|600px|frameless]] New
| Create a new blank Sketch
|-
! scope="row" |[[Image:IDE 4.png|600px|frameless]] Open
| Show a list of Sketches
|-
! scope="row" |[[Image:IDE 5.png|600px|frameless]] Save
| Save the current Sketch
|-
! scope="row" |[[Image:IDE 6.png|600px|frameless]] Serial Monitor
| Display the serial data being sent from the Arduino
|-
|}
 
<br>
<br>


==Specifications ==
===Step2| Connect a USB to Serial Module===
* Fourteen digital input/output ports;
To program the Pro Mini board, you will need to connect an external USB to Serial module. Different USB to Serial modules might have different driver installation. In the following, we will introduce the use of pro mini with our [http://www.keyestudio.com/ks0277.html keyestudio FTDI Basic Program Downloader]. <br>
See more details [http://wiki.keyestudio.com/index.php/Ks0277_keyestudio_FTDI_Basic_Program_Downloader_USB_to_TTLFT232 here].
<br>[[Image:Ks0277 FTDI Basic Program Downloader.png|600px|frameless]]<br>


* Eight analog input ports A0 ~ A7;
<br>
====Download the Driver Files====
[[Image:driver file- KS0247.png|600px|frameless]]<br>
You can download the driver file from the link below:<br>
https://drive.google.com/open?id=1vj4Is2LokXf3GDGcnumnAPmaI39uPhQk


* One pair of TTL level serial port RX/TX;
<br>
====Installing the Driver ====
The USB to serial port chip of this control board is FT232RL. So you need to install the driver for the chip. You can click the driver file here [https://drive.google.com/open?id=1vj4Is2LokXf3GDGcnumnAPmaI39uPhQk  ft232r usb uart driver] to download it.<br>
In different systems, the driver installation is similar. Here we start to install the driver on the Win7 system.<br>
Plug one end of your USB cable into the module and the other into a USB socket on your computer. <br>
<br>[[Image:图片1-module.png|600px|frameless]]<br>
<br>
When you connect the module to your computer at the first time, right click your “Computer” —>for “Properties”—> click the “Device manager”, under Other devices, you should see the “USB Serial Port”.
<br>[[Image:KS0247- DRIVER 1.png|600px|frameless]]<br>


* Six PWM ports, D3, D5, D6, D9, D10, D11
Then right-click on the device and select the top menu option (Update Driver Software...) shown as the figure below.. 
<br>[[Image:KS0247- DRIVER 2.png|600px|frameless]]<br>


* Using Atmel atmega328p-AU Uno
Then it will be prompted to either “Search Automatically forupdated driversoftware” or “Browse my computer for driver software”. Shown as below. In this page, select “Browse my computer for driver software”.
<br>[[Image:KS0247- DRIVER 3.png|600px|frameless]]<br>


* Support external 7-9V Dc power supply
After that, select the option to browseand navigate to the “drivers” folder.
<br>[[Image:KS0247- DRIVER 4.png|600px|frameless]]<br>


== Special Instructions ==
Once the software has been installed, you will get a confirmation message. Installation completed, click “Close”.
The keyestudio pro mini burn program requires the external USB serial port module, such as FT232 module. The wiring method is as the following table.
<br>[[Image:KS0247- DRIVER 5.png|600px|frameless]]<br>
 
Up to now, the driver is installed well. Then you can right click “Computer” —>“Properties”—>“Device manager”, you should see the device as the figure shown below. 
<br>[[Image:KS0247- DRIVER 6.png|600px|frameless]]<br>
 
<br>
 
===Step3| Hookup Guide===
Driver installation completed, disconnect the module to computer, then connect it to pro mini board using F-F jumper wires. Shown below. The slide switch on the module is used to control the voltage for serial communication. Whether it is set to 5V or 3.3V, it can be programmed with the Pro Mini.
<br>[[Image:KS0247 Step3.png|600px|frameless]]<br>
{| class="wikitable" border="1"
{| class="wikitable" border="1"
|-
|-
! Keyestudio pro mini
! FTDI Basic Program Downloader
! FT232 module
! keyestudio pro mini
|-
|-
|GND
|GND
|GND
|GND
|-
|-
|VCC
|5V
|5V
|5V
|-
|-
|RXD
|TXD
|TXD
|RX
|-
|-
|TXD
|RXD
|RXD
|TX
|-
|-
|DTR
|DIR
|DTR
|DIR
|}
Connect well the module to pro mini board, then connect the pro mini board to your computer with a mini USB cable.
 
<br>
 
===Step4| Select the Arduino Board ===
Open the Arduino IDE, you’ll need to click the “Tools”, then select the Board that corresponds to your Arduino.
<br>[[Image:Ks0313图片1.png|600px|frameless]]<br>
<br>[[Image:ks0247 board.png|600px|frameless]]<br>
 
<br>
 
===Step5| Select your serial port===
Select the serial device of the Arduino board from the Tools | Serial Port menu.  <br>
'''Note:''' to avoid errors, the COM Port should keep the same as the Ports shown on Device Manager.
<br>[[Image:KS0247- DRIVER 6.png|600px|frameless]]<br>
<br>[[Image:ks0247 port.png|600px|frameless]]<br>
 
<br>
 
===Step6| Upload the Code===
Below is an example code for displaying the Hello World!<br>
Copy and paste the code to the Arduino environment IDE.<br>
<pre>
int val;
int ledpin=13;
void setup()
{
Serial.begin(9600);
pinMode(ledpin,OUTPUT);
}
void loop()
{
val=Serial.read();
if(val=='R')
{
digitalWrite(ledpin,HIGH);
delay(500);
digitalWrite(ledpin,LOW);
delay(500);
Serial.println("Hello World!");
}
}
</pre>
 
<br>[[Image:ks0247 code.png|600px|frameless]]<br>
<br>
Then click verify button to check the errors. If compiling successfully, the message "Done compiling." will appear in the status bar.
<br>[[Image:KS0247 COMPILE.png|800px|frameless]]<br>
<br>
After that, click the “Upload” button to upload the code. If the upload is successful, the message "Done uploading." will appear in the status bar.
<br>[[Image:KS0247 upload.png|800px|frameless]]<br>
 
<br>
 
 
===Step7| Open the Serial Monitor===
After that, click the button to open the serial monitor.
<br>[[Image:ks0247 monitor 1.png|600px|frameless]]<br>
<br>
Then set the baud rate to 9600, enter an “R” and click Send, that is, the computer will send the character R. When pro mini board receives it, you should see the D13 led flash once. "Hello World!" is sent to the computer, so that you should see the "Hello World!" is showed on the monitor.
<br>[[Image:ks0247 monitor 2.png|700px|frameless]]<br>


|}


<br>
==Resources==
==Resources==


'''Datasheet:'''http://www.keyestudio.com/files/index/download/id/1500368425/
More detailed files in the link:
 
https://fs.keyestudio.com/KS0247
 
 
 
'''You might also want to look at:''' <br>
[http://arduino.cc/en/Reference/HomePage the reference] for the Arduino language;
 
'''Download ARDUINO Software:''' <br>
https://www.arduino.cc/en/Main/OldSoftwareReleases#1.5.x


<br>
==Troubleshooting==
If you have problems, please see the [http://arduino.cc/en/Guide/Troubleshooting troubleshooting suggestions].
<br>
==Get One Now==
==Get One Now==
*[https://www.keyestudio.com/keyestudio-5v-16mhz-promini-original-atmega328p-development-board-for-arduino-diy-projects-p0362.html  '''Official Website''']
*[https://www.amazon.com/dp/B07B2PZFBJ  '''Shop on Amazon''' ]
*[https://www.aliexpress.com/store/product/Free-shipping-funduino-promini-328-Mini-at-mega328-5V-16MHz-for-arduino/1452162_2042220807.html?spm=2114.12010612.8148356.24.215c2ca4rBVE7h  '''Shop on AliExpress''' ]
*[https://www.ebay.com/itm/132717405573  '''Shop on eBay''']


http://www.keyestudio.com/keyestudio-pro-mini.html


[[Category: Arduino Board]]
[[Category: Arduino Board]]

Latest revision as of 10:31, 6 January 2021

Keyestudio Pro Mini


Introduction

keyestudio Pro Mini is a small microcontroller board based on the ATmega328. (datasheet), intended for use on breadboards and when space is at a premium.
It has 14 digital input/output pins (of which 6 can be used as PWM outputs), 8 analog inputs, a 16 MHz crystal oscillator, and a reset button.
Note that the board is without an on-board USB to Serial connection. To program the Pro Mini, you will need an external USB to Serial module.
The keyestudio pro mini can be powered via the pins 5V GND (DC 5V), or female headers Vin GND (DC 7-9V).


Features

  • Using ATmega328P-AU from Atmel
  • 14 digital input/output pins
  • 8 analog input pins labeled A0 ~ A7
  • TTL level serial pins RX/TX;
  • 6 PWM pins (D3, D5, D6, D9, D10, D11)
  • Support external DC 7-9V power supply


TECH SPECS

Microcontroller ATmega328P-AU
Operating Voltage 5V
Input Voltage (recommended) DC7-9V
Digital I/O Pins 14 (D0-D13) (of which 6 provide PWM output)
PWM Digital I/O Pins 6 (D3, D5, D6, D9, D10, D11)
Analog Input Pins 8 (A0-A7)
DC Current per I/O Pin 40 mA
Flash Memory 32 KB of which 2 KB used by bootloader
SRAM 2 KB
EEPROM 1 KB
Clock Speed 16 MHz
LED_BUILTIN D13


Technical Details

  • Dimensions: 40mm x 18mm x 14mm
  • Weight: 4.1g


KS0247 Details.jpg

KS0247 Front.jpg


Element and Interfaces

Here is an explanation of what every element and interface of the board does:
Ks0247 pinout.jpg


Specialized Functions of Some Pins

  • Serial communication: 0 (RX) and 1 (TX). Used to receive (RX) and transmit (TX) TTL serial data.
  • PWM (Pulse-Width Modulation): D3, D5, D6, D9, D10, D11
  • External Interrupts: D2 (interrupt 0) and D3 (interrupt 1).
  • SPI communication: D10 (SS), D11 (MOSI), D12 (MISO), D13 (SCK).
  • IIC communication: A4 (SDA); A5(SCL)


Detailed Use with ARDUINO Software as follows

Step1| Download the Arduino IDE

When you get the board, first you should install the Arduino software and driver.
We usually use the Windows software Arduino 1.5.6 version. You can download it from the link below:
https://www.arduino.cc/en/Main/OldSoftwareReleases#1.5.x
Or you can browse the ARDUINO website to download the latest version from this link, https://www.arduino.cc, pop up the following interface.
KS0313-1.png

Then click the SOFTWARE on the browse bar, you will have two options ONLINE TOOLS and DOWNLOADS.
KS0313-2.png

Click DOWNLOADS, it will appear the latest software version of ARDUINO 1.8.5 shown as below.
KS0313-3.png

In this software page, on the right side you can see the version of development software for different operating systems. ARDUINO has a powerful compatibility. You should download the software that is compatible with the operating system of your computer.
We will take WINDOWS system as an example here. There are also two options under Windows system, one is installed version, the other is non-installed version. For simple installed version, first click Windows Installer, you will get the following page.

KS0313-4.png

KS0313-5.png

This way you just need to click JUST DOWNLOAD, then click the downloaded file to install it.
For non-installed version, first click Windows ZIP file, you will also get the pop-up interface as the above figure.
Click JUST DOWNLOAD, and when the ZIP file is downloaded well to your computer, you can directly unzip the file and click the icon of ARDUINO software to start it.


Installing Arduino (Windows)

Install Arduino with the exe. Installation package downloaded well.
thumb

Click“I Agree”to see the following interface.
thumb

Click “Next”. Pop up the interface below.
thumb

You can press Browse… to choose an installation path or directly type in the directory you want.
Then click “Install” to initiate installation.
thumb

Wait for the installing process, if appear the interface of Window Security, just continue to click Install to finish the installation.
thumb


Introduction for Arduino IDE Toolbar

Double-click the icon of Arduino software downloaded well, you will get the interface shown below.
Ks0313图片1.png
(Note: if the Arduino software loads in the wrong language, you can change it in the preferences dialog. See the environment page for details.)
717.png

The functions of each button on the Toolbar are listed below:
IDE.png

IDE 1.png Verify/Compile Check the code for errors
IDE 2.png Upload Upload the current Sketch to the Arduino
IDE 3.png New Create a new blank Sketch
IDE 4.png Open Show a list of Sketches
IDE 5.png Save Save the current Sketch
IDE 6.png Serial Monitor Display the serial data being sent from the Arduino



Step2| Connect a USB to Serial Module

To program the Pro Mini board, you will need to connect an external USB to Serial module. Different USB to Serial modules might have different driver installation. In the following, we will introduce the use of pro mini with our keyestudio FTDI Basic Program Downloader.
See more details here.
Ks0277 FTDI Basic Program Downloader.png


Download the Driver Files

Driver file- KS0247.png
You can download the driver file from the link below:
https://drive.google.com/open?id=1vj4Is2LokXf3GDGcnumnAPmaI39uPhQk


Installing the Driver

The USB to serial port chip of this control board is FT232RL. So you need to install the driver for the chip. You can click the driver file here ft232r usb uart driver to download it.
In different systems, the driver installation is similar. Here we start to install the driver on the Win7 system.
Plug one end of your USB cable into the module and the other into a USB socket on your computer.

图片1-module.png

When you connect the module to your computer at the first time, right click your “Computer” —>for “Properties”—> click the “Device manager”, under Other devices, you should see the “USB Serial Port”.
KS0247- DRIVER 1.png

Then right-click on the device and select the top menu option (Update Driver Software...) shown as the figure below..
KS0247- DRIVER 2.png

Then it will be prompted to either “Search Automatically forupdated driversoftware” or “Browse my computer for driver software”. Shown as below. In this page, select “Browse my computer for driver software”.
KS0247- DRIVER 3.png

After that, select the option to browseand navigate to the “drivers” folder.
KS0247- DRIVER 4.png

Once the software has been installed, you will get a confirmation message. Installation completed, click “Close”.
KS0247- DRIVER 5.png

Up to now, the driver is installed well. Then you can right click “Computer” —>“Properties”—>“Device manager”, you should see the device as the figure shown below.
KS0247- DRIVER 6.png


Step3| Hookup Guide

Driver installation completed, disconnect the module to computer, then connect it to pro mini board using F-F jumper wires. Shown below. The slide switch on the module is used to control the voltage for serial communication. Whether it is set to 5V or 3.3V, it can be programmed with the Pro Mini.
KS0247 Step3.png

FTDI Basic Program Downloader keyestudio pro mini
GND GND
5V 5V
TXD RX
RXD TX
DIR DIR

Connect well the module to pro mini board, then connect the pro mini board to your computer with a mini USB cable.


Step4| Select the Arduino Board

Open the Arduino IDE, you’ll need to click the “Tools”, then select the Board that corresponds to your Arduino.
Ks0313图片1.png

Ks0247 board.png


Step5| Select your serial port

Select the serial device of the Arduino board from the Tools | Serial Port menu.
Note: to avoid errors, the COM Port should keep the same as the Ports shown on Device Manager.
KS0247- DRIVER 6.png

Ks0247 port.png


Step6| Upload the Code

Below is an example code for displaying the Hello World!
Copy and paste the code to the Arduino environment IDE.

int val; 
int ledpin=13; 
void setup()
{
Serial.begin(9600); 
pinMode(ledpin,OUTPUT);
}
void loop()
{
val=Serial.read();
if(val=='R')
{
digitalWrite(ledpin,HIGH);
delay(500);
digitalWrite(ledpin,LOW);
delay(500);
Serial.println("Hello World!");
}
}


Ks0247 code.png

Then click verify button to check the errors. If compiling successfully, the message "Done compiling." will appear in the status bar.
KS0247 COMPILE.png

After that, click the “Upload” button to upload the code. If the upload is successful, the message "Done uploading." will appear in the status bar.
KS0247 upload.png



Step7| Open the Serial Monitor

After that, click the button to open the serial monitor.
Ks0247 monitor 1.png

Then set the baud rate to 9600, enter an “R” and click Send, that is, the computer will send the character R. When pro mini board receives it, you should see the D13 led flash once. "Hello World!" is sent to the computer, so that you should see the "Hello World!" is showed on the monitor.
Ks0247 monitor 2.png



Resources

More detailed files in the link:

https://fs.keyestudio.com/KS0247


You might also want to look at:
the reference for the Arduino language;

Download ARDUINO Software:
https://www.arduino.cc/en/Main/OldSoftwareReleases#1.5.x



Troubleshooting

If you have problems, please see the troubleshooting suggestions.



Get One Now