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 : MMEdit and miniMaximite
Author | Message | ||||
mpep Newbie Joined: 09/11/2014 Location: New ZealandPosts: 29 |
Hi Gents, I have a problem whereby I cannot load any program to the mMM using MM Edit. Keeps coming up: "Error: SD Card not detected" Now I don't have a SD Card reader etc attached, so that bit makes sense, but does this mean that I cannot use MM Edit at all? If this is the case, then I need to learn the following: Writing a program using MM Edit, and testing it on MM DOS. This is not quite the same, but okay will help me along a fair way, obviously I cannot test external inputs. When I get to a point that I am happy with a program, how do I upload it to the mMM? And store and run it? I think I've read quite a few of the manuals around, but am missing something MPep |
||||
TassyJim Guru Joined: 07/08/2011 Location: AustraliaPosts: 5905 |
MMEdit normally uses Xmodem to transfer the file to the maximite. The micromite transfers the files directly to memory but that option is not available on the maximite. All is not lost. Start with your program in the editor. Open up a Chat window Click on the 'New' button (looks like a blank page). Click on the 'Ld' (load) button. This will load the program into memory on the maximite. This method uses the 'auto' command to load the program. If your maximite looses power, the program will be lost. Jim VK7JH MMedit MMBasic Help |
||||
mpep Newbie Joined: 09/11/2014 Location: New ZealandPosts: 29 |
Thanks for the clear instructions, Jim. Just gone through that, and works okay. Is there a way to enter a program permanently? I.E. for using the miniMaximite as an embedded controller? Is there a terminal provided in MME? Haven't managed to find it yet if there is Reason being is that I am starting out, taking small steps at a time. I have set up TeraTerm, no problems there, COM4. I use is as my 'monitor' to see the output of my programs at this stage. However, using MME, I find that I need to quickly disconnect, then open up TT. If I leave it too long, then I find that although I have everything in a loop, continuously 'print'ing stuff through COM4, even when opening TT, nothing is displayed. pause 10000
setpin 2,AIN setpin 3,ain do v2 = pin(2)*250-410 v3 = pin(3)*250-410 PRINT @(150,100)("V2 = "),v2 PRINT @(150,150)("V3 = "),v3 pause 200 loop MPep |
||||
Geoffg Guru Joined: 06/06/2011 Location: AustraliaPosts: 3165 |
MMBasic on the Maximite series creates a filesystem called drive A: from the internal flash memory of the PIC32. Page 3 of the manual goes into more detail. The SD card is drive B: but because it is the default you do not normally notice that there are two drives available to you. You can change the default with the DRIVE command. The command FILES "A:" will list the files stored in the internal drive. SAVE "A:PROG.BAS: will save a file to that drive. RUN "A:PROG.BAS" will run the program, etc. Nearly all commands that use a file name can access drive A:. Finally, you can use XMODEM to transfer files to/from drive A: Geoff Geoff Graham - http://geoffg.net |
||||
mpep Newbie Joined: 09/11/2014 Location: New ZealandPosts: 29 |
Hi Geoff, Thanks for that info. Will check that out today. I thought about it later and realised that the XMODEM protocol could be used to send to the mMM. Now, about the terminal? MPep |
||||
TassyJim Guru Joined: 07/08/2011 Location: AustraliaPosts: 5905 |
If you use MMEdit's file manager, you can save directly to drive A: but 'load and run' uses drive B: I can make a change to the program to allow the option of using drive A: instead of B: I will put it on the todo list. If you got a far as opening the Chat window in MMEdit, you are in the terminal... The terminal in MMEdit is fairly basic and I would stick with TeraTerm for long term use. There are 3 modes in the Chat window ASCII - commands are entered in the one-line text box and all data from the Maximite appears in the larger window. This is best for receiving long streams of data and the data can be captured. HEX - same as ASCII but the data is displayed in HEX. This is used for debugging your output. VT100 - This is your TeraTerm style terminal. It is very slow and doesn't work well for fast data rates. TeraTerm is much better. Jim VK7JH MMedit MMBasic Help |
||||
CircuitGizmos Guru Joined: 08/09/2011 Location: United StatesPosts: 1421 |
How about Save before Load? Or is it there and I've missed it? Micromites and Maximites! - Beginning Maximite |
||||
mpep Newbie Joined: 09/11/2014 Location: New ZealandPosts: 29 |
Interesting. Yes I've got Chat working, certainly appears that the program is loaded into the mMM. But as stated, I couldn't see any results (PRINT) output. Will go with Geoff's suggestion to upload and test via TT. Unless you want something else on the to-do list [ ] and have an option to open up TT after loading a program into a MM, thereby closing its own terminal. Just a thought. MPep |
||||
TassyJim Guru Joined: 07/08/2011 Location: AustraliaPosts: 5905 |
On the Maximite, XMODEM does a 'save' After a 'load and run' in MMEdit there will be a file called temp.bas The problem is, MMEdit leaves the default drive as B: To allow for users without a card in the drive, I need to force drive A: Jim VK7JH MMedit MMBasic Help |
||||
TassyJim Guru Joined: 07/08/2011 Location: AustraliaPosts: 5905 |
Mpep, I have often thought about using TeraTerm as the terminal. It would add more problems than it solves. I prefer to develop the program with MMEdit and then use TeraTerm for production use. With your example program, why do you have a 10 second delay at the start? Jim VK7JH MMedit MMBasic Help |
||||
mpep Newbie Joined: 09/11/2014 Location: New ZealandPosts: 29 |
I have often thought about using TeraTerm as the terminal. It would add more problems than it solves. I prefer to develop the program with MMEdit and then use TeraTerm for production use. With your example program, why do you have a 10 second delay at the start? Jim Hi Jim, My preference would be similar to you, MMEdit to develop and TT for the rest, but I'm only starting out The delay is to try and close MMEdit, and open TT before the program starts. Only worked once so far. MPep |
||||
TassyJim Guru Joined: 07/08/2011 Location: AustraliaPosts: 5905 |
The delay is to try and close MMEdit, and open TT before the program starts. Only worked once so far. MPep Why not wait till you have TeraTerm running before you 'run' your application? If you don't deliberately close the connection to your maximite, MMEdit will hold it open for 20 seconds after closing the Chat window. (I have reduced that to 5 or 10 seconds for the next update) I still don't know why you didn't have any output when you were running MMEdit. With your program, it should be working with any of the Chat terminal modes. The program is transferred OK so your obviously are connecting to the maximite OK. Jim VK7JH MMedit MMBasic Help |
||||
mpep Newbie Joined: 09/11/2014 Location: New ZealandPosts: 29 |
Why not wait till you have TeraTerm running before you 'run' your application? If you don't deliberately close the connection to your maximite, MMEdit will hold it open for 20 seconds after closing the Chat window. (I have reduced that to 5 or 10 seconds for the next update) I still don't know why you didn't have any output when you were running MMEdit. With your program, it should be working with any of the Chat terminal modes. The program is transferred OK so your obviously are connecting to the maximite OK. Jim Because the COM port can only be used by one program at a time. I have just gone through the RUN program and SAVE etc. I can now progress to further programming exercises for myself. |
||||
CircuitGizmos Guru Joined: 08/09/2011 Location: United StatesPosts: 1421 |
I will put it on the todo list. How about Save before Load? Or is it there and I've missed it? On the Maximite, XMODEM does a 'save' After a 'load and run' in MMEdit there will be a file called temp.bas The problem is, MMEdit leaves the default drive as B: To allow for users without a card in the drive, I need to force drive A: Jim I meant on the PC. I've been editing a file C:\fred.bas. I'm doing a test/run/test/run cycle when something catastrophic happens and MMEDITdit crashes. I'd like a save of C:\fred.bas (to PC hard drive) every time I do a load to the Maximite. Micromites and Maximites! - Beginning Maximite |
||||
TassyJim Guru Joined: 07/08/2011 Location: AustraliaPosts: 5905 |
I meant on the PC. I've been editing a file C:\fred.bas. I'm doing a test/run/test/run cycle when something catastrophic happens and MMEDITdit crashes. I'd like a save of C:\fred.bas (to PC hard drive) every time I do a load to the Maximite. That makes more sense. There is auto-backup which will do a backup every x minutes if the file has changed. If you have that set to a short time, the backup folder will grow rather fast. I leave it at 30 minutes. It is handy for going back a few versions when the latest great idea doesn't work... I could add an option to save the code to a file called backup.bas every time you do a 'load and run'. It would go into the same folder as the timed backups. I don't like the idea of simply saving the code under it's own name. If you are testing, you probably only want to save working code. I will add it to the list. But why does MMEdit crash???? That worries me. Jim VK7JH MMedit MMBasic Help |
||||
matherp Guru Joined: 11/12/2012 Location: United KingdomPosts: 8582 |
Jim I'm also getting crashes of MMEdit from time to time (W7-64bit). It seemed to get worse after the latest round of MS updates but that could be just serendipidity. There is a failsafe though. An error box pops up before the program shuts down. At this time is is possible to select and copy the current program out of the MMEdit window. Then I acknowledge the error and restart and I can paste the program back in. |
||||
TassyJim Guru Joined: 07/08/2011 Location: AustraliaPosts: 5905 |
I'm also getting crashes of MMEdit from time to time (W7-64bit). Next time it happens, can you make a note of the error message for me. Also, check the error log to see if there is an entry there with the corresponding time. A copy of your configuration report will help too. Jim VK7JH MMedit MMBasic Help |
||||
Print this page |