Home
JAQForum Ver 24.01
Log In or Join  
Active Topics
Local Time 02:06 13 Nov 2025 Privacy Policy
Jump to

Notice. New forum software under development. It's going to miss a few functions and look a bit ugly for a while, but I'm working on it full time now as the old forum was too unstable. Couple days, all good. If you notice any issues, please contact me.

Forum Index : Microcontroller and PC projects : Armmite H7 V5.05.07: 480MHz support

Author Message
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 10572
Posted: 01:30pm 25 Jun 2019
Copy link to clipboard 
Print this post



2019-06-25_212718_Armmite1.3bin.zip

2019-06-25_212732_Armmite1.3hex.zip

2019-06-25_212755_Armmite_H7_Manual.pdf

Note: If you overclock and the processor doesn't run you will need to re-flash. Other ways of resetting can't work in this case. The test above was run on a V1 Nucleo so only specced for 400MHz but ran fine at 540MHz!!!
 
HardingJohn

Regular Member

Joined: 28/07/2017
Location: Australia
Posts: 78
Posted: 09:31pm 25 Jun 2019
Copy link to clipboard 
Print this post

Well done Peter,
How you find the time to achieve so much is bewildering!

Obviously the comm port serial data rates will not be affected?

It will be interesting to see how fast the 480Mhz chip will run.
The chip is likely to overheat and fail, one would presume?

Thanks so much

John
Just know enough to get me in trouble, but not quite enough to get me out.
 
KeepIS

Guru

Joined: 13/10/2014
Location: Australia
Posts: 1945
Posted: 01:22am 26 Jun 2019
Copy link to clipboard 
Print this post

I'm waiting for connectors before I can run the V2 board, for fun I tried to see if the V1 board would overclock as your unit did.

I decided to test with my full CNC controller program, everything worked except for the USB Keyboard, the console allowed me to change back to 400. Max Speed before the USB Keyboard stops is 420.

However the controller runs everything fine even at 480Mhz. No real advantage though so it's back at 400.

Why did I bother posting?

Yes I know I'm overclocking.
Yes I know I can't expect it to work without problems.
Yes I know I should not do this as the Processor may explode and I could die.
Yes to any other reason that someone on the forum will be so eager to point out.

I posted this just as a heads up for the rare possibility that a timing parameter effecting the USB port may be hidden away and the USB problem my not be entirely related to my stupidity in overclocking the V1 from 400 to 420Mhz for a test.

Mike.
Edited by KeepIS 2019-06-27
NANO Inverter: Full download - Only Hex Ver 8.1Ks
 
SiNut
Newbie

Joined: 12/03/2015
Location: United States
Posts: 12
Posted: 04:44am 26 Jun 2019
Copy link to clipboard 
Print this post

Peter, thanks for the updated firmware with ability to change CPU clock rate on the ARMmiteH7.

I can push the clock rate on my NUCLEO-H743ZI2 to 560MHz. However it is does not boot at 580MHz or 600MHz.

-- Gurbir






 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 10572
Posted: 07:34am 26 Jun 2019
Copy link to clipboard 
Print this post

  Quote  Max Speed before the USB Keyboard stops is 420


That is interesting and shouldn't be the case. USB uses a completely separate 48MHz clock from the processor which is not affected by the processor speed. What happens if you run at say 200MHz?

If that works then my guess would be that the extra heat generated running > 400MHz is causing the 48MHz RC clock to move frequency enough to break USB timings, but it is only a guess.

UPDATE

Try this minor tweak - keyboard tested and works for me at 100, 400, 480 and 540 on V1

2019-06-26_181438_Armmite1.3bin.zip

2019-06-26_181452_Armmite1.3hex.zip Edited by matherp 2019-06-27
 
KeepIS

Guru

Joined: 13/10/2014
Location: Australia
Posts: 1945
Posted: 09:02am 26 Jun 2019
Copy link to clipboard 
Print this post

Loaded bin file. Whatever change you made makes a difference.

The Keyboard runs up to 480 which is as high as I tested, however it's a bit touchy on power up above 430, touchy as in if the Keyboard will respond or not. However once it's running it runs just fine, so heat is not the issue.

Thanks for that.




NANO Inverter: Full download - Only Hex Ver 8.1Ks
 
HardingJohn

Regular Member

