Home
JAQForum Ver 24.01
Log In or Join  
Active Topics
Local Time 12:42 27 Nov 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 : PicoMite/VGA/WEB V5.07.08 release candidates

     Page 15 of 18    
Author Message
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 9122
Posted: 05:36pm 18 Nov 2023
Copy link to clipboard 
Print this post

I've just tested OPTION DISK SAVE/XMODEM S fname$/XMODEM R fname1$/OPTION RESET/OPTION DISK LOAD fname1$ with RC19 as downloaded from Geoff's site (normal and VGA versions) on a windows PC (W11) with Teraterm and it works perfectly with the file size remaining at 768 bytes at all times. If you are seeing the filesize change then it is something in your environment that is causing the problem - sorry
Edited 2023-11-19 03:49 by matherp
 
stanleyella

Guru

Joined: 25/06/2022
Location: United Kingdom
Posts: 2129
Posted: 06:57pm 18 Nov 2023
Copy link to clipboard 
Print this post

never used xmodem, mmedit always. would a version without the inbuilt editor.. never mind, would it save memory?
 
karlelch

Senior Member

Joined: 30/10/2014
Location: Germany
Posts: 172
Posted: 07:50pm 18 Nov 2023
Copy link to clipboard 
Print this post

  matherp said  I've just tested OPTION DISK SAVE/XMODEM S fname$/XMODEM R fname1$/OPTION RESET/OPTION DISK LOAD fname1$ with RC19 as downloaded from Geoff's site (normal and VGA versions) on a windows PC (W11) with Teraterm and it works perfectly with the file size remaining at 768 bytes at all times. If you are seeing the filesize change then it is something in your environment that is causing the problem - sorry

Thanks for checking. This is pretty much the environment I used. Hmm
I’ll try it again (nuking the flash before I try); not before tomorrow evening though (I’m travelling)
 
karlelch

Senior Member

Joined: 30/10/2014
Location: Germany
Posts: 172
Posted: 07:57pm 18 Nov 2023
Copy link to clipboard 
Print this post

  stanleyella said  never used xmodem, mmedit always. would a version without the inbuilt editor.. never mind, would it save memory?

I never use mmedit, always the built-in editor …  
 
Mixtel90

Guru

Joined: 05/10/2019
Location: United Kingdom
Posts: 6798
Posted: 08:01pm 18 Nov 2023
Copy link to clipboard 
Print this post

AFAIK it wouldn't save memory. The editor and the variables share the same RAM, only one is present at once. It may be a major hassle to remove it anyway as it's been a part of MMBasic right from the beginning.
Mick

Zilog Inside! nascom.info for Nascom & Gemini
Preliminary MMBasic docs & my PCB designs
 
TassyJim

Guru

Joined: 07/08/2011
Location: Australia
Posts: 6099
Posted: 08:02pm 18 Nov 2023
Copy link to clipboard 
Print this post

  stanleyella said  never used xmodem, mmedit always.

What do you think MMEdit uses to transfer files to and from the picomite?
VK7JH
MMedit   MMBasic Help
 
TassyJim

Guru

Joined: 07/08/2011
Location: Australia
Posts: 6099
Posted: 08:20pm 18 Nov 2023
Copy link to clipboard 
Print this post

  matherp said  I've just tested OPTION DISK SAVE/XMODEM S fname$/XMODEM R fname1$/OPTION RESET/OPTION DISK LOAD fname1$ with RC19 as downloaded from Geoff's site (normal and VGA versions) on a windows PC (W11) with Teraterm and it works perfectly with the file size remaining at 768 bytes at all times. If you are seeing the filesize change then it is something in your environment that is causing the problem - sorry

I can confirm that the standard picomite gives the correct filesize.
I have reloaded the firmware on my WEBmite and tested again.
It reports a filesize of 772 bytes.
OPTION LIST
WebMite MMBasic Version 5.07.08RC19
OPTION CPUSPEED  250000 'KHz
OPTION WIFI xxxxx, **********, PICO6666666666
OPTION TCP SERVER PORT 80, 1000
OPTION TELNET CONSOLE ON
> option disk save "options2"
> print mm.info(filesize "options2.opt")
772
>

