Home  |  Contents 

Microcontroller and PC projects
  Forum Index : Microcontroller and PC projects         Section
Subject Topic: Armmite - STM32H7: Developments Post ReplyPost New Topic
<< Prev Page of 3
Author
Message << Prev Topic | Next Topic >>
matherp
Guru
Guru


Joined: 11 December 2012
Location: United Kingdom
Online Status: Offline
Posts: 2115
Posted: 21 June 2018 at 4:45am | IP Logged Quote matherp

One more release today (good progress ) 5.04.14 but don't miss details of 5.04.13 on page 2 of the thread.

2018-06-21_044222_Armmite.zip

This includes serial port support. There are 4 H/W serial ports (in addition to the console) with full H/W interrupt support. All functionality is implemented as per the MM+ with the exception of RS485 support (to come later). By default the RX pins are pulled high but this can be disabled with:

OPTION SERIAL PULLUP DISABLE


and re-enabled with:

OPTION SERIAL PULLUP ENABLE


pins are:

COM1_TX_PIN         101 //PA9 
COM1_RX_PIN         76  //PB15
COM2_TX_PIN         36  //PA2 
COM2_RX_PIN         37  //PA3
COM3_TX_PIN         136 //PB6 
COM3_RX_PIN         73  //PB12
COM4_TX_PIN         110 //PA15
COM4_RX_PIN         18  //PF6


This just leaves PWM and analogue input to code and the STM32 will be close to the MMX in functionality.

Edited by matherp on 21 June 2018 at 4:46am



Back to Top View matherp's Profile Search for other posts by matherp
 
goc30
Regular Member
Regular Member
Avatar

Joined: 12 April 2017
Location: France
Online Status: Offline
Posts: 62
Posted: 21 June 2018 at 8:38am | IP Logged Quote goc30

Very very GOOD JOB!!

I don't understand STM Nucleo logic
For com1, they have not connected pins with D0/D1 Arduino who is used as "hardware serial" in many shields

Back to Top View goc30's Profile Search for other posts by goc30
 
matherp
Guru
Guru


Joined: 11 December 2012
Location: United Kingdom
Online Status: Offline
Posts: 2115
Posted: 21 June 2018 at 5:37pm | IP Logged Quote matherp

Quote:
I don't understand STM Nucleo logic
For com1, they have not connected pins with D0/D1 Arduino who is used as "hardware serial" in many shields


That is my allocation - I'll change it so COM4 is on those pins. I'll also change I2C so it is on the normal Arduino pins - watch this space
Back to Top View matherp's Profile Search for other posts by matherp
 
goc30
Regular Member
Regular Member
Avatar

Joined: 12 April 2017
Location: France
Online Status: Offline
Posts: 62
Posted: 22 June 2018 at 12:14am | IP Logged Quote goc30

No, you have good idea to use this pins, I have think that STM connect d0/d1 on UART1 rx/tx but no, they are connected on signals PG6/PG14 as USART6 (and also SPI1 )
Back to Top View goc30's Profile Search for other posts by goc30
 
matherp
Guru
Guru


Joined: 11 December 2012
Location: United Kingdom
Online Status: Offline
Posts: 2115
Posted: 22 June 2018 at 7:58am | IP Logged Quote matherp

Please find attached V5.04.15

2018-06-22_173716_Armmite.zip

This has some pin changes as follows (puts com4 and I2C onto the Arduino header):

COM1_TX_PIN         101 //PA9 USART1
COM1_RX_PIN         76  //PB15

COM2_TX_PIN         36  //PA2 USART2
COM2_RX_PIN         37  //PA3
COM2_EN_PIN         118 //PD4

COM3_TX_PIN         136 //PB6 UART5
COM3_RX_PIN         73  //PB12

COM4_TX_PIN         129 //PG14 USART6
COM4_RX_PIN         124 //PG9

I2C_SCL           139 //PB8
I2C_SDA           140 //PB9



Note that COM2 now supports an enable pin (active high) for driving RS485 transceivers. This is enable by adding "DE" to the open command - see example below:

There are also changes to the other parameters for opening serial ports.

"9BIT" is no longer valid - do not use

"ODD" adds an odd parity bit (making 9 bits if normal 8-bit data is sent)

"EVEN" adds an even parity bit (making 9 bits if normal 8-bit data is sent)

"7BIT" reduces the data to seven bits (total of eight if parity is specified)

other parameters (INV, S2, OC) are as the MM manual

In addition you can now specify a transmit completion interrupt as well as a receive interrupt. This works on any of the 4 com ports - see the example.
This example outputs a "proper" modbus RTU message (8 data bits + even parity)





Open "com2:9600, 1024, myrxint, 256, mytxint, de, even" As #1
For i=2220 To 2400
Print #1,Str$(i,4)+" ";
Next i
Print #1,""
Do
Loop Until k=1
close #1
end

Sub myrxint
End Sub

Sub mytxint
Print "TXcomplete"
k=1
End Sub




Edited by matherp on 22 June 2018 at 6:10pm
Back to Top View matherp's Profile Search for other posts by matherp
 
goc30
Regular Member
Regular Member
Avatar

Joined: 12 April 2017
Location: France
Online Status: Offline
Posts: 62
Posted: 22 June 2018 at 7:11pm | IP Logged Quote goc30

yesss!!

1000 thanks peter

here pinouts excel sheet with signals names

2018-06-22_191039_NUCLEO-H743ZI-pinout2.zip

I can translate my modbus/gps app on this card

Edited by goc30 on 22 June 2018 at 7:13pm
Back to Top View goc30's Profile Search for other posts by goc30
 
matherp
Guru
Guru


Joined: 11 December 2012
Location: United Kingdom
Online Status: Offline
Posts: 2115
Posted: 22 June 2018 at 10:33pm | IP Logged Quote matherp

Please find attached V5.04.16

2018-06-22_223239_Armmite.zip

This has LONGSTRING, JSON, and background GPS functionality as per the MMX (see MMX manual for details).

In addition RTC SETTIME is removed. Setting the STM32 RTC is done by setting TIME$ and DATE$. the day of the week is automatically calculated for the date and will always be available once DATE$ is set by using the DAY$ function. If the battery backup to the STM32 RTC is connected (remove SB156 first) then the time and date will be correct immediately on power up.

Back to Top View matherp's Profile Search for other posts by matherp
 


If you wish to post a reply to this topic you must first login
If you are not already registered you must first register

  Search the forums using Google.
<< Prev Page of 3
In the news...
 
Post ReplyPost New Topic
Printable version Printable version
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You cannot vote in polls in this forum

Powered by Web Wiz Forums version 7.8
Copyright ©2001-2004 Web Wiz Guide

This page was generated in 0.1094 seconds.
Privacy Policy     Process times : 0, 0, 0, 0.11