Menu
JAQForum Ver 19.10.27

Forum Index : Microcontroller and PC projects : PicoMite V6.00.02 release candidates - all versions

   Page 11 of 52    
Posted: 03:08pm
24 Mar 2025
Copy link to clipboard
ville56
Senior Member

@Peter,

list variables does what it says, but .... the output is a bit hard to use ....

> list variables gives the following output:

DIM FLOAT F_LEN_MMDIM FLOAT F_SCALEDIM FLOAT F_SPEEDDIM INTEGER EVTDIM INTEGER I2CADDRDIM INTEGER I2CADDR1DIM INTEGER I2CADDR2DIM INTEGER IDLEDIM INTEGER IDXDIM INTEGER KEY_EFDIM INTEGER LONG_PRESS_SIGDIM INTEGER MEASDIM INTEGER MENUE_MODEDIM INTEGER MIN_DDIM INTEGER R1DIM INTEGER R1_F_NDIM INTEGER R1_LDIM INTEGER R1_N_FDIM INTEGER R2DIM INTEGER R2_F_NDIM INTEGER R2_LDIM INTEGER R2_N_FDIM INTEGER R_ENC_DIRDIM INTEGER R_ENC_STATEDIM INTEGER R_KEY_STATEDIM INTEGER ROT_CNTDIM INTEGER ROT_EFDIM INTEGER ROT_ENC_DIRDIM INTEGER ROT_ENC_STATEDIM INTEGER ROT_KEY_LONGDIM INTEGER ROT_KEY_STATEDIM INTEGER ROT_KEY_TIMEDIM INTEGER ROT_PIN_STATEDIM INTEGER ROT_PINNR_ADIM INTEGER ROT_PINNR_BDIM INTEGER ROT_PINNR_KEYDIM INTEGER ROT_STATE_TABLE(4)DIM INTEGER S1_BGDIM INTEGER S2_BGDIM INTEGER START_TIMEDIM INTEGER STATEDIM INTEGER STOP_VARIABLEDIM INTEGER TIME_DIFFDIM STRING PIN_ADIM STRING PIN_BDIM STRING PIN_KEYDIM STRING SCALE_TYPELOCAL INTEGER I2C_ADDRLOCAL INTEGER NUM_BTLOCAL INTEGER RANGELOCAL INTEGER READRANGECONTMMLOCAL INTEGER READREGLOCAL INTEGER REGLOCAL INTEGER REG_CONT(4)

>

IMHO a newline after each variable would enhance readability ...

Environment: PicoMite MMBasic RP2350A Edition V6.00.02RC7, console output via MMCC.

for me this is a long missed feature. Thank you for implementing !!

Regards,
Gerald

Note: just deleted the statement about missing DIM. Reading the output with the brain enabled did help .... sorry
Edited 2025-03-25 01:20 by ville56
 
Posted: 03:28pm
24 Mar 2025
Copy link to clipboard
matherp
Guru

  Quote  IMHO a newline after each variable would enhance readability ...

There is a newline when I use it with teraterm or on the VGA or HDMI output

  Quote  The PIO CONFIGURE version complains about using pins double.


OK.

This is the new code doing that as you can see it checks for a PIO specified pin being either not configured, a digital input or a PIO pin for that pio.
If I read the code correctly, you have got a pin (GP1) used by PIO as the jmp pin that is configured as a digital output. I assume this is somewhat artificial and that in a real application the gate would be an externally driven pin?

The question is what to do? I think, in general, the validation is correct but perhaps I should include the ability to override it.

Thoughts?

  Quote  int getGPpin(unsigned char *pinarg, int pio, int base){
char code;
       int pin;
if(!(code=codecheck(pinarg)))pinarg+=2;
pin = getinteger(pinarg);
if(!code)pin=codemap(pin);
       if(IsInvalidPin(pin)) error("Invalid pin");
       if(!(ExtCurrentConfig[pin] == EXT_NOT_CONFIG ||
               ExtCurrentConfig[pin] == EXT_DIG_IN ||
               (ExtCurrentConfig[pin] == EXT_PIO0_OUT && pio==0) ||
               (ExtCurrentConfig[pin] == EXT_PIO1_OUT && pio==1)
#ifdef rp2350
               || (ExtCurrentConfig[pin] == EXT_PIO2_OUT && pio==2)
#endif
       )) error("Pin in use");
       if(PinDef[pin].GPno<base || PinDef[pin].GPno>base+31)error("Pin out of range for base %");
       return PinDef[pin].GPno;

}

Edited 2025-03-25 01:38 by matherp
 
Posted: 04:18pm
24 Mar 2025
Copy link to clipboard
JanVolk
Senior Member

Oled I2C display not working anymore.