Can you test a WEBmite?

Jim
VK7JH
MMedit   MMBasic Help
 
phil99

Guru

Joined: 11/02/2018
Location: Australia
Posts: 2135
Posted: 09:07pm 18 Nov 2023
Copy link to clipboard 
Print this post

  Quote  Can you test a WEBmite?

A:/
  <DIR>  .
  <DIR>  ..
00:00 01-01-2000          4  bootcount
07:59 18-11-2023        772  WebMite 50708RC19.opt
2 directories, 2 files, 651264 bytes free
>

And after XMODEM S to PC becomes 896 bytes.
 
TassyJim

Guru

Joined: 07/08/2011
Location: Australia
Posts: 6099
Posted: 11:15pm 18 Nov 2023
Copy link to clipboard 
Print this post

Thanks Phil,
The options file is supposed to be 768 bytes, not the 722 that gets reported.
That is what is causing the issues on my system.

Jim
VK7JH
MMedit   MMBasic Help
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 9122
Posted: 08:42am 19 Nov 2023
Copy link to clipboard 
Print this post

I've updated the WebMite file in the download - should be OK now. Installing it will delete all options
 
TassyJim

Guru

Joined: 07/08/2011
Location: Australia
Posts: 6099
Posted: 09:00am 19 Nov 2023
Copy link to clipboard 
Print this post

That looks better.

It should be pointed out that the WIFI password is in plain text within the options file.
I wouldn't recommend having it on a system that is open to the big bad world.

Jim
VK7JH
MMedit   MMBasic Help
 
karlelch

Senior Member

Joined: 30/10/2014
Location: Germany
Posts: 172
Posted: 01:28pm 19 Nov 2023
Copy link to clipboard 
Print this post

@matherp:

I just downloaded the beta from Geoff's site (R19) and tested the VGA version. OPTION DISK LOAD/SAVE with intermittent XMODEM transfer now seems to work perfectly. Thanks!
 
stanleyella

Guru

