![]() |
Forum Index : Microcontroller and PC projects : MMBasic on ARM, worth the effort?
![]() ![]() ![]() ![]() |
|||||
Author | Message | ||||
vegipete![]() Guru ![]() Joined: 29/01/2013 Location: CanadaPosts: 1132 |
Has any one links to a good set of up-to-date instructions for setting up a nice IDE for ST Discovery or Nucleo dev boards? I spent months off and on trying to get a Linux box to work, with minimal success. Now I've got a mostly working Win7 setup using Eclipse (following the instructions here (click 'prev' to go to the next installment) ) but so far I can't get the OpenOCD debugger to work. Visit Vegipete's *Mite Library for cool programs. |
||||
darthmite![]() Senior Member ![]() Joined: 20/11/2011 Location: FrancePosts: 240 |
My god ! , you made yourself your life harder ![]() If you just start , use Cocoox (CoIDE). I try that on the stm32f407 last year and it was not bad so long you don't try to debug too deep ![]() When you get more familiar with ARM chip , then you can try Keil MDK who 'for me' is one of the best around. And they are 2 primary libs set for STM32 ... The Standard Peripheral Library and ... the CubeMX Library ... If you can ... use the 1st one , the CubeMX is still in dev and full of bugs ![]() Cheers. PS : and this is out of Topic ! Topic: MMBasic on ARM, worth the effort? <- everything new worth an effort ![]() Theory is when we know everything but nothing work ... Practice is when everything work but no one know why ;) |
||||
plasma Guru ![]() Joined: 08/04/2012 Location: GermanyPosts: 437 |
So much People with much knowlege around the Stm here. I think we need a Community Project for this. But how to handle ? A secret forum which can only read by People which have a "ok" from geoff and a Passwort and email auth? if anyone have a good idea about this and Geoff agreed with this i think we can build some cool. gtx |
||||
matherp Guru ![]() Joined: 11/12/2012 Location: United KingdomPosts: 10315 |
UPDATE I've created a RAM array that pretends to the code it is the flash memory. This means that I can now load programs from MMEDIT using xmodem up to 32K in length. EDIT, NEW, CLEAR, MEMORY, XMODEM, RUN, ctrl-C all work together with all the normal BASIC language including TIMER and PAUSE. PAUSE now accepts an integer number of milliseconds rather than a float. The only difference from the Micromite is that the program is lost following a reset. The next step is to try and replace the RAM array with the STM flash. From the docs it looks like STM flash is easier to handle than Microchip other than the fact it can only be erased in large chunks. Once I've got this working it would be great if a group could work on the code. My idea is that we could allocate the various peripherals to individuals so that one person could work on I2C, another on SPI etc. As these are all handled in separate source files it shouldn't be too difficult to coordinate the development. There are lots of example programs out there so getting each individual type of hardware to work should be easy enough. The challenge will be bringing it all together under the flexible pin allocation "SETPIN" umbrella. One key area is getting timers other than settick working as these are used for many of the special hardware devices (DS18B20, IR, DHT22, HC-SR04) I haven't thought about Cfunctions yet but obviously these would be essential if the port is to be of any use in high speed applications. They would need G8JCF to help with a new version of CFuncGen that could handle the ARM elf file. I'll PM Geoff to ask permission to work in this way and also Peter (G8JCF) to get his comments. Please PM me if you would like to be involved |
||||
pito Newbie ![]() Joined: 09/06/2011 Location: Posts: 25 |
Mind the access to the external sram/sdram is at least 6x slower (or more with slower memories) than to the internal sram with stm32f4xx. On the other hand it has got SDIO (pic32 does not posses it) so 10MB/sec r/w to an sdcard is real (with 32k buffers). Also single precision FPU math calcs are 10-15x faster. I would highly recommend to have double precision (64bit) floating point as well (or more with bcdfp bignumber library thus the users may use it as a scientific programmable). I would use the internal sram for various buffers (for serial, video, sdcard, etc.), while the Basic itself would reside in the external sram/sdram (ie 512kx16bit 10-55ns). In the result such config would be _many_ (20-50x ??) times faster than my old Atari 1024ST with Basic. So today the stm32f4xx are the best candidates when talking DIY, still-hand-solderable-Basic kits. |
||||
plasma Guru ![]() Joined: 08/04/2012 Location: GermanyPosts: 437 |
let us use the coide because keil isnt really cheap for a hoby progger ( like me) ![]() |
||||
matherp Guru ![]() Joined: 11/12/2012 Location: United KingdomPosts: 10315 |
Geoff has kindly agreed that we can proceed with the STM32 Micromite development on the basis I proposed in my last post. The current development group is matherp, plasma, darthmite, G8JCF and TZadvantage. If anyone else would like to be involved please PM me, requirements are purchase of a $15 development board and a willingness to get down and very dirty in C with the ARM peripheral hardware. Current status is as follows: MMBasic is fully working Programs are now correctly stored in flash and run from flash Interaction with MMEdit works properly XMODEM, EDIT, NEW, CLEAR, ctrlC, CONTINUE, VAR SAVE, VAR RESTORE, OPTION AUTORUN ON/OFF all work TIMER and PAUSE both work (PAUSE now accepts an integer number of msec rather than a float) No peripherals other than the 1msec SYSTICK timer have yet been configured |
||||
darthmite![]() Senior Member ![]() Joined: 20/11/2011 Location: FrancePosts: 240 |
Great ![]() I was sure Geoff will say yes ![]() @TZadvantage : the ST429 Disco is on his way to your country ... I will do the PS2 KB (as i helped for it on the pic32 MM and i know how it work) The mod player is done here for the st429 SD Card driver (tough SPI) is done too Full Graphics driver done (800 x 480 16bits)... Wii joystick driver (I2C) done... For the mouse is one another story , i put a stm32f0 in a PS2 mouse (4 pin from UC like the schematic from this page : mouse protocol ) and output clk/dat to my main board. Driver for dual SDRAM chip done .... Well allot of the driver are ready , now it's just some adaptation to do for the interpreter ![]() I hope that the matherp CoIde project will not be the hell to adapt for Keil ... will see ... Cheers. Theory is when we know everything but nothing work ... Practice is when everything work but no one know why ;) |
||||
Grogster![]() Admin Group ![]() Joined: 31/12/2012 Location: New ZealandPosts: 9610 |
If this seems to be the way that things are now heading, have the 470's been dropped in favor of the ST's? Does not bother me if the answer is "Yes". But, if this is the way things are heading, perhaps I could start work on a preliminary ARM MicroMite PCB layout? ...unless the $15 development board has everything that will be needed anyway... What do the ST chips sell for by themselves, and can someone link me to the part, so I can see what it's footprint is? Unfortunately, I cannot help with this code development - C is not my area! ![]() @ darthmite - how are the graphics done? HDMI? DVI? VGA? Smoke makes things work. When the smoke gets out, it stops! |
||||
matherp Guru ![]() Joined: 11/12/2012 Location: United KingdomPosts: 10315 |
Certainly not from my perspective - we don't even know if it will work out. Remember Geoff's experience with the MZ. |
||||
JohnS Guru ![]() Joined: 18/11/2011 Location: United KingdomPosts: 4044 |
My feeling is that the 470 is a good idea and in effect here now (nearly). Looks like Geoff is in favour, with just some details to be firmed up. An ARM chip is almost certainly another good idea but will take some time. And may or may not be an ST - and if an ST may be the 407 or 429 or ... (who knows). I suspect Geoff will decide when more is known. A choice of chips and a choice of makes must be good for the longer term. (Also, maybe Microchip will see that the MZ needs more effort to make it better - don't let's assume it won't be.) Grogster - if you fancy a go at an ARM PCB... hey why not! In case it may help I think there are some creative commons or OSHW type ones available from Olimex for Allwinner and perhaps for ST ARM chips. They might be of some interest. John |
||||
pito Newbie ![]() Joined: 09/06/2011 Location: Posts: 25 |
407 does support sram, does not support sdram 42x does support sdram 16MBx16 sdram costs $1.50, the same in sram would be 100x more expensive 407 costs $10-$15 single q. 42x costs $15-$20 single q. So basically twice the pic32MX/MZ PS: do not use SPI but SDIO for the SDcard |
||||
darthmite![]() Senior Member ![]() Joined: 20/11/2011 Location: FrancePosts: 240 |
I have done up to 640 x 480 in 16bits on VGA Screen.(old board) Now i do 400 x 240 or 800 x 480 in 16bits at 112 fps on my new board with LCD. For VGA you need a R2R DAC to convert the 16bits digital to 5R 6G 5B analog. you can get all info for that on my 'discontinued' page here : old board schematic from v1 and v2 board at bottom of the page. I have do in the past 320 x 240 8bits VGA with a stm32f407 , but is a little too restrictive , better directly use the st429 for doing sexy things like that ![]() Cheers. Theory is when we know everything but nothing work ... Practice is when everything work but no one know why ;) |
||||
boss![]() Senior Member ![]() Joined: 19/08/2011 Location: CanadaPosts: 268 |
STM32F4 is an old horse but still good enough for MMBasic project I personally suggest to focus our effort on the latest pin and instruction backward compatible chip STM32F7 Bo |
||||
JohnS Guru ![]() Joined: 18/11/2011 Location: United KingdomPosts: 4044 |
When it's conveniently & cheaply available - but it's not is it? John |
||||
boss![]() Senior Member ![]() Joined: 19/08/2011 Location: CanadaPosts: 268 |
@JohnS Their promises say Q2 2015 in US/Canada and the price should be close or the same as F4. But they are Frenchmen, aren't they? ![]() So we will see. Bo |
||||
JohnS Guru ![]() Joined: 18/11/2011 Location: United KingdomPosts: 4044 |
If/when that happens I'm likely to be keen. Right now I'd rather stick to what's available :) John |
||||
boss![]() Senior Member ![]() Joined: 19/08/2011 Location: CanadaPosts: 268 |
@JohnS I fully agree with you. I have a couple of F4 demo boards from ST Canada and I'm eager to try MMBasic running on it. Together with SSD1963 shield with DVI output it might be nice gadget. I hope the final version will run on F7 as well. They proclaim pin and code compatibility with F4. |
||||
plasma Guru ![]() Joined: 08/04/2012 Location: GermanyPosts: 437 |
Any Progress ? At the Moment i test some libs without the Mmbasic port to become a feeling for the Stm32. @darthmite. Look like i can help . |
||||
darthmite![]() Senior Member ![]() Joined: 20/11/2011 Location: FrancePosts: 240 |
Yea , it progress slowly ![]() From more than 200 warning and 150 error in compilation (Coocox and Keil don't like each other) i reduced this to 62 warning and 7 errors (damn pointer) ... I think that it probably soon can interpret on st429 too. But i'm not alone for this work ![]() Cheers. Theory is when we know everything but nothing work ... Practice is when everything work but no one know why ;) |
||||
![]() ![]() ![]() ![]() |
![]() |
![]() |
The Back Shed's forum code is written, and hosted, in Australia. | © JAQ Software 2025 |