![]() |
Forum Index : Microcontroller and PC projects : PicoMite Alpha Firmware
![]() ![]() ![]() ![]() |
|||||
Author | Message | ||||
lizby Guru ![]() Joined: 17/05/2016 Location: United StatesPosts: 3298 |
Cool. > flash run 1 1 0 1 1 0 2 1 0 3 1 1 1 1 1 2 1 1 3 1 2 1 1 2 2 1 2 3 1 3 1 1 3 2 1 3 3 1 4 1 1 4 2 1 4 3 2 0 1 2 0 2 2 0 3 2 1 1 2 1 2 2 1 3 2 2 1 2 2 2 2 2 3 2 3 1 2 3 2 2 3 3 2 4 1 2 4 2 2 4 3 > flash load 1 > list ' test1.bas k=k+1 j=0 If k>2 Then End label: For i=1 To 3: subb : Next i: Inc j: If j>4 Then Flash chain 2 ' End GoTo label Sub subb: Print k;" ";j;" ";i: End Sub > flash load 2 > list Flash chain 1 > k gets incremented with each iteration of the flash 1 code when chained with flash 2. ~ Edited 2021-06-01 00:39 by lizby PicoMite, Armmite F4, SensorKits, MMBasic Hardware, Games, etc. on fruitoftheshed |
||||
Volhout Guru ![]() Joined: 05/03/2018 Location: NetherlandsPosts: 4811 |
@lizby: I tend to remember that both of us had one F4 that would enumerate (in my case earlier F4 code would, but newer code would not). While others had no problems. And both of us had one F4 that would not work after reflashing. Are we the only 2 that have pi pico's that will not enumerate ? Maybe there is something on our PC's that (BIOS version ?) that relates to this same issue. Am I making sense, or is this nonsense ? Volhout PicomiteVGA PETSCII ROBOTS |
||||
lizby Guru ![]() Joined: 17/05/2016 Location: United StatesPosts: 3298 |
Yes, I did early on have an F4 which wouldn't enumerate, but subsequently it did and I haven't had problems with F4s since (except the one I maybe just killed somehow). It will be interesting to see if anyone else has the problem with the picoMite. PicoMite, Armmite F4, SensorKits, MMBasic Hardware, Games, etc. on fruitoftheshed |
||||
Mixtel90![]() Guru ![]() Joined: 05/10/2019 Location: United KingdomPosts: 7458 |
A fun way to test FLASH CHAIN n :) n=2 j=i do inc i print i, loop until i=j+100 flash chain n copy into flash 1, 2 & 3 (and more if you feel ike it) edit each as follows: n=2 in flash 1 n=3 in flash 2 n=1 in flash 3 and just run whichever you are in at the time. :) Mick Zilog Inside! nascom.info for Nascom & Gemini Preliminary MMBasic docs & my PCB designs |
||||
matherp Guru ![]() Joined: 11/12/2012 Location: United KingdomPosts: 9992 |
a5 PicomiteV5.07.00a5.zip Fixes timer. I'm slowly replacing hack versions of commands with the full versions and cut and paste this one from the wrong source This is an important on as it is critical that the device works when not plugged into a computer. It works when I power from a USB Power bank or at least the heartbeat flashes. I would suspect D+ and D- must be in some sort of state so that the USB doesn't block but we can test this properly once we can do something with I/O and autorun to see a program is running when powered without a computer Jim: can you have a look at XMODEM S. In a5 it works for 9 blocks and then the receiver disconnects. Could be some sort of buffer overrun or automatically inserting LF or .... Many thanks |
||||
lizby Guru ![]() Joined: 17/05/2016 Location: United StatesPosts: 3298 |
On a laptop by a different manufacturer, my picomite still doesn't provide a com port unless it is flashed each time it is plugged in. PicoMite, Armmite F4, SensorKits, MMBasic Hardware, Games, etc. on fruitoftheshed |
||||
Mixtel90![]() Guru ![]() Joined: 05/10/2019 Location: United KingdomPosts: 7458 |
Have you tried a different micro usb lead? No idea if this would make a difference, but you never know. lol Mick Zilog Inside! nascom.info for Nascom & Gemini Preliminary MMBasic docs & my PCB designs |
||||
Plasmamac![]() Guru ![]() Joined: 31/01/2019 Location: GermanyPosts: 570 |
version A5 on pc works (win 10) on an standalone apple phone charger model A1300 led is blinking (works). blinks also on my powerbank hope this help Edited 2021-06-01 07:05 by Plasmamac Plasma |
||||
TassyJim![]() Guru ![]() Joined: 07/08/2011 Location: AustraliaPosts: 6210 |
I know I should have tested this direction with a big file! I can see 2 problems with sending from the pico. It looks like chr$(0) is getting dropped. CHR$(10) is getting converted to CHR$(13);chr$(10) Packet 10 is failing because the receiver is seeing packet number 13 instead of 10 (plus the extra character and checksum mismatch etc) Transfers will also fail if the checksum happens to be zero. The first character of the next packet gets seen instead and that will always be CHR$(1) Jim VK7JH MMedit |
||||
TassyJim![]() Guru ![]() Joined: 07/08/2011 Location: AustraliaPosts: 6210 |
Possibly related. When I first plugged my pico in with bootloader button pressed, I found that some ports on my USB 7 port hub didn't bring up the new drive. Other ports did work reliably. A 7 port hub will usually have cascaded 4 port hubs and I thing the bad ports were on the cascaded hub. I expect that the pico is going to be rather fussy about USB. I would try different ports if available, especially USB2 in preference to USB3. At some stage, my USB hub started behaving for all ports. Jim VK7JH MMedit |
||||
Volhout Guru ![]() Joined: 05/03/2018 Location: NetherlandsPosts: 4811 |
About crunching the program, I am not sure how we can keep the original program available using the build in editor. In a cmm2 the sd card is the second storage medium. With a pi pico there is only one storage medium. If we can only keep the original program by using an external IDE, like Mmedit, I suggest not to crunch the code. PicomiteVGA PETSCII ROBOTS |
||||
Volhout Guru ![]() Joined: 05/03/2018 Location: NetherlandsPosts: 4811 |
That is scary, when things start behaving....it's alive.... ![]() PicomiteVGA PETSCII ROBOTS |
||||
Volhout Guru ![]() Joined: 05/03/2018 Location: NetherlandsPosts: 4811 |
SD card... it just fits... ![]() PicomiteVGA PETSCII ROBOTS |
||||
Mixtel90![]() Guru ![]() Joined: 05/10/2019 Location: United KingdomPosts: 7458 |
Wow.... We are not worthy! lol Nice bit of wiring there. :) Mick Zilog Inside! nascom.info for Nascom & Gemini Preliminary MMBasic docs & my PCB designs |
||||
TassyJim![]() Guru ![]() Joined: 07/08/2011 Location: AustraliaPosts: 6210 |
Possibly related. When I first plugged my pico in with bootloader button pressed, I found that some ports on my USB 7 port hub didn't bring up the new drive. Other ports did work reliably. A 7 port hub will usually have cascaded 4 port hubs and I thing the bad ports were on the cascaded hub. I expect that the pico is going to be rather fussy about USB. I would try different ports if available, especially USB2 in preference to USB3. At some stage, my USB hub started behaving for all ports. Jim This could be the explanation (taken from the errata in the datasheet). controller requires 800us of idle (J-state) after a bus reset before moving to the CONNECTED state. Without this idle time, the USB device does not connect and will not receive any packets from the host, and so does not enumerate. A device reset happens just after the device is plugged in. Although a host will wait before talking to a reset device, other devices attached to the same USB hub may also be communicating with the host. USB 2.0 and USB 3.0 hubs have one or more transaction translators, which facilitate low speed and full speed transactions on a higher speed bus. It depends on the hub design, but a transaction translator is usually shared between a few ports. As the RP2040 USB device is full speed, its traffic when connected to a hub will come via a transaction translator. This means that if you have another device plugged in next to an RP2040, the RP2040 is likely to see some messages from the host addressed to the other device. If the device is not very active, for example, a mouse that is polled every 8ms, this is not a problem. However some devices, such as a USB serial port, are polled every 30-50us. In this case the bus is very active, and will cause the RP2040 to never exit RESET state and not connect. There is a software workaround for this issue (see workaround section). A user can also work around this by closing the USB serial port or any other offending devices while connecting their RP2040 and then re opening their USB serial port. On a larger hub, the problem may be fixed by moving the RP2040 far away (onto a different transaction translator) from the offending device. For example, connecting the RP2040 to port 1 of a 7 port hub, and connecting the USB serial console to port 7, may solve the issue. Connecting the RP2040 to a separate USB hub to any busy devices will also fix the problem. Jim VK7JH MMedit |
||||
Volhout Guru ![]() Joined: 05/03/2018 Location: NetherlandsPosts: 4811 |
@peter @lizby I ordered 2 pi pico's. Tested both for the coldboot problem. Board #1 enumerates correct on version a0 and a1 (29/30 times.. I tested 30 times) does not enumerate at all on version a2,a3,a4,a5 (*) Board #2 enumerates well with all versions a0...a5 I tried putting the board in conductive foam to ensure all IO pins are discharged when doing the test: no difference. The problem: a/ It is definitely board related b/ it is definitely software related (version a0 and a1 work) This makes me believe it is a timing issue, and the first area I would look for is the settling time of the PLL's. Probably on Board #1 the crystal oscillator starts different, the PLL's settle slower, and there is a timeout. Another thing to look at is the LED. Note, version a2 (that shows the problem) is the first version that has a blinking LED. Maybe in the control of GP25 (LED) has a side effect on GP23 (that controls the power supply). Peter: Not sure if you can look at the differences between a1 and a2, because there is where the degradation happens. And maybe it is just that enabling a peripheral in the chip increases ripple on the power supply, slowing down the settling of the PLL. As I understand the LED should also blink with a charger power supply. There is a direct relation (versions a2,a3,a4,a5) between blinking of the LED, and enumerating on USB. Therefore I think that the CPU does not run at all. Maybe the PLL is not given enough time to settle, the CPU starts to run at 500MHz, it can't, so it stops. I hope this helps.... Volhout (*) I tested on a PC where the pi is connected to the root hub. Edited 2021-06-01 18:06 by Volhout PicomiteVGA PETSCII ROBOTS |
||||
matherp Guru ![]() Joined: 11/12/2012 Location: United KingdomPosts: 9992 |
Jim Thanks for the diagnostic - I've fixed xmodem s On the difference between a0 to a2, I have changed the way the clock starts up in preparation for UART support. I'll put an extra wait loop in after the clock set up and see if that fixes it. The code is in bits at the moment so I'll post another alpha later today |
||||
Mixtel90![]() Guru ![]() Joined: 05/10/2019 Location: United KingdomPosts: 7458 |
I've been having a look at what info is available on the web and I can't see anything about pcb revisions for the Pico. The circuit looks pretty straightforward. If there are differences between boards then I can only think of two possible causes - the clock and the buck-boost converter. It might be instructive to see how quickly the 3v3 and 1v1 rails come up. Mick Zilog Inside! nascom.info for Nascom & Gemini Preliminary MMBasic docs & my PCB designs |
||||
CaptainBoing![]() Guru ![]() Joined: 07/09/2016 Location: United KingdomPosts: 2137 |
very neat! ![]() Before acquiring my laser I used to backwire most projects where I was doing one-offs/small runs. I find it quite therapeutic. The netlist from Eagle makes it really easy not to miss anything. Edited 2021-06-01 19:43 by CaptainBoing |
||||
matherp Guru ![]() Joined: 11/12/2012 Location: United KingdomPosts: 9992 |
a6 PicomiteV5.07.00a6.zip Delay on start up. XMODEM S should work |
||||
![]() ![]() ![]() ![]() |
![]() |