Home
JAQForum Ver 24.01
Log In or Join  
Active Topics
Local Time 16:29 02 Aug 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 : MMBasic on ARM, worth the effort?

     Page 3 of 4    
Author Message
JohnS
Guru

Joined: 18/11/2011
Location: United Kingdom
Posts: 4044
Posted: 11:57pm 26 Feb 2015
Copy link to clipboard 
Print this post

Why use Keil?

Why not gcc?

John
 
plasma
Guru

Joined: 08/04/2012
Location: Germany
Posts: 437
Posted: 09:57pm 27 Feb 2015
Copy link to clipboard 
Print this post

hmm gcc toolchain and eclipse maybe ?
have anyone this ever running without much problems ?

yesterday i tryed keil , but i dislike it because its soo different in some commands.

btw: we have a compiling source for the 429 now , and i hope Dathmite get the source running.

so i think the MMbasic port for the Stm429 is ready , darthmite get some errors in some extra libs but
i know he can solve this because it is his own source.

mfg
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 10315
Posted: 10:47pm 27 Feb 2015
Copy link to clipboard 
Print this post

We seem to be going off in multiple directions and trying to run before we can walk.

There is a huge amount of coding to do to get the STM32F running its peripherals under Basic control before we worry about whether the target is a 407 or 429 and integrating things like SD cards

The only free IDE for the STM32 which can deal with a program this big is CoIDE.

darthmite has a licensed version of Keil but others don't and it is very expensive.

If the development is to work as a group effort we have to agree to standardise.

The code I sent out has a fully working Basic interpreter on the 407 developed under CoIde. I'm unclear why we need to change this.

Do we agree to start with the 407 on CoIDE?Edited by matherp 2015-03-01
 
plasma
Guru

Joined: 08/04/2012
Location: Germany
Posts: 437
Posted: 01:28am 28 Feb 2015
Copy link to clipboard 
Print this post

Please dont misunderstand my Post.
As i wrote above we need to go with
Coide because keil is much to expensive
and sux imho.
I total agree with your way because i think
the same about.
But for darthmite is the 429 the goal because
he have programming a lot of libs for the 429.
This libs will help us in the future i mean.
Also i startet with your codesample and try to
Understand your inplement for the serial.
Gtx
 
darthmite

Senior Member

Joined: 20/11/2011
Location: France
Posts: 240
Posted: 01:29am 28 Feb 2015
Copy link to clipboard 
Print this post

Hi

yesterday evening it compiled with warning for the st429.now for use the st407 , why
not for those who still have it.
I agree that CoIde is cheap (free) , but still a problem with st429 and not
compatible with the RealView ULINK2 debugger !!
Keil is probably restrictive on what you can do , but is a industry well know environment with the Rowley one.(Try to use CoIde in big industry for fun )
The actual 'Hardfault' come probably from memory management , i will try to put the
Basic Source memory to SDRAM that is allot less restrictive.
Then after tokenizing , it will be executed from main sram who is faster.
But i don't have say i will not try CoIde / gcc when it become better for the st429.
But one of the most annoying thing in mm code is the mixing between char and uchar and
that is no re-entry preventing in the headers
Today i will switch off my libs and try it again to see if it still have 'hardfault'.
If yes , then it will be time to redo the actual memory stuff.

Cheers.

Theory is when we know everything but nothing work ...
Practice is when everything work but no one know why ;)
 
JohnS
Guru

Joined: 18/11/2011
Location: United Kingdom
Posts: 4044
Posted: 01:53am 28 Feb 2015
Copy link to clipboard 
Print this post

Sounds like first thing to do is tidy up - fix the headers and char/uchar.

BTW, people will in general not have any expensive tool, whether Keil/Rowley/RealView or whatever.

OpenOCD supports STM32 and is free.

JohnEdited by JohnS 2015-03-01
 
G8JCF

Guru

Joined: 15/05/2014
Location: United Kingdom
Posts: 676
Posted: 01:08pm 28 Feb 2015
Copy link to clipboard 
Print this post

I agree with @matherp. PeterM & GeoffG have always said that getting the BASIC part of MMBasic working on ARM is the easy part. The really hard and value added part is getting all the peripherals to work in the MMBasic way. Sure with CFunctions, and a detailed understanding of data sheets the 'C' literati will be able to use MMBasic and C to do stuff with the peripherals, but for everyone else, without the MMBasic way of handling peripherals, it wouldn't be MMBasic. The power of the uMite is that with very little understanding of how the PIC32 peripherals work internally to the PIC32, most people can still make the PIC32 do hardware stuff very quickly and easily.

I believe that @matherp has described a good middle ground which might allow us to actually achieve a real uMite on an ARM chip at very low cost. Once the goal of a uMite on ARM has been achieved, then perhaps comes the time to get complicated.

It is more important that we all work together with a single goal in mind, using the same tools, and processes than splintering our efforts into disparate adventures.

I for one will be sticking to the CoIDE+GCC+STM32F4Discovery direction set by PeterMather.

Peter

The only Konstant is Change
 
geraldfryjr

Regular Member

Joined: 02/03/2014
Location: United States
Posts: 61
Posted: 08:53pm 01 Mar 2015
Copy link to clipboard 
Print this post

This sounds like a very excellent project!!!

I have Three STM32F429discovery boards with the TFT display.

I did take the web course on the board last year and I used KIEL but it was only good for 60days.
It didn't make since to have to spend $2500 in order to learn to program a $30 board and play with the demo that came with it.