> OPTION LIST
PicoMite MMBasic RP2040 Edition V6.00.02RC6
OPTION CPUSPEED (KHz) 200000
> OPTION SYSTEM I2C GP4,GP5
> LIST PINS
GP0      1      OFF
GP1      2      OFF
GP2      4      OFF
GP3      5      OFF
GP4      6      Boot Reserved : SYSTEM I2C SDA
GP5      7      Boot Reserved : SYSTEM I2C SCL
GP6      9      OFF
GP7      10     OFF
GP8      11     OFF
GP9      12     OFF
GP10     14     OFF
GP11     15     OFF
GP12     16     OFF
GP13     17     OFF
GP14     19     OFF
GP15     20     OFF
GP16     21     OFF
GP17     22     OFF
GP18     24     OFF
GP19     25     OFF
GP20     26     OFF
GP21     27     OFF
GP22     29     OFF
GP23     41     DOUT
GP24     42     DIN
GP25     43     HEARTBEAT
GP26     31     OFF
GP27     32     OFF
GP28     34     OFF
GP29     44     AIN
> LIST SYSTEM I2C
HEX  0  1  2  3  4  5  6  7  8  9  A  B  C  D  E  F
00: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
30: -- -- -- -- -- -- -- -- -- -- -- -- 3C -- -- --
40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
70: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
> OPTION LCDPANEL SSD1306I2C, L
Error : Pin 6/GP4 is reserved on startup

It still works in RP2040 Edition V6.00.01

> OPTION LIST
PicoMite MMBasic RP2040 Edition V6.00.01
OPTION SYSTEM I2C GP4,GP5
OPTION COLOURCODE ON
OPTION PICO OFF
OPTION DISPLAY 44, 92
OPTION LCDPANEL SSD1306I2C, LANDSCAPE
>

Greetings,

Jan.
 
Posted: 04:40pm
24 Mar 2025
Copy link to clipboard
matherp
Guru

  Quote  Oled I2C display not working anymore.


Thanks for the report - will fix
 
Posted: 05:14pm
24 Mar 2025
Copy link to clipboard
matherp
Guru

RC7 updated if you re-download

Fixes bug in OPTION LCDPANEL SSD1306I2C and other I2C display variants
Relaxes validation of pins in PIO CONFIGURE

Harm: Your test program and LA_24_2 (unmodified) both confirmed to run
 
Posted: 05:53pm
24 Mar 2025
Copy link to clipboard
Volhout
Guru

RC7_2 seems okay also. Tested on the main programs.

Volhout
 
Posted: 05:54pm
24 Mar 2025
Copy link to clipboard
Volhout
Guru

RC7_2 seems okay also. Tested on the main programs on VGA 2040.

Volhout
Edited 2025-03-25 03:54 by Volhout
 
Posted: 06:09pm
24 Mar 2025
Copy link to clipboard
JohnS
Guru

  matherp said  
PIO Configure pio, sm, clock [,startaddress]
[,sidesetbase] [,sidesetno] [,sidesetout]
[,setbase] [,setno] [,setout] [,outbase] [,outno] [,outout] [,inbase]
[,jmppin] [,wraptarget] [,wrap] [,sideenable] [,sidepindir]
[,pushthreshold] [,pullthreshold] [,autopush] [,autopull] [,inshiftdir] [,outshiftdir]
[,joinrxfifo] [,jointxfifo] [,joinrxfifoget] [,joinrxfifoput]



hmm, I suspect it really should be

PIO Configure pio, sm, clock, [startaddress],
[sidesetbase], [sidesetno], [sidesetout],
[setbase], [setno], [setout], [outbase], [outno], [outout], [inbase],
[jmppin], [wraptarget], [wrap], [sideenable], [sidepindir],
[pushthreshold], [pullthreshold], [autopush], [autopull], [inshiftdir], [outshiftdir],
[joinrxfifo], [jointxfifo], [joinrxfifoget], [joinrxfifoput]