Joined: 28/07/2017
Location: Australia
Posts: 78
Posted: 11:22am 26 Jun 2019
Copy link to clipboard 
Print this post

Typical sales scam by the manufacturer. Exactly the same chip.
Let's hope it will run reliably at 560 MHz. I guess it will come down to ambient air temperature, ventilation, heatsinking etc.
Just know enough to get me in trouble, but not quite enough to get me out.
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 10572
Posted: 12:14pm 28 Jun 2019
Copy link to clipboard 
Print this post

Please find attached a minor change relating to using a USB keyboard. The code now allows you to optionally specify a pin which is used to turn on power to the USB port. If a USB keyboard is not used this frees up an additional I/O pin.

2019-06-28_220328_Armmite1.3bin.zip

2019-06-28_220342_Armmite1.3hex.zip

2019-06-28_221216_Armmite_H7_Manual.pdf

OPTION USBKEYBOARD layout [, powerpinno]


Sets the key layout for a connected USB keyboard. Valid layouts are UK and US. The optional “powerpinno” parameter specifies a pin which can be used to enable power to the USB port. Normally the pin will be set high when enabled. However, by specifying the pin number as a negative value the pin will be set low.

For an original Nucleo-H743 the command will be:

OPTION USBKEYBOARD UK,91


For the new ZI2 version it should be (UNTESTED!!):

OPTION USBKEYBOARD UK,-79


For a homebrew PCB with the USB power permanently connected the command will be:

OPTION USBKEYBOARD UK


The USB keyboard appears to be very robust at CPU speeds up to 400MHz. Above this there seems to be some internal timing issue deep within the STM USB code that sometimes causes the code not to enumerate properly in an apparently random way. I have included a re-try mechanism that attempts to overcome this and it seems to work OK up to 480MHz.

A correct USB connection can be checked with:

MM.INFO$(KEYBOARD)


Returns the string “Connected” if a USB keyboard is connected and working. Otherwise returns “Not connected”

Edited by matherp 2019-06-29
 
KeepIS

Guru

Joined: 13/10/2014
Location: Australia
Posts: 1945
Posted: 10:58pm 28 Jun 2019
Copy link to clipboard 
Print this post


OPTION USBKEYBOARD UK,-79

LOCKS the ZI2 - waited a long time but no response from reset button etc, BIN file has to be reloaded. BTW -79 Does NOT power on USB 5v



OPTION USBKEYBOARD UK


Locks up for a few seconds, presumably doing a keyboard retry that you mentioned. Obviously no keyboard power.

Mike.


Then typed in:


setpin 79,dout


Keyboard worked.



Edited by KeepIS 2019-06-30
NANO Inverter: Full download - Only Hex Ver 8.1Ks
 
KeepIS

Guru

Joined: 13/10/2014
Location: Australia
Posts: 1945
Posted: 11:37pm 28 Jun 2019
Copy link to clipboard 
Print this post

Set option autorun on.

Board Restarts from Reset button and runs tiny bit of code.

Board locks from power on - reload BIN.
NANO Inverter: Full download - Only Hex Ver 8.1Ks
 
KeepIS

Guru

Joined: 13/10/2014
Location: Australia
Posts: 1945
Posted: 12:48am 29 Jun 2019
Copy link to clipboard 
Print this post

Did a few tests with older version 2019-06-26_181438_Armmite1.3bin.

CPU 480.

With a BC548 NPN transistor:

C: to Pin 79
B: via 4k7 to 3v3
E: to ground.

On power up: Keyboard starts every time (20 times in a row).
After Reset: Most of the time.

But then at a later time - totally flaky again.

CPU 500
Flaky on power up all the time, KB not starting 90% of the time.

I think I'm chasing my tail with this reset line. I tried various RC time delays and like everything else, there are times when it works 100% then a minute later hardly works at all, as matherp indicated:

  Quote  
The USB keyboard appears to be very robust at CPU speeds up to 400MHz. Above this there seems to be some internal timing issue deep within the STM USB code that sometimes causes the code not to enumerate properly in an apparently random way.


  Quote  
I have included a re-try mechanism that attempts to overcome this and it seems to work OK up to 480MHz.


Can we also have the option to disable that Keyboard re-try time but still define the Keyboard without a reset pin option?

I'm thinking if it's going to be a royal pain to sort in SW then we have the option to handle the enable line in hardware in a way that works most of the time, especially at higher speeds.

