Actions

Difference between revisions of "KA-Nucleo-UniExp"

(Schemat elektryczny)
 
(6 intermediate revisions by 3 users not shown)
Line 1: Line 1:
====== Opis ======
+
__jzpdf__
[https://kamami.pl/kamod-kamami/234527-ka-nucleo-uniexp-ekspander-shield-zgodny-z-arduinonucleo-z-bluetooth-20edr-mems-lis35d-i-czujnikiem-temperatury.html KA-Nucleo-UniExp] to wielofunkcyjny ekspander (shield) dla NUCLEO i Arduino wyposażony w interfejs Bluetooth 2.0+EDR (HC-05), MEMS 3DoF LIS35, LED-RGB, joystickiem i analogowym czujnikiem temperatury STLM20 opracowany i produkowany przez firmę KAMAMI.
+
====== Description ======
 
+
[https://kamami.pl/kamod-kamami/234527-ka-nucleo-uniexp-ekspander-shield-zgodny-z-arduinonucleo-z-bluetooth-20edr-mems-lis35d-i-czujnikiem-temperatury.html KA-Nucleo-UniExp] is a multifunctional expander (shield) for NUCLEO and Arduino boards. It is equipped with Bluetooth 2.0+EDR interface (HC-05), MEMS 3DoF LIS35, LED-RGB, joystick and analog temperature sensor STLM20, which was developed and produced by KAMAMI company.  
 +
 
<center>
 
<center>
[[Plik:KA-Nucleo-UniExp_modul.jpg|none|400px|thumb|center]]
+
[[File:KA-Nucleo-UniExp_modul.jpg|none|400px|thumb|center]]
 
</center>
 
</center>
  
===== Podstawowe cechy i parametry =====
+
===== Basic features and parameters =====
*Zgodność z systemami NUCLEO i Arduino
+
*Compatibility with NUCLEO and Arduino systems
*Wbudowany moduł Bluetooth v2.0+EDR o parametrach:
+
*Embedded Bluetooth v2.0+EDR module with parameters:
**Profil SPP (Serial Port Protocol)
+
**SPP Profile (Serial Port Protocol)
**Prędkość transmisji asynchronicznej do 2,1 Mb/s
+
**Asynchronous transmission speed up to 2,1 Mb/s
**Prędkość transmisji synchronicznej do 1 Mb/s
+
**Synchronous transmission speed up to 1 Mb/s
*Wbudowany akcelerometr MEMS 3D z I2C
+
*Embedded MEMS 3D accelerometer with I2C interface:
**Sprzętowy selektor adresu na magistrali
+
** Hardware address selector on bus
**Zakres pomiarowy +/-2g lub +/-8gMaksymalna częstotliwość pomiarów 100/400 Hz
+
**Measurement range +/-2g or +/-8g
*Wbudowany czujnik temperatury z wyjściem analogowym (-40…+85°C)
+
**Maximum measurement data rate 100/400 Hz
*Wbudowana LED RGB
+
*On-board temperature sensor with analog output (-40…+85°C)
*Wbudowany joystick 5-stykowy
+
*On-board LED RGB
*Przedłużone złącza szpilkowe
+
*On-board 5-way joystick
 +
*Extended pins connector
  
===== Wyposażenie standardowe =====
+
===== Standard equipment=====
 
<center>
 
<center>
{| class="wikitable" style="width: 1000px;"
+
{| class="wikitable" style="width: 1000px;"
 
|-
 
|-
! style="text-align: center;"|Kod
+
! style="text-align: center;"| Code
! style="text-align: center;"|Opis
+
! style="text-align: center;"| Description
 
|-
 
|-
 
| style="text-align: center;"|<b>KA-Nucleo-UniExp</b>
 
| style="text-align: center;"|<b>KA-Nucleo-UniExp</b>
 
| style="text-align: center;"|
 
| style="text-align: center;"|
*Zmontowany i uruchomiony moduł
+
* Assembled and launched module
 
|}
 
|}
 
</center>
 
</center>
  
===== Schemat elektryczny =====
+
===== Electrical schematics=====
 
<center>
 
<center>
[[Plik:KA-Nucleo-UniExp_schemat.png|none|800px|thumb|center]]
+
[[File:KA-Nucleo-UniExp_schemat.png|none|800px|thumb|center]]
 
</center>
 
</center>
  
===== Widok płytki =====
+
===== Board view=====
 
<center>
 
<center>
[[Plik:KA-Nucleo-UniExp_obrys.png|none|300px|thumb|center]]
+
[[File:KA-Nucleo-UniExp_obrys.png|none|300px|thumb|center]]
 
</center>
 
</center>
  
===== Czujnik temperatury =====
+
===== Temperature sensor =====
W ekspanderze zastosowano półprzewodnikowy czujnik temperatury STLM20 z wyjściem analogowym. Napięcie na wyjściu czujnika zmienia się zgodnie ze wzorem:
+
In expander was applied a semiconductor temperature sensor STLM20 with analog output. Output voltage level is changing according to the equation:
 
<center>
 
<center>
{| class="wikitable" style="width: 300px;"
+
{| class="wikitable" style="width: 300px;"
 
|-
 
|-
 
! style="text-align: center;"|Vo = (–11,69mV)/°C × T + 1,8663V [V]
 
! style="text-align: center;"|Vo = (–11,69mV)/°C × T + 1,8663V [V]
 
|}
 
|}
 
</center>
 
</center>
gdzie:
+
where:
*T - temperatura zmierzona przez czujnik
+
*T - temperature measured by sensor
*Vo – napięcie na wyjściu czujnika
+
*Vo – voltage on sensor output
  
Mierzona temperatura ma więc wartość:
+
Measured temperature has then value:
 
<center>
 
<center>
{| class="wikitable" style="width: 300px;"
+
{| class="wikitable" style="width: 300px;"
 
|-
 
|-
 
! style="text-align: center;"|T=(1,8663−Vo)/0,01169 [°C]
 
! style="text-align: center;"|T=(1,8663−Vo)/0,01169 [°C]
 
|}
 
|}
 
</center>
 
</center>
Wyjście czujnika temperatury dołączono do linii A2, która spełnia rolę kanału wejściowego ADC_IN4 (linia GPIO PA4 w STM32)
+
Output of temperature sensor is connected to A2 line, which is used as input canal of ADC_IN4 (GPIO PA4 pin in STM32).
 
<center>
 
<center>
[[Plik:KA-Nucleo-UniExp_czujnik_temp.png|none|500px|thumb|center]]
+
[[File:KA-Nucleo-UniExp_czujnik_temp.png|none|500px|thumb|center]]
 
</center>
 
</center>
  
===== Interfejs Bluetooth =====
+
===== Bluetooth interface=====
W ekspanderze zastosowano moduł Bluetooth HC-05, komunikujący się z mikrokontrolerem za pomocą interfejsu
+
In expander was applied Bluetooth HC-05 module. It communicates with microcontroller via UART interface (UART1 in STM32). How it is connected to microcontroller STM32, was presented in table below.
UART (UART1 w STM32). Sposób dołączenia modułu do mikrokontrolera STM32 przedstawiono w tabeli poniżej.
 
 
<center>
 
<center>
{| class="wikitable" style="width: 1000px;"
+
{| class="wikitable" style="width: 1000px;"
 
|-
 
|-
! style="text-align: center;"|Linie HC-05
+
! style="text-align: center;"| HC-05 lines
! style="text-align: center;"|Nazwa linii
+
! style="text-align: center;"|Line name
! style="text-align: center;"|GPIO w STM32
+
! style="text-align: center;"|GPIO in STM32
! style="text-align: center;"|Interfejs STM32
+
! style="text-align: center;"| STM32 interface
  
 
|-
 
|-
Line 106: Line 107:
  
  
Mikroswitch Sw1 służy do przełączania trybu pracy modułu, w tym wprowadzania w tryb AT. Zalecanym sposobem
+
Micro switch Sw1 is used for module work mode switching, including entering in AT mode. Recommended method of switching module in AT mode is to push and hold Sw1 before power supply enabled (interface UART works therefore with speed 38400 b/s). Module signalizes entering in this mode by LED D1 blinking with frequency 1 Hz. High state on KEY output of module can be forced from microcontroller program (PA0/A0). If LED D1 is blinking with frequency 2 Hz, that means waiting for pairing or completing of pairing process. Ending of pairing process is additional signalized by enabled LED D2.
przełączenia modułu w tryb AT jest wciśnięcie i przytrzymanie Sw1 przed włączeniem zasilania (interfejs UART pracuje
 
wtedy z prędkością 38400 b/s). Moduł sygnalizuje wejście w ten tryb pracy miganiem LED D1 z częstotliwością
 
1 Hz. Wysoki stan na wejściu KEY modułu można wymusić także z poziomu mikrokontrolera (PA0/A0).
 
Jeżeli LED D1 miga z częstotliwością 2 Hz oznacza to oczekiwanie na sparowanie lub poprawne sparowanie, które
 
dodatkowo jest sygnalizowane za pomocą świecenia LED D2.
 
  
 
<center>
 
<center>
[[Plik:KA-Nucleo-UniExp_bluetooth.png|none|600px|thumb|center]]
+
[[File:KA-Nucleo-UniExp_bluetooth.png|none|600px|thumb|center]]
 
</center>
 
</center>
  
===== Akcelerometr MEMS 3D =====
+
===== MEMS 3D accelerometer=====
Ekspander jest wyposażony w akcelerometr MEMS 3D (LIS35DE), komunikujący się z mikrokontrolerem za pomocą
+
Expander is equipped with MEMS 3D accelerometer (LIS35DE). It use for communication with microcontroller I2C interface (I2C1 canal in STM32). How it is connected to microcontroller STM32, was presented in table below.
magistrali I2C (kanał I2C1 w STM32). Sposób dołączenia akcelerometru pokazano w tabeli poniżej.  
 
 
<center>
 
<center>
{| class="wikitable" style="width: 1000px;"
+
{| class="wikitable" style="width: 1000px;"
 
|-
 
|-
! style="text-align: center;"|Linie LIS35DE
+
! style="text-align: center;"| LIS35DE lines
! style="text-align: center;"|Nazwa linii
+
! style="text-align: center;"|Line name
! style="text-align: center;"|GPIO w STM32
+
! style="text-align: center;"|GPIO in STM32
! style="text-align: center;"|Interfejs STM32
+
! style="text-align: center;"|STM32 interface
! style="text-align: center;"|Uwagi
+
! style="text-align: center;"|Comments
  
 
|-
 
|-
Line 134: Line 129:
 
| style="text-align: center;"|PB8
 
| style="text-align: center;"|PB8
 
| style="text-align: center;"|SCL/I2C1
 
| style="text-align: center;"|SCL/I2C1
| rowspan="2" style="text-align: center;"|Linie podciągnięte do plusa zasilania rezystorami 4,7 kΩ
+
| rowspan="2" style="text-align: center;"| Lines was pulled up to power supply lines by 4,7 kΩ resistors
  
 
|-
 
|-
Line 157: Line 152:
 
|}
 
|}
 
</center>
 
</center>
Akcelerometr zastosowany w zestawie ma następujący adres bazowy na magistrali I2C: 001110xb. Symbol „x”
+
Accelerometer used in set has basic address on I2C bus: 001110xb. „x” symbol means „0” or „1” depending on the JP1 jumper position. Communication lines of I2C interface was pulled up to power supply by using by 4,7 kΩ resistors.
oznacza „0” lub „1” w zależności od położenia zwory JP1.
 
Linie komunikacyjne magistrali I2C są podciągnięte do plusa zasilania za pomocą rezystorów 4,7kΩ.
 
 
<center>
 
<center>
[[Plik:KA-Nucleo-UniExp_akcelerometr.png|none|600px|thumb|center]]
+
[[File:KA-Nucleo-UniExp_akcelerometr.png|none|600px|thumb|center]]
 
</center>
 
</center>
 
<center>
 
<center>
{| class="wikitable" style="width: 500px;"
+
{| class="wikitable" style="width: 500px;"
 
|-
 
|-
! style="text-align: center;"|Zwarte styki JP1
+
! style="text-align: center;"|Closed pins JP1
! style="text-align: center;"|Adres bazowu U1
+
! style="text-align: center;"|Base address U1
 
! style="text-align: center;"|SA0
 
! style="text-align: center;"|SA0
  
Line 184: Line 177:
  
 
===== LED-RGB =====
 
===== LED-RGB =====
Wbudowane diody LED-RGB są sterowane bezpośrednio z linii GPIO mikrokontrolera zgodnie z tabelą poniżej.
+
On-board LED-RGB are controlled direct with GPIO pins of microcontroller (according to table below). Diodes are on, if state of control line has logical state „0”.
Diody świecą jeżeli na linii sterującej jest stan logiczny „0”.)
 
 
<center>
 
<center>
{| class="wikitable" style="width: 1000px;"
+
{| class="wikitable" style="width: 1000px;"
 
|-
 
|-
! style="text-align: center;"|Dioda LED
+
! style="text-align: center;"| LED
! style="text-align: center;"|Nazwa linii
+
! style="text-align: center;"|Line name
! style="text-align: center;"|GPIO w STM32
+
! style="text-align: center;"|GPIO in STM32
! style="text-align: center;"|Uwagi
+
! style="text-align: center;"|Comments
  
 
|-
 
|-
Line 198: Line 190:
 
| style="text-align: center;"|D12
 
| style="text-align: center;"|D12
 
| style="text-align: center;"|PA6
 
| style="text-align: center;"|PA6
| rowspan="3" style="text-align: center;"|LED świecą, gdy stan na liniach GPIO jest "0"
+
| rowspan="3" style="text-align: center;"| LEDs are on, if state on GPIO pins is „0”
  
 
|-
 
|-
Line 204: Line 196:
 
| style="text-align: center;"|D11
 
| style="text-align: center;"|D11
 
| style="text-align: center;"|PA7
 
| style="text-align: center;"|PA7
 
  
 
|-
 
|-
Line 214: Line 205:
 
</center>
 
</center>
 
<center>
 
<center>
[[Plik:KA-Nucleo-UniExp_LED_RGB.png|none|600px|thumb|center]]
+
[[File:KA-Nucleo-UniExp_LED_RGB.png|none|600px|thumb|center]]
 
</center>
 
</center>
  
 
===== Joystick =====
 
===== Joystick =====
Wbudowany w ekspander 5-stykowy joystick jest dołączony bezpośrednio do linii GPIO mikrokontrolera zgodnie
+
Embedded 5-way tact switch is connected direct to GPIO pins of microcontroller (according to table below). Each of pins are pulled up to power supply by using 10 kΩ resistor.
z tabelą poniżej. Każda linia jest podciągnięta do plusa zasilania za pomocą rezystora 10 kΩ.
 
 
<center>
 
<center>
{| class="wikitable" style="width: 1000px;"
+
{| class="wikitable" style="width: 1000px;"
 
|-
 
|-
! style="text-align: center;"|Kierunek joysticka
+
! style="text-align: center;"|Joysticka direction
! style="text-align: center;"|Nazwa linii
+
! style="text-align: center;"|Line name
! style="text-align: center;"|GPIO w STM32
+
! style="text-align: center;"|GPIO in STM32
! style="text-align: center;"|Uwagi
+
! style="text-align: center;"|Comments
  
 
|-
 
|-
| style="text-align: center;"|Góra
+
| style="text-align: center;"|Up
 
| style="text-align: center;"|D4
 
| style="text-align: center;"|D4
 
| style="text-align: center;"|PB5
 
| style="text-align: center;"|PB5
| rowspan="5" style="text-align: center;"|Linie podciągnięte do plusa zasilania rezystorami 10 kΩ  
+
| rowspan="5" style="text-align: center;"| Lines pulled up to power supply by 10 kΩ resistor
 
 
 
|-
 
|-
| style="text-align: center;"|Dół
+
| style="text-align: center;"|Down
 
| style="text-align: center;"|D10
 
| style="text-align: center;"|D10
 
| style="text-align: center;"|PB6
 
| style="text-align: center;"|PB6
  
 
|-
 
|-
| style="text-align: center;"|Lewo
+
| style="text-align: center;"|Left
 
| style="text-align: center;"|D3
 
| style="text-align: center;"|D3
 
| style="text-align: center;"|PB3
 
| style="text-align: center;"|PB3
  
 
|-
 
|-
| style="text-align: center;"|Prawo
+
| style="text-align: center;"|Right
 
| style="text-align: center;"|D5
 
| style="text-align: center;"|D5
 
| style="text-align: center;"|PB4
 
| style="text-align: center;"|PB4
Line 257: Line 246:
 
</center>
 
</center>
 
<center>
 
<center>
[[Plik:KA-Nucleo-UniExp_joystick.png|none|600px|thumb|center]]
+
[[File:KA-Nucleo-UniExp_joystick.png|none|600px|thumb|center]]
 
</center>
 
</center>
  
===== Mapa przypisań linii GPIO =====
+
===== Signal connections map of GPIO pins =====
 
<center>
 
<center>
[[Plik:KA-Nucleo-UniExp mapa GPIO.png|none|1000px|thumb|center]]
+
[[File:KA-Nucleo-UniExp mapa GPIO.png|none|1000px|thumb|center]]
 
</center>
 
</center>
 
[[Kategoria:Moduły peryferyjne KAmod (Kamami)]]
 
[[Kategoria:Zawartość]]
 

Latest revision as of 11:49, 22 September 2020

Description

KA-Nucleo-UniExp is a multifunctional expander (shield) for NUCLEO and Arduino boards. It is equipped with Bluetooth 2.0+EDR interface (HC-05), MEMS 3DoF LIS35, LED-RGB, joystick and analog temperature sensor STLM20, which was developed and produced by KAMAMI company.

KA-Nucleo-UniExp modul.jpg
Basic features and parameters
  • Compatibility with NUCLEO and Arduino systems
  • Embedded Bluetooth v2.0+EDR module with parameters:
    • SPP Profile (Serial Port Protocol)
    • Asynchronous transmission speed up to 2,1 Mb/s
    • Synchronous transmission speed up to 1 Mb/s
  • Embedded MEMS 3D accelerometer with I2C interface:
    • Hardware address selector on bus
    • Measurement range +/-2g or +/-8g
    • Maximum measurement data rate 100/400 Hz
  • On-board temperature sensor with analog output (-40…+85°C)
  • On-board LED RGB
  • On-board 5-way joystick
  • Extended pins connector
Standard equipment
Code Description
KA-Nucleo-UniExp
  • Assembled and launched module
Electrical schematics
KA-Nucleo-UniExp schemat.png
Board view
KA-Nucleo-UniExp obrys.png
Temperature sensor

In expander was applied a semiconductor temperature sensor STLM20 with analog output. Output voltage level is changing according to the equation:

Vo = (–11,69mV)/°C × T + 1,8663V [V]

where:

  • T - temperature measured by sensor
  • Vo – voltage on sensor output

Measured temperature has then value:

T=(1,8663−Vo)/0,01169 [°C]

Output of temperature sensor is connected to A2 line, which is used as input canal of ADC_IN4 (GPIO PA4 pin in STM32).

KA-Nucleo-UniExp czujnik temp.png
Bluetooth interface

In expander was applied Bluetooth HC-05 module. It communicates with microcontroller via UART interface (UART1 in STM32). How it is connected to microcontroller STM32, was presented in table below.

HC-05 lines Line name GPIO in STM32 STM32 interface
Tx D2 PA10 UART1/RxD
Rx D8 PA9 UART1/TxD
KEY A0 PA0 -
RESET nRST nRES -


Micro switch Sw1 is used for module work mode switching, including entering in AT mode. Recommended method of switching module in AT mode is to push and hold Sw1 before power supply enabled (interface UART works therefore with speed 38400 b/s). Module signalizes entering in this mode by LED D1 blinking with frequency 1 Hz. High state on KEY output of module can be forced from microcontroller program (PA0/A0). If LED D1 is blinking with frequency 2 Hz, that means waiting for pairing or completing of pairing process. Ending of pairing process is additional signalized by enabled LED D2.

KA-Nucleo-UniExp bluetooth.png
MEMS 3D accelerometer

Expander is equipped with MEMS 3D accelerometer (LIS35DE). It use for communication with microcontroller I2C interface (I2C1 canal in STM32). How it is connected to microcontroller STM32, was presented in table below.

LIS35DE lines Line name GPIO in STM32 STM32 interface Comments
SCL D15 PB8 SCL/I2C1 Lines was pulled up to power supply lines by 4,7 kΩ resistors
SDA D14 PB9 SDA/I2C1
INT1 A1 PA1 - -
INT2 D7 PA8 - -

Accelerometer used in set has basic address on I2C bus: 001110xb. „x” symbol means „0” or „1” depending on the JP1 jumper position. Communication lines of I2C interface was pulled up to power supply by using by 4,7 kΩ resistors.

KA-Nucleo-UniExp akcelerometr.png
Closed pins JP1 Base address U1 SA0
1-2 0011101b 1
2-3 0011100b 0
LED-RGB

On-board LED-RGB are controlled direct with GPIO pins of microcontroller (according to table below). Diodes are on, if state of control line has logical state „0”.

LED Line name GPIO in STM32 Comments
Red D12 PA6 LEDs are on, if state on GPIO pins is „0”
Green D11 PA7
Blue A3 PB0
KA-Nucleo-UniExp LED RGB.png
Joystick

Embedded 5-way tact switch is connected direct to GPIO pins of microcontroller (according to table below). Each of pins are pulled up to power supply by using 10 kΩ resistor.

Joysticka direction Line name GPIO in STM32 Comments
Up D4 PB5 Lines pulled up to power supply by 10 kΩ resistor
Down D10 PB6
Left D3 PB3
Right D5 PB4
OK D6 PB10
KA-Nucleo-UniExp joystick.png
Signal connections map of GPIO pins
KA-Nucleo-UniExp mapa GPIO.png