Although I think trailing commas can be omitted so the above should have all the bracketed parts nested (not shown as it's horrible)...

John
 
Posted: 06:43pm
24 Mar 2025
Copy link to clipboard
ville56
Senior Member

  matherp said  
There is a newline when I use it with teraterm or on the VGA or HDMI output


Sorry Peter, there are no newline ... please see attached screenshot with control chars visible.

List-vars.zip
 
Posted: 07:06pm
24 Mar 2025
Copy link to clipboard
homa
Guru



> option list
PicoMiteHDMI MMBasic USB RP2350A Edition V6.00.02RC7
OPTION SERIAL CONSOLE COM2,GP8,GP9
OPTION SYSTEM I2C GP20,GP21
OPTION FLASH SIZE 4194304
OPTION COLOURCODE ON
OPTION KEYBOARD GR
OPTION CPUSPEED (KHz) 315000
OPTION RESOLUTION 640x480
OPTION SDCARD GP22, GP26, GP27, GP28
OPTION AUDIO GP10,GP11', ON PWM CHANNEL 5
OPTION RTC AUTO ENABLE
OPTION MODBUFF ENABLE  192
OPTION PLATFORM HDMIUSB
>




  ville56 said  
  matherp said  
There is a newline when I use it with teraterm or on the VGA or HDMI output


Sorry Peter, there are no newline ... please see attached screenshot with control chars visible.

List-vars.zip


That is astonishing ...

Matthias
Edited 2025-03-25 05:08 by homa
 
Posted: 07:11pm
24 Mar 2025
Copy link to clipboard
toml_12953
Guru

  matherp said  V6.00.02RC7 is available on

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


Isn't TIMER supposed to be the number of milliseconds since either power-on, reset or setting it to 0? If so, I'd expect an integer. When I print TIMER, though, it prints three decimal places. Why?

If I set TIMER to 0 at the beginning of a routine, can I just divide TIMER by 1000 at the end to get the number of seconds elapsed?
 
Posted: 07:20pm
24 Mar 2025
Copy link to clipboard
toml_12953
Guru

  ville56 said  
  matherp said  
There is a newline when I use it with teraterm or on the VGA or HDMI output


Sorry Peter, there are no newline ... please see attached screenshot with control chars visible.

List-vars.zip


I get the same output as you do no linefeeds. I use TeraTerm 5.40 on Windows 11.

I tried setting the terminal New-line options but no combination of CR and LF changes it. My terminal ID is VT100.
 
Posted: 07:26pm
24 Mar 2025
Copy link to clipboard
matherp
Guru

Try again now

Worked on all versions with a console set up but not on the standard version without an LCD configured as a console

  Quote  Isn't TIMER supposed to be the number of milliseconds since either power-on, reset or setting it to 0? If so, I'd expect an integer. When I print TIMER, though, it prints three decimal places. Why?


Yes but accurate to the microsecond

  Quote  If I set TIMER to 0 at the beginning of a routine, can I just divide TIMER by 1000 at the end to get the number of seconds elapsed?


Yes
Edited 2025-03-25 05:28 by matherp
 
Posted: 07:48pm
24 Mar 2025
Copy link to clipboard
homa
Guru


PicoMiteHDMI MMBasic USB RP2350A Edition V6.00.02RC7
option list see above

PicoMite User Manual, Page 137:
PLAY PAUSE will temporarily halt the currently playing file or tone.


> play modfile "bigjapan-625.mod"
Playing biginjapan
> play pause
Error : Nothing playing


Question: Is this behaviour normal? this is my first time trying something with MODfiles, so I don't know the behaviour.

Matthias
 
Posted: 07:53pm
24 Mar 2025
Copy link to clipboard
ville56
Senior Member

ad LIST VARIABLES:

is now working on RP2350 without LCD console ... thanks Peter !!!!
 
Posted: 07:57pm
24 Mar 2025
Copy link to clipboard
matherp
Guru

Pause isn't available with MOD files. I can probably enable it if it is genuinely useful? Alternatively, I'll just update the manual.
 
Posted: 08:10pm
24 Mar 2025
Copy link to clipboard
homa
Guru


  matherp said  Pause isn't available with MOD files. I can probably enable it if it is genuinely useful? Alternatively, I'll just update the manual.

Counter question: Does the command "PLAY MODSAMPLE Samplenum, channel[,volume]" still work when PAUSE is active? Or would no samples be played?
 
Posted: 08:54pm
24 Mar 2025
Copy link to clipboard
toml_12953
Guru

  matherp said  Try again now

Worked on all versions with a console set up but not on the standard version without an LCD configured as a console

  Quote  Isn't TIMER supposed to be the number of milliseconds since either power-on, reset or setting it to 0? If so, I'd expect an integer. When I print TIMER, though, it prints three decimal places. Why?


Yes but accurate to the microsecond

  Quote  If I set TIMER to 0 at the beginning of a routine, can I just divide TIMER by 1000 at the end to get the number of seconds elapsed?


Yes


Great! list variables works fine now. Thanks!
 
Posted: 09:04pm
24 Mar 2025
Copy link to clipboard
ville56
Senior Member

Peter,

typing  ~  character and CR at the commandline makes the firmware unresponsive (hang) which can only be cured by HW reset.

Tried with RP2350 with LCD and RP2350 with OLIMEX HDMI adapter

Edit: Just found out that a ~ on any position on the commandline hangs the firmware.


Gerald
Edited 2025-03-25 07:08 by ville56
 
Posted: 09:58pm
24 Mar 2025
Copy link to clipboard
JohnS
Guru

  ville56 said  Peter,

typing  ~  character and CR at the commandline makes the firmware unresponsive (hang) which can only be cured by HW reset.

Tried with RP2350 with LCD and RP2350 with OLIMEX HDMI adapter

Edit: Just found out that a ~ on any position on the commandline hangs the firmware.


Gerald

Are you typing the ~ (tilde) direct or through a terminal app?

If the latter it's likely the app as tilde is sometimes special.

John
 
   Page 11 of 52    
The Back Shed's forum code is written, and hosted, in Australia.
© JAQ Software 2025