![]() |
Forum Index : Microcontroller and PC projects : Killed microprosessor
![]() ![]() ![]() ![]() |
|||||
Author | Message | ||||
plover![]() Guru ![]() Joined: 18/04/2013 Location: AustraliaPosts: 306 |
With the new cable I can now use gtkterm gtkterm -p /dev/ttyUSB0 -d 50 gtkterm -p /dev/ttyUSB0 Not quite sure how I got below. I get a blinking cursor and typing anything did not seem to anything. Speed to start with was 9600 and I then started changing speeds, seems that 38400 gave response, some randoms clicks and i got a prompt > then I thought I might be in Basic: > list CPU 48 b$="1234567890123456" change: Input "speed ";speed speed = speed * 1000000 SPI OPEN speed, 3, 16 Lop: SPI WRITE 16, b$ a$=Inkey$ If a$="" Then GoTo lop SPI CLOSE GoTo change > Well something is happening, now I must find the basic commands and see what else I can do. I was expecting a Banner, is that not normal a couple of lines identiyng what is running? Also got it running in Minicom 2.7 still no banner but apparently working very simple check like print 4 and print cos(pi/4). |
||||
plover![]() Guru ![]() Joined: 18/04/2013 Location: AustraliaPosts: 306 |
Minicom 2.7 partly will run MMBasic on the Mup-v2, when going into Edit mode the trouble starts the bottom line with F-keys is not working properly. Need to look into this closer. To get around this I thought I would try MMedit, I had an early version install in Wine and it appeared to work ok but I decided to install the latest version. [code]wine MMedit_setup.exe[/code] This seems to work fine until I try to run, then get a message smalltalk/v: unable to allocate virtual address space Nasty one that for me, I don't understand what that means and googling not helped much so far. I made a mistake when trying to install MMedit running it as MMedit_setup.exe Actually seemed to have the same effect as with "wine" preceeding the statement. Well I am stuck at the moment. ![]() |
||||
TassyJim![]() Guru ![]() Joined: 07/08/2011 Location: AustraliaPosts: 6283 |
Try installing MMEdit again but select the option "Memory bug fix (only select if needed)" That uses a smaller memory model which should fix the problem. Jim VK7JH MMedit |
||||
plover![]() Guru ![]() Joined: 18/04/2013 Location: AustraliaPosts: 306 |
Indeed, I have just re-run the wine install line for MMedit, no problem started up and somehow has found the test program I entered to run on the Mup-v2. I have got to the stage of trying to figure out which com port to use. Turns out that COM4 makes the connection. Manual p.38 last line, seems to end in open air? is there something missing here? BigMik's Mup-Test board is plugged into the Mup-v2 board and blinking away (one LED11 probably wrong polarity not working) Question how do I stop the program in the Chat window? Ctl-C or Ctl-Z no effect? Ahhh, quick enough this time to do a ctl-c when loading the program Well at least that NEW statement stopped the micro and the program now waiting on RUN command in the CHAT window? Funny that, it says LOAD and RUN, should RUN not be automatically? How can I get to see the two line Banner, shown in the manual. Apart from that I now have a good connection to communicate with the micro, better than the terminal connection I have managed so far. Can install and edit programs and edit. |
||||
plover![]() Guru ![]() Joined: 18/04/2013 Location: AustraliaPosts: 306 |
With the Micromite almost working I have turned my attention to my Colour Maximite to see if this will work on the MMedit just installed. gtkterm -p /dev/ttyACM0 -d 50 This line confirms contact with the Maximite, I get the banner Changing to use the Maximite with MMedit I am struggling. When I use "Connect to Maximite" the chat box opens and I can enter characters on the command line but nothing happens. Tried "Connect NEW" ON ALL COM1..4 ports, COM3 and 4 outright say no connection both COM1 and COM2 give the impression that I can "LOAD and RUN" but gives following: The dots represent identical lines removed. I do notice that MMedit does not seem to have picked up that it is a Maximite version that is installed according to the Banner. I will have a breaking from punching keys and finish reading the manual. added later Ahh yes, my comment on manual seemed to end in open air on p.38, due to my way of reading in Okular, forgot to move sideways to pick up next page, where the lines continue to make sense. Just noticed too, "Autodetect device" is greyed out |
||||
TassyJim![]() Guru ![]() Joined: 07/08/2011 Location: AustraliaPosts: 6283 |
I struggled with serial ports and Wine. You will have to work out with Wine, which comports have been mapped to what. I find that using ser2net in Linux and then using the TCPIP option in MMEdit is a lot easier than battling with the serial port mappings of Wine. "Load and Run" has a number of options, one of them being RUN after load. Set the options in Preferences. "Autodetect device" was causing too much grief and taking too long so I now expect users to know what they are talking to and select the correct syntax file. If you have the right syntax file loaded, MMEdit knows what you are talking to (usually). If I come up with more reliable detecting, I will put the option back in. Rather than using Load and Run", you can try "Load" from the chat window. It uses AUTOLOAD (or AUTO) rather than XMODEM to load the program. The Chat window has 3 modes. In ASCII mode, you enter text into the command line then click on the third button (right arrow) to send the line. Pressing enter should also send the line but under Wine, I am not confident. The command line has a scroll-back buffer which is handy for repeat sending. Use the up arrow to scroll back. In VT mode, you have a (very primitive) VT100 terminal so any key-press is sent immediately. My VT100 mode is not very good and I wouldn't recommend it for any serious terminal work. HEX mode is handy for debugging your output stream. You can usually switch between modes at will. In all modes there are buttons that send things like control-C and commands to set the clock, list, load etc. Jim VK7JH MMedit |
||||
plover![]() Guru ![]() Joined: 18/04/2013 Location: AustraliaPosts: 306 |
Staying on the Maximite and managed to get the banner confirming I was running Maximite 4.5 and around the same time I realised that I should change the Syntax to Maximite 4.5 I thought I was home and hosed but not quite. Now MMedit does show Maximite_4.5 but when I try to "LOAD and RUN" as you can see in my previous message MMedit insists that I am still running "Micromite_MK2_V5.1 Version V0.0 detected" This was what is loaded in the Mup-v2, I.e. I have change micro and MME still think the previous version of Basic has something to do with new micro. I think I will restart the computer just in case as I did have cable trouble when switching to the Maximite, that was a blow the USB simply did not register until I wrigle the USB-B connector at the back up the box (Jaycar Kit) Have managed to get through the manual and starting from the beginning again. I did find answers to some of the questions that I asked previously so really I don't think there is much missing before MME is working for me. I am starting to think Terra term might be worth a try under Wine, though if I can get MMEdit to work then I think I will live with that. After a re-start of the PC the Maximite_4.5 recognised but still no connection on COM2 getting closer MMedit really nice program, great job Jim. |
||||
TassyJim![]() Guru ![]() Joined: 07/08/2011 Location: AustraliaPosts: 6283 |
I think you have to tell Wine which com port you want to map to /dev/ttyACM0 TeraTerm is far superior to MMEdit but I think it will have trouble if Wine is not correctly mapped. I suggest that you have a look at ser2net. It will make life easier. Jim VK7JH MMedit |
||||
plover![]() Guru ![]() Joined: 18/04/2013 Location: AustraliaPosts: 306 |
Yes that is correct, and I have made a symbolic link like this: ln -s /dev/ttyACM0 /.wine/dosdevices/COM4 and [root@kde64byTexstar gert]# ls -l /home/gert/.wine/dosdevices/COM4 lrwxrwxrwx 1 gert gert 12 Jul 16 15:17 /home/gert/.wine/dosdevices/COM4 -> /dev/ttyACM0 [root@kde64byTexstar gert]# I think this should work. Yes I will check out your suggestion, ser2net at this stage I have no clue what that is. |
||||
plover![]() Guru ![]() Joined: 18/04/2013 Location: AustraliaPosts: 306 |
Well I don't understand, despite above symbolic link MMEdit will not connect to COM4, seemingly it tries on COM1 and COM2. Interesting ser2net does not appear to be an option for me. The only rpm I found needed systemd, not on for me. |
||||
TassyJim![]() Guru ![]() Joined: 07/08/2011 Location: AustraliaPosts: 6283 |
If you select "Find Ports", MMEdit will start at COM1 and work up to COM64, testing each one in turn. If you are convinced that you need COM4, select COM4 and do not let MMEdit search. Try TeraTerm and see if you have more luck. VK7JH MMedit |
||||
plover![]() Guru ![]() Joined: 18/04/2013 Location: AustraliaPosts: 306 |
I am starting to think that despite my MMedit seems working under wine that I have screwed something up during install phase, not sure what yet. Using "Find Ports" I notice that I always get COM1 to COM4 options, with COM3 and COM4 flat out telling me, "can not connect to COM3 or COM4" if I try to open "MM CHAT". COM1 and COM2 will allow me to open CHAT but it will not respond to say "list" just ends in empty space but I find that if I try "MM Files Master" it will show files on the PC with empty pane for micro and shortly after opening it give a notice "No response from device". I think this is independent on having a USB connection made to the micro, so does not really tell me that a micro has been found. To set uo a COM port I use a symbolic link, placed in the "dosdevices' folder: ln -s /dev/ttyUSB0 /home/gert/.wine/dosdevices/COM2 Above action will set up: COM2 as a link to ttyUSB0 (Mup-v2) Similar I have set up: COM1 as a link to ttyACM0 (Maximite) Below shows my two options I would expect to work, but I am obviously missing something as it does not. [root@kde64byTexstar dosdevices]# ls -l COM1 lrwxrwxrwx 1 root root 12 Jul 16 19:15 COM1 -> /dev/ttyACM0 [root@kde64byTexstar dosdevices]# ls -l COM2 lrwxrwxrwx 1 root root 12 Jul 16 19:35 COM2 -> /dev/ttyUSB0 [root@kde64byTexstar dosdevices]# I am a bit worried about root being owner, but it does not seem to matter. I have tested setting myself as owner and makes no difference. I think I will un-install MMedit and start over again. I am finding that MMedit has disappeared out of the K-menu entry. I am starting MMedit from an Icon on the desktop. |
||||
plover![]() Guru ![]() Joined: 18/04/2013 Location: AustraliaPosts: 306 |
I will explain what I meant by "disappeared out of the K-menu entry". I deleted MMedit in the CCom folder, ie just deleted the folder CCom, that was my way of uninstalling. MMedit was not installed by "wine control" so this could not be used to uninstall. After deleting I the used "wine control" to install MMedit again, to my surprise this just created the same CCom folder. I was expecting to see an entry under K-menu (PC-menu) wine entries as shown in the picture: ![]() I know there are a few options in the CCom folder, for example the CF-gen option and uninstall. Some installs earlier did show MMedit in the PC-menu wine listings, with options but I don't remember exactly how many and I don't know at what stage MMedit dropped out from the PC-menu wine location. ZZzzz time here. ![]() |
||||
TassyJim![]() Guru ![]() Joined: 07/08/2011 Location: AustraliaPosts: 6283 |
I can't help you much with Wine. MMEdit would normally go into the CCom folder. I suggest you try running uninstall from the CCom folder. That should uninstall MMEdit but it will leave the user settings. The user data is in C:\Users\Jim\appdata\local\ccom\mmedit or similar. Simply delete the full folder for a clean install. As far as the serial ports, I can't help there either. Prove the ports using TeraTerm or Putty or some other Windows terminal program rather than using MMEdit. VK7JH MMedit |
||||
plover![]() Guru ![]() Joined: 18/04/2013 Location: AustraliaPosts: 306 |
You are helping more than you think. I am very intrigued, and curious because something is not behaving as I would expect. I don't believe it is MMedit that is the problem. When I connect with Minicom 2.7 or gtkterm, while they are not much good to do more than just confirm connection, both do not behave as I expected from previous experience. Well I have downloaded TeraTerm 4.88 and installed it under Wine ver 1.8 using the "wine control" (I do cheat when in hurry and just do "wine <whatever .exe file>" seems to work fine. "Wine control" looks like a GUI interface and allows install/uninstall via this graphics window. I did this for Tera Term, and now has the following in wine menu: ![]() If you have any idea why MMedit does not make an entry like that (as I said earlier I have seen it do that on an earlier version and I think too on the latest. Of course I can no longer recall well the details at the time) The only thing I can think of is the extra tick for memory patch, could that be it. That aside, when installing TT and getting used to how it operates, I have not yet been able to make a connection to the Mup-ver2 but what I did notice is that TT seems to have TCPIP option: ![]() Looks interesting but I do have a problem, don' know what I need to fill in. ![]() |
||||
plover![]() Guru ![]() Joined: 18/04/2013 Location: AustraliaPosts: 306 |
I have moved to my latest KDE 5 installation which has very small amount of cusomisation. Have installed wine, different to previous v 1.8 on older KDE: [gert@KDE64-plasma5 ~]$ wine --version wine-2.11 (Staging) [gert@KDE64-plasma5 ~]$ Turns out this made automatic linking to Mup-v2, I assume because USB connection made before startup. Not worked out if each time I power up get a new COMx port, but COM4 and COM5 linked to the ttyUSB0 (Mup-TTL) [gert@KDE64-plasma5 .wine]$ cd /home/gert/.wine/dosdevices [gert@KDE64-plasma5 dosdevices]$ ls -l com* lrwxrwxrwx 1 gert gert 10 Jul 17 12:41 com1 -> /dev/ttyS0 lrwxrwxrwx 1 gert gert 10 Jul 17 12:41 com2 -> /dev/ttyS1 lrwxrwxrwx 1 gert gert 12 Jul 17 12:19 com4 -> /dev/ttyUSB0 lrwxrwxrwx 1 gert gert 12 Jul 17 12:25 com5 -> /dev/ttyUSB0 [gert@KDE64-plasma5 dosdevices]$ I also installed with "wine control" two programs, MMedit and Tera Term, at the moment it is 1 score to MMedit 0 score to TT, so far it appears that TeraTerm will not offer more than COM1 and COM2 so no luck getting TT to work. This new KDE5 install has a poor Wine-menu unfortunately so I have more work trying to sort this out ![]() Very faint you can see "wine" been selected and in second list MMedit has been selected waiting for the click. The disappointing thing both the TT and MMedit options are lumped together. This must be wine or KDE problem. What I have proved is that MMedit does install into Wine-menu on the new system (I first installed without memory patch, would not run on the new system. Checked the Wine-menu was as shown and then I just re-installed on top of the existing system with memory patch option and it works fine) I got immediate contact with Mup-v2 when I selected COM4, next Maximite test on the KDE 5 system (PCLinuxOS) |
||||
TassyJim![]() Guru ![]() Joined: 07/08/2011 Location: AustraliaPosts: 6283 |
To get TeraTerm to find the serial ports you might have to edit the Wine registry. https://onetransistor.blogspot.com.au/2015/12/wine-serial-port-linux.html I don't have enough room on my Linux installation to install Wine but I might sacrifice an old laptop. Jim VK7JH MMedit |
||||
plover![]() Guru ![]() Joined: 18/04/2013 Location: AustraliaPosts: 306 |
It is now 2 points to MMedit and still nil points to TT. Had trouble getting MME to re-connect to the maximite, in the end I removed all wine COM links and created just COM2 and made sure this worked with Mup-v2 (ttyUSB0 linked) Then I created COM1 and got it to work with Maximite (ttyACM0) so now I am just about to go back to my KDE64 which is my battered work system, to see if I can get MMedit install "properly" and see if I can make connections. Then I will get back to TT, TCP/IP option looks interesting but who is the host, I am used to work in IP numbers and the micros do not have IP or perhaps they are not hosts? Will check up the link, some hours ago I pondered if it really was necessary to get into registry work. Never felt comfortable with that database. Just had email back from the Australian rep for my gas analyser, she passed on my request for a couple of chips, not actually denied but research very busy with a new release. In the mean time I am getting a new unit sent for use. Impressive customer service, I busted the chip, though now a bit doubtful as when I had it to pieces and applied power I got blinking lights, to be looked into. Should re-assemble and test but this terminal work has thrown me off course. Luckily it is raining the last few days. Excuse to be off the roof which I am cleaning so we can collect clean rainwater. |
||||
TassyJim![]() Guru ![]() Joined: 07/08/2011 Location: AustraliaPosts: 6283 |
Next time you are in MMEdit connect to the "test server" - top of the connect menu. That will connect you to a micromite here which is plugged into a Raspberry Pi running Linux and ser2net. ser2net links a serial port (USB or other) to a TCPIP Port number. You can use TCPIP to connect from MMEdit or TeraTerm. ser2net becomes the server or host. I use ser2net a lot and have multiple serial devices hanging of the same Pi. The server can be on the same PC as the client. Just connect to 'localhost' and the chosen port. That is the way I used Wine when I gave up trying to get a reliable serial port working. VK7JH MMedit |
||||
plover![]() Guru ![]() Joined: 18/04/2013 Location: AustraliaPosts: 306 |
Your test server have popped open a couple of times: 09:36:37 T(BMP085): 23.0 P(sl): 1006.9, T(DHT22): 22.6 H: 45.6, T(DS18B20): 22.7 09:36:47 T(BMP085): 22.9 P(sl): 1006.9, T(DHT22): 22.6 H: 45.6, T(DS18B20): 22.7 09:36:57 T(BMP085): 23.0 P(sl): 1007.0, T(DHT22): 22.5 H: 45.6, T(DS18B20): 22.7 Yes I have no trouble connecting to that. I am back on the 'work horse pc' and with some persistence I can now connect to both the Mup-v2 and Maximite but I must be on clear look out all the time as it seems the wine COM port linking keep shifting, actually when I come to think about it, when my Mup-v2 was reconnected I was caught out because the USB device file changed to ttyUSB1 and I think I just figured out why. I had a connection to Tera Term on ttyUSB0, that was a total disaster. I got the prompt from the Mup-v2 and I was connected in a fashion but very slow. The mouse stopped working well it was delayed many seconds so I gave up. Forgot to close down TT and of cause when I connected MME again and eventually found out that it now needed linking to ttyUSB1 (at which time I had shut down TT so ttyUSB0 did not show in the /dev/ directory. Ok, I think I can just about handle the connection in wine, MME clear winner. I will write down exact details which works for me. Doing it here will leave me a record I will remember for some weeks so when I go wrong next time it should be easier. Funny if I can get TT connected and get a such a poor result I must have something terribly wrong. |
||||
![]() ![]() ![]() ![]() |
![]() |
![]() |
The Back Shed's forum code is written, and hosted, in Australia. | © JAQ Software 2025 |