Although I'm beginning to wonder if there really is any advantage in controlling the enable line over simply having USB +5 permanently enabled? Edited by KeepIS 2019-06-30
NANO Inverter: Full download - Only Hex Ver 8.1Ks
 
HardingJohn

Regular Member

Joined: 28/07/2017
Location: Australia
Posts: 78
Posted: 04:09am 29 Jun 2019
Copy link to clipboard 
Print this post

I saw a self reboot occur when running the 400 Mhz chip at 480Mhz. For stability reasons I don't think you can push the clock rate any faster than what the chip is specd for.

I would like to upgrade to the 480 Mhz chips so will order some as I am struggling with getting my very large code to run fast enough. Please keep the great work going on getting Ver 5.0507 working so that we can utilise the 480Mhz chips.

I do not use the Development boards and prototype the chip directly, so might be able to help with V2 board issues. I don't use the keyboard however.


thanks John
Just know enough to get me in trouble, but not quite enough to get me out.
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 10572
Posted: 08:17am 29 Jun 2019
Copy link to clipboard 
Print this post

I've fixed the command so -79 should now work - please let me know. Also removed the re-tries.
You can use OPTION USBKEYBOARD without a pin if the power is permanently selected or if you want tho drive the pin manually (SETPIN)


2019-06-29_181436_Armmite1.3bin.zip
2019-06-29_181450_Armmite1.3hex.zip
 
KeepIS

Guru

Joined: 13/10/2014
Location: Australia
Posts: 1945
Posted: 08:56am 29 Jun 2019
Copy link to clipboard 
Print this post

Thanks Peter, this is now very usable. All tests on the ZI2 board:

400 MHz: Power on VIN 5V and Reset: Keyboard works.

480 MHz: Will only work from Power on. Occasionally runs after reset.

520 MHz: Still working at power on. Almost never works after reset.

This is still good for me as it's mainly at power up that I want the keyboard.

For those thinking that I'm wasting time with this Keyboard thing - this is why:

To test the controllers I'm designing, they have to connected into a fully running CNC type of Machine which is also in the final design and testing stage. I'm also modifying / developing code to account for mechanical inertia, torque and ramp speeds with automated closed loop control of a heavy spindle cutter and a heavy 1M long guide Fence, so I need to fine tune the final code. A small wireless Keyboard is just so dam useful for quickly editing code in this situation.

As usual Peter, thanks for all the work on this.


NANO Inverter: Full download - Only Hex Ver 8.1Ks
 
Tinine
Guru

Joined: 30/03/2016
Location: United Kingdom
Posts: 1646
Posted: 03:01pm 29 Jun 2019
Copy link to clipboard 
Print this post

Would love to know more about this machine control application. I am currently adapting the E100 to a 3-axis CNC tube bender. I have the servo loops closed on dedicated PIC devices with hardware QEIs (quadrature encoder interface.)
 
KeepIS

Guru

Joined: 13/10/2014
Location: Australia
Posts: 1945
Posted: 12:28am 30 Jun 2019
Copy link to clipboard 
Print this post

  Tinine said   Would love to know more about this machine control application. I am currently adapting the E100 to a 3-axis CNC tube bender. I have the servo loops closed on dedicated PIC devices with hardware QEIs (quadrature encoder interface.)



Hi, perhaps we could start a thread about linear/rotary encoders including digital Scale slide encoders (currently using two) and how we are decoding the data. I got called upon to make a replacement controller for a Tube Bending machine about 10 years ago and it's still running to this day, uses a PIC (assembler) and (expensive) precision 360 deg rotary encoder. I don't want to clutter this thread so that's enough for now, however I would really like to see what others are using. I gave up on the CNC forums as they are mainly biased around commercial controllers and their needs are completely different to mine/ours. When I get time I can start a thread unless you do so in the meantime.

Mike.

NANO Inverter: Full download - Only Hex Ver 8.1Ks
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 10572
Posted: 07:38am 30 Jun 2019
Copy link to clipboard 
Print this post

Fix for SPI3 when data length is not 8 bits.

2019-06-30_173755_Armmite1.3bin.zip

2019-06-30_173807_Armmite1.3hex.zip

Also includes rewrite of the ARC command to improve speed.
 
Print this page


To reply to this topic, you need to log in.

The Back Shed's forum code is written, and hosted, in Australia.
© JAQ Software 2025