![]() |
Forum Index : Microcontroller and PC projects : Pi-cromite: V5.05.01
![]() ![]() |
|||||
Author | Message | ||||
goc30![]() Guru ![]() Joined: 12/04/2017 Location: FrancePosts: 435 |
Hi Matherp I have a small problem with my GPS it is a "gsm/gprs/gnss hat " I work in 115200 baudrate and sometime I receive bad char in usb mode I have no problem ![]() my program test Open "com1:115200" As #1 Dim a$ As string print #1,"AT+CGNSPWR=1" pause(100) print #1,"AT+CGNSTST=1" pause(100) Do If Loc(#1)=>1 Then a$=Input$(1,#1) Print a$; End If Loop |
||||
matherp Guru ![]() Joined: 11/12/2012 Location: United KingdomPosts: 10000 |
Are you receiving a bad character (i.e. checksum incorrect) or is it the output to the screen that is corrupting? All serial I/O on the Pi-cromite is bitbanged as the real UARTs can't be used (the best one is dedicated for bluetooth, the other changes speed when the CPU throttles) so it is best to keep baudrates as low as possible. Nothing I can do about this. No, but you can write code that causes a problem and Linux has buffers that can fill up. Are you printing to a disconnected console or anything similar? |
||||
lew247![]() Guru ![]() Joined: 23/12/2015 Location: United KingdomPosts: 1702 |
Peter on the normal MM you can use Pin 1 to reset the processor Is there any way to reset Picromite through a hardware pin or software so if say a reset button was pressed then Picromite would reboot |
||||
lizby Guru ![]() Joined: 17/05/2016 Location: United StatesPosts: 3299 |
Peter--PM sent re pi-cromite source. PicoMite, Armmite F4, SensorKits, MMBasic Hardware, Games, etc. on fruitoftheshed |
||||
matherp Guru ![]() Joined: 11/12/2012 Location: United KingdomPosts: 10000 |
SYSTEM "sudo shutdown - r now" After Christmas I'll send it to Geoff to be included on the list of downloads |
||||
lizby Guru ![]() Joined: 17/05/2016 Location: United StatesPosts: 3299 |
Or to restart (if you have autostart of mmbasic set up): SYSTEM "sudo reboot" (Although the shutdown with -r option for reboot may be cleaner.) PicoMite, Armmite F4, SensorKits, MMBasic Hardware, Games, etc. on fruitoftheshed |
||||
goc30![]() Guru ![]() Joined: 12/04/2017 Location: FrancePosts: 435 |
Are you receiving a bad character (i.e. checksum incorrect) or is it the output to the screen that is corrupting? All serial I/O on the Pi-cromite is bitbanged as the real UARTs can't be used (the best one is dedicated for bluetooth, the other changes speed when the CPU throttles) so it is best to keep baudrates as low as possible. Nothing I can do about this. I have checksum error each time, If I use card with usb output (not by rpi), all frames are corrects |
||||
goc30![]() Guru ![]() Joined: 12/04/2017 Location: FrancePosts: 435 |
After change baudrate (9600Bd), it work correctly For me it's enough, but I think that Picromite can't work with high speed like 115200 bds |
||||
lizby Guru ![]() Joined: 17/05/2016 Location: United StatesPosts: 3299 |
After Christmas I'll send it to Geoff to be included on the list of downloads Thanks. If you could, please also include a readme with some notes or links about setting up the tool chain for cross compiling from the PC to the pi. I'm somewhat familiar with the tool chain process from having built them for a decade for the openWrt linux OS for small router devices--but that was mostly plug and play. PicoMite, Armmite F4, SensorKits, MMBasic Hardware, Games, etc. on fruitoftheshed |
||||
matherp Guru ![]() Joined: 11/12/2012 Location: United KingdomPosts: 10000 |
I used this to get set up. I don't provide support for source/building - sorry. |
||||
JohnS Guru ![]() Joined: 18/11/2011 Location: United KingdomPosts: 3988 |
Sounds wrong (if using the hardware uart(s), don't know what else may be in use). John |
||||
matherp Guru ![]() Joined: 11/12/2012 Location: United KingdomPosts: 10000 |
As per my previous post. Pi-cromite can't and doesn't use H/W UARTs. Pi only has 2, one not on header and the other useless as changes speed when you aren't looking |
||||
JohnS Guru ![]() Joined: 18/11/2011 Location: United KingdomPosts: 3988 |
I suppose just document the practical max where people like the poster will actually find it. 9600 seems quite slow. John |
||||
disco4now![]() Guru ![]() Joined: 18/12/2014 Location: AustraliaPosts: 965 |
SYSTEM "sudo shutdown - r now" I dont think there should be a space between - and r. i.e. should be like this SYSTEM "sudo shutdown -r now" Latest F4 Latest H7 FotS |
||||
JohnS Guru ![]() Joined: 18/11/2011 Location: United KingdomPosts: 3988 |
Correct. Well spotted! John |
||||
lizby Guru ![]() Joined: 17/05/2016 Location: United StatesPosts: 3299 |
I used this to get set up. I don't provide support for source/building - sorry. I now have netbeans set up on my laptop and compiling on a Pi 3B+. This was much more complicated than I anticipated. Maintenance of netbeans has been transferred from Oracle to Apache. Apache says it is the biggest chunk of source they maintain, and they are working through it to make sure that all of the many components satisfy the Apache copyright requirements. They have made two releases, but these don't include C/C++. They have a roadmap, but C support is not expected to be released until the 3rd quarter. I faffed about a good deal, trying guides which were out of date. Finally I used wayback to find an Windows Netbeans 8.2 release with C/C++. It installed with no problem and the rest of the link you provided was good. So I'm ready for pi-cromite source, when it is convenient. Can you tell me whether your netbeans mmbasic environment is set up for C89, C99, or C++? What other factors do I need to consider? Thanks. PicoMite, Armmite F4, SensorKits, MMBasic Hardware, Games, etc. on fruitoftheshed |
||||
goc30![]() Guru ![]() Joined: 12/04/2017 Location: FrancePosts: 435 |
Hi Peter I install my prog test on Pi-cromite All seem to work correctly exept "Sprites" on "SPRITE load", it make an error (buffer in use) it load image but not sprite if I run your sprites programme it can't load image" I put here 2 progs 2019-04-30_134015_pi_sprites.zip |
||||
matherp Guru ![]() Joined: 11/12/2012 Location: United KingdomPosts: 10000 |
I think there is a bug in your program. In line 1038 you load sprite 1 and then in line 1056 you try and load it again - this gives the error. However, you have prompted me to bring the Pi version up-to-date with the latest changes. I'll post an new version in a specific thread when built. |
||||
goc30![]() Guru ![]() Joined: 12/04/2017 Location: FrancePosts: 435 |
Hi peter yes it is my fault, my mega fault!!! ![]() in line 1038, it is juste test to know if sprite function is installed or not now I add "Sprite Close 1" to unload in fact I was deceived by the lack of problem on Mz version, and the fact that we can load a file multiple times, I think that it is same for sprites |
||||
![]() ![]() |
![]() |