I have CooCox installed and ready to go but I know nothing about how to get started with it.
I have been waiting for them to introduce full support for the 429 graphic system rather than just working with the 407 core features.

I am still cutting my teeth on C so I won't be much help in development at this point.
But, I would like to be part of this project even if it means just beta testing software and reporting the results.

I would love to see MMB working on one of these so that I could actually make it do something. ;)

jer :)
Keep on DIYin' !!!
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 10315
Posted: 07:47am 02 Mar 2015
Copy link to clipboard 
Print this post

Progress report:

I've now got all basic digital I/O working under Basic control. i.e.
SETPIN DIN, DOUT, INTL, INTH, INTB
PIN(n)=x
x=PIN(n)

including open-collector, pullups, and pulldowns.

This went together really nicely. The STM libraries seem much easier than the Microchip versions:

This site has been a great source of example code to make the port easier.

If you are part of the development group and haven't received the latest code please let me know.
 
geraldfryjr

Regular Member

Joined: 02/03/2014
Location: United States
Posts: 61
Posted: 06:54pm 02 Mar 2015
Copy link to clipboard 
Print this post

What a Great site thank you for posting that.

I will start there with the tutorial with CooCox !!

Cheers!!

jer :)
Keep on DIYin' !!!
 
plasma
Guru

Joined: 08/04/2012
Location: Germany
Posts: 437
Posted: 08:18pm 02 Mar 2015
Copy link to clipboard 
Print this post

Hi ,
Try port 60 ! Blinky blinky 😜👍
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 10315
Posted: 09:20am 03 Mar 2015
Copy link to clipboard 
Print this post

Anyone in the development group who has't received beta-5 please email me.

Lots of new functionality working including:

12-bit analogue input on 16 pins plus reading the reference voltage – pin(0), nominally 1.2V
External hardware interrupts supporting SETPIN CIN, and FIN
Onewire functionality including DS18B20
PULSIN (returns the no. of usec as an integer)

I think we can now be certain that complete Micromite MKII functionality on the STM32F4 is definitely achievable.
Edited by matherp 2015-03-04
 
WhiteWizzard
Guru

Joined: 05/04/2013
Location: United Kingdom
Posts: 2944
Posted: 10:03am 03 Mar 2015
Copy link to clipboard 
Print this post

@matherp

Fantastic progress there.

As a total novice with STM MPU's what would you recommend I buy as a platform to 'test' things (once you release the code more 'generally'. I don't want to have to delve into C, just want to load the 'firmware' and start using it with TeraTerm.

Is the Discovery kit a decent step into this? I notice it is only about £5 more than the MPU by itself, yet includes all kinds of 'goodies' on the board.

Your advice would be appreciated (I'm in no rush - just want to buy the right thing on my limited budget).

Thanks,

WW
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 10315
Posted: 10:41am 03 Mar 2015
Copy link to clipboard 
Print this post

WW

I'm using RS part number 745-8434.

Cheap and powerful, also capable of being used as a PicKit3 equivalent for programming bare chips
 
JohnS
Guru

Joined: 18/11/2011
Location: United Kingdom
Posts: 4044
Posted: 10:58am 03 Mar 2015
Copy link to clipboard 
Print this post

You might like to get the equivalent board (as well or instead) with a 429.

RS 789-2815

Is an Allwinner (*) board next???

(*) the chips in most of the lower cost tablets & Android TV box devices

JohnEdited by JohnS 2015-03-04
 
WhiteWizzard
Guru

Joined: 05/04/2013
Location: United Kingdom
Posts: 2944
Posted: 11:51am 03 Mar 2015
Copy link to clipboard 
Print this post

Thanks for the responses - these were actually the units that I had shortlisted (based purely on value for money) so that was pleasant to hear these two mentioned by you both.

Simple question: will the development that matherp is currently doing (based on the 407) work on the 429 module (with no/minimal effort) OR will the code only work on the 407 module? Hope this makes sense!

WW
 
JohnS
Guru

Joined: 18/11/2011
Location: United Kingdom
Posts: 4044
Posted: 02:18pm 03 Mar 2015
Copy link to clipboard 
Print this post

I've not seen any of the code but correctly written C I/O code will work on the whole STM32 family (but being I/O will not work unchanged on RPi, OMAP, AW, Freescale, NXP, etc).

(Non-I/O code should work almost anywhere, subject to some awkwardness possibilities like word size and endianness.)

JohnEdited by JohnS 2015-03-05
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 10315
Posted: 09:54pm 03 Mar 2015
Copy link to clipboard 
Print this post

The code won't run as-is on the 429 board. This uses an LQFP144 chip rather than the LQFP100 on the 407 board. This requires the pin layout table to be changed in the code and there may be other possible consequences
 
JohnS
Guru

Joined: 18/11/2011
Location: United Kingdom
Posts: 4044
Posted: 10:48pm 03 Mar 2015
Copy link to clipboard 
Print this post

Would it be worth having it auto-configure so it "just works"? Maybe that's on the To Do list?

JohnEdited by JohnS 2015-03-05
 
WhiteWizzard
Guru

Joined: 05/04/2013
Location: United Kingdom
Posts: 2944
Posted: 10:54pm 03 Mar 2015
Copy link to clipboard 
Print this post

I think at the low cost of each unit I will just buy both

WW
 
     Page 3 of 4    
Print this page
The Back Shed's forum code is written, and hosted, in Australia.
© JAQ Software 2025