Joined: 25/06/2022
Location: United Kingdom
Posts: 2129
Posted: 03:24pm 19 Nov 2023
Copy link to clipboard 
Print this post

  [ said  QUOTE=karlelch
I never use mmedit, always the built-in editor …  


The inbuilt editor is a great feature but as a beginner mmedit and win seemed just like using gcbasic editor, my previous basic for 8 bit I still use, even the program button at the top. It was all very familiar, so easy to get started with mmbasic."Which is more fun than 8 bit controllers"
 
stanleyella

Guru

Joined: 25/06/2022
Location: United Kingdom
Posts: 2129
Posted: 05:56pm 19 Nov 2023
Copy link to clipboard 
Print this post

  TassyJim said  
  stanleyella said  never used xmodem, mmedit always.

What do you think MMEdit uses to transfer files to and from the picomite?


need to know,I don't. As I need to know gcbasic uses averdude to flash atmeg. It just works.
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 9122
Posted: 08:55am 20 Nov 2023
Copy link to clipboard 
Print this post

V5.07.08RC20

https://geoffg.net/Downloads/picomite/PicoMite_Beta.zip

Changes

Fixes bugs in LOAD JPG

New Commands

MEMORY PRINT [#]fnbr , nbr, address%/array()
MEMORY INPUT [#]fnbr , nbr, address%/array()

These commands save or read data from or to memory from or to an open disk file

e.g.

dim a%(5)=(1,2,3,4,5,6)
open "test.txt" for output as #1
memory print #1,48,a%()
close #1
dim b%(6)
open "test.txt" for input as #1
memory input #1,48,b%()
close #1
? b%(3)
4



MATH SHIFT inarray%(), nbr, outarray%()

This command does a bit shift on all elements of inarray%() and places the result in outarray%() (may be the same as inarray%()). nbr can be between -63 and 63. Positive numbers are a left shift (multiply by power of 2). Negative number are a right shift.


WebMite only

WEB SCAN can now be used without a connection
WEB CONNECT has new optional parameters

WEB CONNECT [SSID$, PASSWD$, [NAME$] [,IPADDRESS$, MASK$, GATEWAY$]]

This command, with no optional parameters,  will connect to the default network if possible (as previously set with OPTION WIFI) or with the new parameters will connect to the network specified and also set up the OPTIONS for future use.

Together WEB SCAN and WEB CONNECT allow the user to connect to their a new network without previously setting using OPTION WIFI

WEB CONNECT does not disconnect from a previously connected network so should only be used where nothing has been previously set up or where a previously configured network is not active or a previously configured network has previously failed to connect on boot (no parameters)
 
Volhout
Guru

Joined: 05/03/2018
Location: Netherlands
Posts: 4243
Posted: 09:07am 20 Nov 2023
Copy link to clipboard 
Print this post

@Peter,

MEMORY PRINT/MEMORY INPUT
Looking at the example I assume variable "nbr" is the number of bytes. Correct?
In the example, you MEMORY PRINT the whole array (6x8=48 bytes).

Volhout

P.S. I love the MATH SHIFT in combination with PIO.... new project...
Edited 2023-11-20 19:09 by Volhout
PicomiteVGA PETSCII ROBOTS
 
phil99

Guru

Joined: 11/02/2018
Location: Australia
Posts: 2135
Posted: 12:03pm 20 Nov 2023
Copy link to clipboard 
Print this post

A:/> XMODEM SEND
Error: Invalid address - resetting
PicoMiteVGA MMBasic Version 5.07.08RC20
Copyright 2011-2023 Geoff Graham
Copyright 2016-2023 Peter Mather

A:/>

Xmodem Send works for files but not for the loaded program on the VGA Pico.
Xmodem Receive works for both modes.
 
matherp
Guru

Joined: 11/12/2012
Location: United Kingdom
Posts: 9122
Posted: 05:16pm 20 Nov 2023
Copy link to clipboard 
Print this post

V5.07.08RC21

https://geoffg.net/Downloads/picomite/PicoMite_Beta.zip

Fixes a bug in XMODEM S on the VGA version (NB: will erase all options and the A: drive on the VGA version)

New commands

DEVICE WII OPEN [interrupt]
DEVICE WII CLOSE

NB: the DEVICE command replaces the BITBANG command. You can still use BITBANG but it will be converted to DEVICE in the program listing and editor

The Wii Classic must be wired to the pins specified by OPTION SYSTEM I2C which is a prerequisite. Open attempts to talk to the Wii Classic and will return an error if not found. If found the firmware will sample the Wii data in the background at a rate of 50Hz. If an optional user interrupt is specified this will be triggered if any of the buttons changes (both on and off)

New FUNCTION

DEVICE(WII funct)

Returns data from a Wii Classic controller.
'funct' is a 1 or 2 letter code indicating the information to return as follows:
LX returns the position of the analog left joystick x axis
LY returns the position of the analog left joystick y axis
RX returns the position of the analog right joystick x axis
RY returns the position of the analog right joystick y axis
L returns the position of the analog left button
R returns the position of the analog right button
B returns a bitmap of the state of all the buttons. A bit will be set to 1 if the
button is pressed.
T returns the ID code of the controller - should be hex &H4200101
The button bitmap is as follows:
BIT 0: Button R
BIT 1: Button start
BIT 2: Button home
BIT 3: Button select
BIT 4: Button L
BIT 5: Button down cursor
BIT 6: Button right cursor
BIT 7: Button up cursor
BIT 8: Button left cursor
BIT 9: Button ZR
BIT 10: Button x
BIT 11: Button a
BIT 12: Button y
BIT 13: Button b
BIT 14: Button ZL

Example code

Device wii open myint
Pause 1000
Do
Loop
Sub myint
 Static integer l%=0
 m%=1
 a%=DEVICE(wii b)
 t%=l% Xor a%
 If t% And m% Then
   If a% And m% Then : Print "R_ON":Else : Print "R_OFF":EndIf
 EndIf
 Inc m%,m%
 If t% And m% Then
   If a% And m% Then : Print "Start_ON":Else : Print "Start_OFF":EndIf
 EndIf
 Inc m%,m%
 If t% And m% Then
   If a% And m% Then : Print "Home_ON":Else : Print "Home_OFF":EndIf
 EndIf
 Inc m%,m%
 If t% And m% Then
   If a% And m% Then : Print "Select_ON":Else : Print "Select_OFF":EndIf
 EndIf
 Inc m%,m%
 If t% And m% Then
   If a% And m% Then : Print "L_ON":Else : Print "L_OFF":EndIf
 EndIf
 Inc m%,m%
 If t% And m% Then
   If a% And m% Then : Print "DOWN_ON":Else : Print "DOWN_OFF":EndIf
 EndIf
 Inc m%,m%
 If t% And m% Then
   If a% And m% Then : Print "RIGHT_ON":Else : Print "RIGHT_OFF":EndIf
 EndIf
 Inc m%,m%
 If t% And m% Then
   If a% And m% Then : Print "UP_ON":Else : Print "UP_OFF":EndIf
 EndIf
 Inc m%,m%
 If t% And m% Then
   If a% And m% Then : Print "LEFT_ON":Else : Print "LEFT_OFF":EndIf
 EndIf
 Inc m%,m%
 If t% And m% Then
   If a% And m% Then : Print "ZR_ON":Else : Print "ZR_OFF":EndIf
 EndIf
 Inc m%,m%
 If t% And m% Then
   If a% And m% Then : Print "X_ON":Else : Print "X_OFF":EndIf
 EndIf
 Inc m%,m%
 If t% And m% Then
   If a% And m% Then : Print "A_ON":Else : Print "A_OFF":EndIf
 EndIf
 Inc m%,m%
 If t% And m% Then
   If a% And m% Then : Print "Y_ON":Else : Print "Y_OFF":EndIf
 EndIf
 Inc m%,m%
 If t% And m% Then
   If a% And m% Then : Print "B_ON":Else : Print "B_OFF":EndIf
 EndIf
 Inc m%,m%
 If t% And m% Then
   If a% And m% Then : Print "ZL_ON":Else : Print "ZL_OFF":EndIf
 EndIf
 l%=a%
End Sub


Edited 2023-11-21 03:17 by matherp
 
thwill

Guru

Joined: 16/09/2019
Location: United Kingdom
Posts: 4042
Posted: 07:37pm 20 Nov 2023
Copy link to clipboard 
Print this post

  matherp said  V5.07.08RC21...


I'm personally not a fan of the Wii Classic controller, but I guess the more the merrier; I foresee another round of PCBs. I can certainly add a driver SUB for this to my controller library if anyone is interested, but not until the New Year when I'll add a Wiichuck breakout board to my next AliExpress order.

  matherp said  
T returns the ID code of the controller - should be hex &H4200101


I believe it is  actually &hA4200101, note the leading A. IIRC there was a typo in the CMM2 manual to this effect; I think I have brought it up before. Is that where you got your information from ?

Thanks for your continued efforts,

Tom
Edited 2023-11-21 08:48 by thwill
Game*Mite, CMM2 Welcome Tape, Creaky old text adventures
 
Mixtel90

Guru

Joined: 05/10/2019
Location: United Kingdom
Posts: 6798
Posted: 11:48am 21 Nov 2023
Copy link to clipboard 
Print this post

Someone may find this useful...

Pre-Manual.zip
Mick

Zilog Inside! nascom.info for Nascom & Gemini
Preliminary MMBasic docs & my PCB designs
 
     Page 15 of 18    
Print this page
© JAQ Software 2024