![]() |
Forum Index : Microcontroller and PC projects : PicoMite V6.00.02 release candidates - all versions
![]() ![]() ![]() ![]() |
|||||
Author | Message | ||||
toml_12953 Guru ![]() Joined: 13/02/2015 Location: United StatesPosts: 384 |
For a fast and easy lockup, try: erase flag() I know the syntax of the erase command doesn't allow parentheses, but they shouldn't lock up the interpreter. |
||||
matherp Guru ![]() Joined: 11/12/2012 Location: United KingdomPosts: 10010 |
yes they should. If the interpreter tries to trap everything it will slow to a halt. This and many other things can cause a lockup. Press reset and it starts again and then you can fix your code. |
||||
58kk90 Regular Member ![]() Joined: 14/06/2023 Location: United KingdomPosts: 59 |
This is RC8, and (just tested it) it still has the BIT command. For me (RP2040 VGA user) this was a stable version. The only issue I found was with font 7. But as I learned later, the above I2C issue with 256 bytes exists in rc8. 6.00.02rc8 But I think (when you ask Peter politely) he may bring the BIT command and function back, in addition to the FLAGS. Regards, Volhout Brilliant thank you very much, all downloaded and safely stored away. I did ask the question of Peter in an earlier post, but never got a reply, nor did the others that asked a similar question after I did, hence assuming it was now taboo and not coming back. Hopefully it will come back, as there is more than just me that wants it back from what I can see. Thanks once again Tony |
||||
Volhout Guru ![]() Joined: 05/03/2018 Location: NetherlandsPosts: 4824 |
58kk90, Download RC11, and check if the BIT is working again. Peter made a very quick fix, and BIT should work again. See 3 posts back. I assume it is there to stay... Thanks Peter!!!, Volhout PicomiteVGA PETSCII ROBOTS |
||||
ville56 Senior Member ![]() Joined: 08/06/2022 Location: AustriaPosts: 213 |
https://geoffg.net/Downloads/picomite/PicoMite_Beta.zip The Bit(ch) is back + > 255 i2c transfers should work - untested Sorry Peter, I2C transfers > 255 still cause a hang. N.B.: looking at the I2C bus protocol, all is normal, e.g. 256 bytes are tansfered and the transfer is normally terminated. Then the firmware "hangs", meaning no reboot but being completely unresponsive. Edited 2025-04-10 03:03 by ville56 73 de OE1HGA, Gerald |
||||
matherp Guru ![]() Joined: 11/12/2012 Location: United KingdomPosts: 10010 |
Need some simple example code to test with |
||||
ville56 Senior Member ![]() Joined: 08/06/2022 Location: AustriaPosts: 213 |
Need some simple example code to test with ' OPTION EXPLICIT OPTION DEFAULT NONE const i2c_addr = &H57 'any address will do, no matter if HW is connected const xfr_size = 256 '<= 255 ok, > 255 crash/reboot or hang dim integer eeprom_data(300) i2c read i2c_addr, 0, xfr_size, eeprom_data() end 73 de OE1HGA, Gerald |
||||
circuit Senior Member ![]() Joined: 10/01/2016 Location: United KingdomPosts: 268 |
https://geoffg.net/Downloads/picomite/PicoMite_Beta.zip The Bit(ch) is back + > 255 i2c transfers should work - untested Peter, thank you. I am delighted; as I was when this command/function first appeared. |
||||
Volhout Guru ![]() Joined: 05/03/2018 Location: NetherlandsPosts: 4824 |
@Peter, Tested on 2040 VGA design 2 with system I2C and RTC installed. RC11. I2C ---------------------------------- DIM e%(300) I2C2 READ &h57,0,255,e%() Works DIM e%(300) I2C2 READ &h57,0,256,e%() Does not work, crash (reboot). MATH V_PRINT ------------------------ DIM e%(300) I2C2 READ &h57,0,255,e%() MATH V_PRINT e%() Crashes (reboot) Regards, Volhout PicomiteVGA PETSCII ROBOTS |
||||
electricat![]() Senior Member ![]() Joined: 30/11/2020 Location: LithuaniaPosts: 288 |
Couldn`t resist ![]() This is part of some code I wrote while testing new BIT & FLAG Idea came to my restless head first time noticed new FLAG com/fn ![]() EXX`changes pair of FLAG 'registers' 'feed stray cats!! =(^^)= CLS Dim flag_% For n=0 To 63 Flag(n)=1 Next n For n=0 To 63 Print Flag(n); Next n Print Chr$(10)+"EXX"+Chr$(10) EXX For n=0 To 63 Print Flag(n); Next n Print Chr$(10)+"EXX"+Chr$(10) Flag(15)=1 EXX For n=0 To 63 Print Flag(n); Next n Print Chr$(10)+"EXX"+Chr$(10) EXX For n=0 To 63 If n=15 Then Color RGB(red),RGB(black) Print Flag(n); Color RGB(white),RGB(black) Else Print Flag(n); End If Next n Print Chr$(10)+"EXX"+Chr$(10) EXX For n=0 To 63 Print Flag(n); Next n Sub EXX(flag_%) Local swp% Static tmp_exx% Static tmp_ex% For n=0 To 63 iisset%=Flag(n) Bit(tmp_exx%,n)=iisset% Next n For n=0 To 63 iisset%=Bit(tmp_ex%,n) Flag(n)=iisset% Next n swp%=tmp_exx% tmp_exx%=tmp_ex% tmp_ex%=swp% End Sub My MMBasic 'sand box' |
||||
matherp Guru ![]() Joined: 11/12/2012 Location: United KingdomPosts: 10010 |
I've found and fixed the I2C issue - uint8_t variable used as the loop counter. Will update the downloads later |
||||
phil99![]() Guru ![]() Joined: 11/02/2018 Location: AustraliaPosts: 2407 |
DIM e%(300) I2C2 READ &h57,0,255,e%() MATH V_PRINT e%() Crashes (reboot) > DIM e%(300) > I2C2 READ &h57,0,255,e%() > MATH V_PRINT e%() 116, 121, 32, 66, 97, 114, 102, 97, 114, 115, 116, 32, 84, 72, 69, 32, 66, 65, 67, 75, '------etc > Edited 2025-04-10 18:35 by phil99 |
||||
bfwolf Regular Member ![]() Joined: 03/01/2025 Location: GermanyPosts: 68 |
@Peter Question about the Flag(n) "register": Is there a possiblility, to set/clr all (or multiple) flags in one step/assignment? bfwolf |
||||
matherp Guru ![]() Joined: 11/12/2012 Location: United KingdomPosts: 10010 |
RC11 updated if you re-download. Should fix the I2C issue Also adds FLAGS=n 'set/clear all the flag bits as required Edited 2025-04-10 20:07 by matherp |
||||
ville56 Senior Member ![]() Joined: 08/06/2022 Location: AustriaPosts: 213 |
I2C issue now fixed, thanks Peter. Great work. 73 de OE1HGA, Gerald |
||||
Volhout Guru ![]() Joined: 05/03/2018 Location: NetherlandsPosts: 4824 |
@Peter, RC11_2 on RP2040 VGA DESIGN 2 with RTC installed at GP14/15 (I2C2) I2C problem is fixed, MATH V_PRINT issue is not fixed. MATH V_PRINT ------------------------ DIM e%(300) I2C2 READ &h57,0,255,e%() MATH V_PRINT e%() Error: Invalid address Then crashes (reboot) Regards, Volhout PicomiteVGA PETSCII ROBOTS |
||||
matherp Guru ![]() Joined: 11/12/2012 Location: United KingdomPosts: 10010 |
Completely unrelated to the I2C issue. Bug that's been in V_Print for some time. Try this PicoMiteRP2040VGAV6.00.02RC11.zip |
||||
Volhout Guru ![]() Joined: 05/03/2018 Location: NetherlandsPosts: 4824 |
Peter, Yes that fixed it. Indeed have not used MATH V_PRINT since the thermal camera where I had to check if all the math worked as I expected. That would have been 6.00.00, even before the change to 6.00.01. Thanks for fixing it. V_PRINT is a handy tool during development. Volhout PicomiteVGA PETSCII ROBOTS |
||||
matherp Guru ![]() Joined: 11/12/2012 Location: United KingdomPosts: 10010 |
All versions in the download updated with V_PRINT fix. AFAIK no identified bugs in this version |
||||
toml_12953 Guru ![]() Joined: 13/02/2015 Location: United StatesPosts: 384 |
try DIM a(3,2) and fill the second row/column with zeros OPTION BASE 1 DIM a(3,3) DIM i(3,3) DIM b(2,3) DIM c(2,3) a(1,1)=1 a(2,1)=2 a(3,1)=3 a(1,2)=2 a(2,2)=4 a(3,2)=5 a(1,3)=3 a(2,3)=5 a(3,3)=6 b(1,1)=3 b(1,2)=4 b(1,3)=5 MATH M_INVERSE a(),i() MATH M_PRINT a() MATH M_PRINT i() MATH M_PRINT b() MATH M_MULT i(),b(),c() MATH M_PRINT c() FOR n = 1 TO 3 PRINT c(1,n) NEXT n RUN 1.0000, 2.0000, 3.0000 2.0000, 4.0000, 5.0000 3.0000, 5.0000, 6.0000 1.0000, -3.0000, 2.0000 -3.0000, 3.0000, -1.0000 2.0000, -1.0000, 0.0000 3.0000, 0.0000 4.0000, 0.0000 5.0000, 0.0000 1.0000, 0.0000 -2.0000, 0.0000 2.0000, 0.0000 1 -2 2 > For your purpose a second row of zeros seems to work I think that you can use MATH INSERT and MATH SLICE to interface to singe dimension arrays Jim Silly me! The solution was staring me in the face all the time! Instead of a matrinx, I can use a vector: 10 OPTION BASE 1 15 DIM C(3),B(3,3) 25 DIM A(3,3)=(1,2,3,2,4,5,3,5,6), X(3)=(3,4,5) 30 MATH M_INVERSE A(),B() 45 MATH M_PRINT B() 50 MATH V_MULT B(),X(),C() 60 PRINT "SOLUTIONS ARE " 65 PRINT 70 MATH V_PRINT C() 100 END |
||||
![]() ![]() ![]() ![]() |
![]() |
![]() |
The Back Shed's forum code is written, and hosted, in Australia. | © JAQ Software 2025 |