Home
JAQForum Ver 20.06
Log In or Join  
Active Topics
Local Time 18:45 17 May 2024 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 : CMM2: Bug reports

     Page 4 of 17    
Author Message
thwill

Guru

Joined: 16/09/2019
Location: United Kingdom
Posts: 3863
Posted: 02:27pm 06 Jun 2020
Copy link to clipboard 
Print this post

You're welcome. Time to update my firmware.

Regards,

Tom
Game*Mite, CMM2 Welcome Tape, Creaky old text adventures
 
thwill

Guru

Joined: 16/09/2019
Location: United Kingdom
Posts: 3863
Posted: 02:38pm 06 Jun 2020
Copy link to clipboard 
Print this post

Hmm, Windows 10 doesn't like your latest zip file:



7-zip will extract the .bin, but the result is 666K long instead of the 671K recorded in the archive.

???
Game*Mite, CMM2 Welcome Tape, Creaky old text adventures
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 8604
Posted: 03:33pm 06 Jun 2020
Copy link to clipboard 
Print this post

Try again. I just used W10 to replace the file in the archive. So it replaces it and then complains about what it has done: WTF?
 
thwill

Guru

Joined: 16/09/2019
Location: United Kingdom
Posts: 3863
Posted: 04:41pm 06 Jun 2020
Copy link to clipboard 
Print this post

OK, that can be extracted, and after a fight with Windows10 and STM32CubeProggammer ... don't know what it was up to ... I have it installed.

But I'm sorry to report that the following which used to work now never exits the loop:

Cls
f$ = "minizork.z3"
Open f$ For Input As #1
Do
 s$ = Input$(255, #1)
 If Len(s$) = 0 Then Exit Do
 a = a + Len(s$)
 Print a
Loop
Close #1


... once it reaches the end of the file it just keeps reporting back a single character read.

Very similar to the first(?) bug I ever reported.


Edited 2020-06-07 02:52 by thwill
Game*Mite, CMM2 Welcome Tape, Creaky old text adventures
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 8604
Posted: 04:57pm 06 Jun 2020
Copy link to clipboard 
Print this post

That was in the first release of 5.05.02. Try downloading again.

"Re-engineered INPUT$ from files to better fix a bug that was reported earlier"

PS

do
loop while not eof(n)

was tested and worked perfectly
Edited 2020-06-07 02:59 by matherp
 
thwill

Guru

Joined: 16/09/2019
Location: United Kingdom
Posts: 3863
Posted: 05:06pm 06 Jun 2020
Copy link to clipboard 
Print this post

  matherp said  That was in the first release of 5.05.02. Try downloading again.

"Re-engineered INPUT$ from files to better fix a bug that was reported earlier"

PS

do
loop while not eof(n)

was tested and worked perfectly


OK ...  a fresh download seems to work now ... scratches head and looks confused

Thanks,

Tom
Game*Mite, CMM2 Welcome Tape, Creaky old text adventures
 
vegipete

Guru

Joined: 29/01/2013
Location: Canada
Posts: 1085
Posted: 10:44pm 08 Jun 2020
Copy link to clipboard 
Print this post

After a month of waiting, I can finally play!

I found something odd with local variable types:
'variable type test

testint

end

sub testint
 local a,b as integer
 local integer c,d

 a = 7/3
 b = 7/3
 c = 7/3
 d = 7/3

 print a
 print b
 print c
 print d

end sub
OUTPUT:

2.333333333
2
2
2


Variable 'a' seems to be a real, all others are integer.

Edit: using version 5.0502
Edit #2: could be that I don't understand what "as integer" means or applies to.
Edited 2020-06-09 08:55 by vegipete
Visit Vegipete's *Mite Library for cool programs.
 
JohnS
Guru

Joined: 18/11/2011
Location: United Kingdom
Posts: 3677
Posted: 10:48pm 08 Jun 2020
Copy link to clipboard 
Print this post

I think you'd need the 2nd form or
local a as integer,b as integer

John
 
TassyJim

Guru

Joined: 07/08/2011
Location: Australia
Posts: 5923
Posted: 10:54pm 08 Jun 2020
Copy link to clipboard 
Print this post

  vegipete said  
I found something odd with local variable types:

sub testint
 local a,b as integer
 local integer c,d



Variable 'a' seems to be a real, all others are integer.

Edit: using version 5.0502


From the manual:
  Quote  DIM nbr AS INTEGER, s AS STRING


In your case, 'a' has not been declared specifically so it becomes whatever the default type is.

This is the same for all versions of MMBasic (which support INTEGERS)

Jim

PS enjoy your new toy!
VK7JH
MMedit   MMBasic Help
 
KeepIS

Guru

Joined: 13/10/2014
Location: Australia
Posts: 1399
Posted: 05:38am 09 Jun 2020
Copy link to clipboard 
Print this post

I'm editing a small program, around 30 lines, only short lines of code.

When copying and pasting I'm "sometimes" getting an Esc sequence at the insert point. Other times I get nothing, other times the pasted code appears, but as soon as you try to edit the inserted code, it suddenly disappears or changes to @@@@@@@.
Same if you save it and go back to edit, the pasted code has disappeared or been replaced by an ESC sequence.

?[?251?[H   The 1st and 3rd ? are white background, likely signalling an ESC char.  

It's independent of the code.

What I'm doing is this:

Towards the bottom of the screen:
Pressing F4 and selectin a line of code
Using the up key to move up about 35 lines and pressing F5

Results vary as above, again it can then suddenly start behaving again.  

I'm sure this has something to do with using the cursor to go up, page-up then cursor down seems ok. I'm not scrolling the page, it's just a single page of code.

Latest MM basic loaded, tried reloading.

BTW. I really think this is just a fantastic piece of kit.

EDIT: Removed a description of a minor CTRL-C problem, turns out to be the keyboard size and big hands holding the release of the c on occasions.
Edited 2020-06-09 15:51 by KeepIS
It's all too hard.
Mike.
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 8604
Posted: 06:56am 09 Jun 2020
Copy link to clipboard 
Print this post

  Quote  When copying and pasting I'm "sometimes" getting an Esc sequence at the insert point.


USB keyboard or Serial console? If the latter just the console screen or both? Does this only happen with programs less than a full page long?
Edited 2020-06-09 16:57 by matherp
 
KeepIS

Guru

Joined: 13/10/2014
Location: Australia
Posts: 1399
Posted: 07:58am 09 Jun 2020
Copy link to clipboard 
Print this post

  matherp said  
USB keyboard or Serial console? If the latter just the console screen or both? Does this only happen with programs less than a full page long?


USB keyboard, haven't had a need to use a console, but I'll try that now as well.

The last program I was editing was just over a page at 60 lines.

FYI: I have the console output to both as I was modifying a WIN application for the CMM2, serial speed is 230400. When this was happening, NO Win program was connected to the serial console. I'll also have a try with serial console disabled.
It's all too hard.
Mike.
 
KeepIS

Guru

Joined: 13/10/2014
Location: Australia
Posts: 1399
Posted: 08:40am 09 Jun 2020
Copy link to clipboard 
Print this post

I've just spent around 15 minutes doing some copy / cut paste and run edit cycles,   it took that long (15 minutes) before it reappeared.

1: Using the USB keyboard
2: Suddenly when go to paste I get ESC codes.
3: On one occasion it looks like there were a number of ESC codes buried in the insert line, I thought it had done a paste correctly, it looked ok, then as I started to delete some code a dozen lines above the last paste point, the code pasted disappeared and was replaced by @@@@@@@@@@, as I deleted those, more ESC sequence codes appeared. The editor became unusable as more @@@ were inserted as I typed, so triple ESC, then back into edit and it all worked once again.

I may not get time tonight to fully test this with a console terminal but I will.

Once again this is just short lines of code, longest at around 23 chars.
A few variable and a couple of Do While loops with a few print statements.
It's all too hard.
Mike.
 
KeepIS

Guru

Joined: 13/10/2014
Location: Australia
Posts: 1399
Posted: 08:51am 09 Jun 2020
Copy link to clipboard 
Print this post

I've just got it to do this in TeraTerm.

The give away is when you mark and copy, then do a Paste, nothing gets pasted.
You think you must have not copied, (no message about nothing to paste though)
when I try to copy & paste again @@@@@@@@@@@@@@@ all in white background.

When you start to delete those @@@@@@@ everything looks good, type a few chars and all looks good, go to the line below and delete a char and the line turns into an ESC sequence and you simply can't edit correctly. Triple ESC and it's ok for a while.

Mike.
.
.
Edited 2020-06-09 19:07 by KeepIS
It's all too hard.
Mike.
 
vegipete

Guru

Joined: 29/01/2013
Location: Canada
Posts: 1085
Posted: 03:43pm 09 Jun 2020
Copy link to clipboard 
Print this post

  matherp said  USB keyboard or Serial console? If the latter just the console screen or both? Does this only happen with programs less than a full page long?

I'm seeing this too, but haven't found a pattern yet. USB keyboard, programs can be multiple pages long. On at least two occasions, the pasted text generated a "line too long" error message at the bottom of the screen and an unrelated character was repeated many many times before the pasted text.

Sorry for the vague description, I'll try harder to identify how to reproduce this.

I also had one instance of INSERT mode turning into OVERSTRIKE mode, <INSERT> key had no effect. USA keyboard. I haven't reproduced it again, maybe it was something else I did.
Visit Vegipete's *Mite Library for cool programs.
 
vegipete

Guru

Joined: 29/01/2013
Location: Canada
Posts: 1085
Posted: 08:53pm 09 Jun 2020
Copy link to clipboard 
Print this post

Something odd is happening in the editor. As KeepIS says, it seems to take a while before anything happens. This last time, I had just used F4-mark to select a bunch of lines, pressed <Del> to erase them and typed a new line with 15 characters. Then I was pressing <PageUp> <PageDown> alternately to show someone the entire program, in this instance 53 lines worth total. Suddenly the last line I had typed got whacked. I pressed <F1> to save, then moved the SD card to a computer and opened the BASIC file in Notepad++. All 15 of the characters I had typed displayed as [NUL].

I fixed the wrecked line, saved, put the SD card back into the CMM2 and reloaded the program. Of course, when I try similar actions, nothing weird happens...

Other times, I have seen what look like [esc] codes or somesuch jibberish appear.

As before, latest firmware, USB keyboard, NO console connection.

===============
On a side note, when copying and pasting an entire line (or more), an extra <newline> gets pasted at the end.

===============
On a different side note, would it be possible to have <SHIFT> <arrow keys> select text for cut/copy/paste/delete? Also, if there is text in the copy buffer, could it replace selected text?

And while you are at it, could you wash my car and mow my lawn?  ;-)

Matherp, you are doing an awesome job with the firmware!!! Thank very much for your and everyone else's work on the CMM2!
Visit Vegipete's *Mite Library for cool programs.
 
TassyJim

Guru

Joined: 07/08/2011
Location: Australia
Posts: 5923
Posted: 03:13am 10 Jun 2020
Copy link to clipboard 
Print this post

A problem with CWD$
this works OK
cl$=CWD$ or PRINT CWD$

but CM$ = CWD$ + myfile$
gives unreliable results for CWD$

PRINT
cl$=CWD$
cm$ = cl$ + "myprog.bas"
PRINT cm$
PRINT CWD$

PRINT
cm2$ = CWD$ + "myprog.bas"
PRINT cm2$
PRINT CWD$

PRINT
cl$=CWD$
cm$ = cl$ + "myprog.bas"
PRINT cm$
PRINT CWD$

PRINT
cm2$ = CWD$ + "myprog.bas"
PRINT cm2$
PRINT CWD$


Output:
  Quote  
A:/MAZE3Dmyprog.bas
A:/MAZE3D

myprog.basmyprog.bas
A:/MAZE3D

A:/MAZE3Dmyprog.bas
A:/MAZE3D

myprog.bas
A:/MAZE3D
>


Ignore the missing backslash, that is checked for in the real code.

Jim
VK7JH
MMedit   MMBasic Help
 
vegipete

Guru

Joined: 29/01/2013
Location: Canada
Posts: 1085
Posted: 03:20am 10 Jun 2020
Copy link to clipboard 
Print this post

The file manager doesn't seem to set a default clut when it runs. If a program has modified the clut and is stopped with CTRL-C, the file manager happily runs with the modified clut, which can lead to unexpected colours, particularly the highlite colour.

Edit: The highlite colour in the editor is affected too.
Edited 2020-06-10 13:25 by vegipete
Visit Vegipete's *Mite Library for cool programs.
 
thwill

Guru

Joined: 16/09/2019
Location: United Kingdom
Posts: 3863
Posted: 08:48am 10 Jun 2020
Copy link to clipboard 
Print this post

BUG: LIST FILES can tell you that the disk is empty

To reproduce

1. Reset Waveshare

2. LIST FILES
 - You get the list of files in root

3. LIST FILES ".."
 - Not sure what the behaviour should be, but it is:
> list files ".."
A:/
0 directories, 0 files


4. LIST FILES
 - The behaviour is definitely wrong since it now tells you the disk is empty:
> list files
A:/
0 directories, 0 files


5. And it will keep telling you it is empty until you reset again.
Game*Mite, CMM2 Welcome Tape, Creaky old text adventures
 
thwill

Guru

Joined: 16/09/2019
Location: United Kingdom
Posts: 3863
Posted: 08:57am 10 Jun 2020
Copy link to clipboard 
Print this post

BUG: More fun and games with LIST FILES

To reproduce

1. Reset Waveshare

2. MKDIR "subdir"

3. CHDIR "subdir"

4. EDIT "foo.txt"
  - add some content

5. LS "."
  - output is incorrect:
> ls "."
A:/SUBDIR
0 directories, 0 files


6. LS
  - output is incorrect, same fritzed state as above requiring a reset:
> ls
A:/SUBDIR
0 directories, 0 files


Also

1. Repeat steps 1, 3 & 4 from above

2. LS ".."
  - output is incorrect:
> ls ".."
A:/SUBDIR
0 directories, 0 files


3. LS
  - output is incorrect, same fritzed state as above requiring a reset:
> ls
A:/SUBDIR
0 directories, 0 files


Also

I hate to tell you this, and I haven't reproduced it yet, but whilst fritzing around with the file commands I ended up with the SD card being unreadable, sorry I forgot to note the error message and had to reformat ... fortunately didn't lose anything important.

Regards,

Tom
Game*Mite, CMM2 Welcome Tape, Creaky old text adventures
 
     Page 4 of 17    
Print this page
© JAQ Software 2024