Raspberry Pi 4

More
26 Feb 2020 14:17 #158541 by MrGreg
Replied by MrGreg on topic Raspberry Pi 4
Hello

Firstly
@ tjtr33 I would like to have a discussion with you about Picnc. PM or open a new thread, if that's OK?

Secondly:
I also did an extended latency test(s) over last night in through the morning. Different approach and different (ish) results

First test part 1
Reason for approach: To test if internal Pi h/keeping etc was causing a big latency by itself?
Gene's RT cold boot.
No other progs /processes started IE none!
Start latency-test period
Initially and for a minute or so
16uS ..... ( glimpsed magic pink unicorn )
23uS 10 mins
58uS 9 hours
"Thinks" cause for optimism?

First test part 2
Without reboot or other intervention before starting next phase (latency test still running)
Glxgears @1080p
Web browser (Firefox) with heavy java on 2 tabs
202uS
File(s) transfer of circa 100MB on SD ( to / from SD)
202uS
Left to simmer on load for further 30 mins
243uS
Left to simmer for further 90 mins
243uS

Hmmm Curious?
Same load conditions and time (2hrs) as previous tests, but applied differently gives quite different results. Also added a Dir/file transfer in to see if that had an effect.
But no, stuck solidly at 243uS for circa 2+hrs.
A little short of 12hrs in total IE pt1 & pt2

Test 2 ( repeat original test)
Glxgears + webserver with x2 heave java script pages ( same as orig previous tests)
restart latency-test period
Initially 98uS
30mins 320uS
2hrs 340uS

Not quite what i was seeing before. Similar start, but no big hike in latency after 90mins

Seems not what you do but the way you do it?

The npt thing may well be worth a look. However if it using npdt? I think that is considered depreciated and may only have a limited future? Hmmm. Prob best I take a look at it.

Re your comments:
Yes, in the real world, I would not be running anything more than the cnc and possibly an editor to tinker with gcode. Nothing else.
I'm not confident about using soft stepping from gpio atm.
Mesa or perhaps Picnc? 7kHz per axis is a minimum/must So is the "Axis" Gui !!
For me, 14kHz per axis, 4axis max is enough. I currently achieve that with a Pi2-Picnc combo.
So yes, both prob doable on Pi4 - Buster.

Thanks for the info & pics
BTW look forward to chat about picnc if poss?

Cheers
MrGreg

Please Log in or Create an account to join the conversation.

More
02 Mar 2020 10:00 - 02 Mar 2020 10:00 #158956 by gtt38
Replied by gtt38 on topic Raspberry Pi 4
Nobody told which version of the RPI4 (size of memory used) and cooling.
There is a huge difference between the RPI4 with 1Go and 4Go of RAM.
Due to thermal throttling i've seen a huge difference when i installed a fan with a heater.
I don't care about latency since i'm using an FPGA. The raspberry is not the Beaglebone, there is no PRU. So using RPI GPIO for Fast I/O is limited i think.
The cheapest way to have fast I/O on RPI could be a STM32 in SPI using the Hostmot2 RPSPI driver as start.
github.com/LinuxCNC/linuxcnc/blob/master...hostmot2/hm2_rpspi.c
Last edit: 02 Mar 2020 10:00 by gtt38.

Please Log in or Create an account to join the conversation.

More
04 Mar 2020 02:06 #159136 by blazini36
Replied by blazini36 on topic Raspberry Pi 4

Nobody told which version of the RPI4 (size of memory used) and cooling.
There is a huge difference between the RPI4 with 1Go and 4Go of RAM.
Due to thermal throttling i've seen a huge difference when i installed a fan with a heater.
I don't care about latency since i'm using an FPGA. The raspberry is not the Beaglebone, there is no PRU. So using RPI GPIO for Fast I/O is limited i think.
The cheapest way to have fast I/O on RPI could be a STM32 in SPI using the Hostmot2 RPSPI driver as start.
github.com/LinuxCNC/linuxcnc/blob/master...hostmot2/hm2_rpspi.c


I came across this thread searching for info on the PICnc. It was mentioned in the MK group and while that thread doesn't sound super interesting to me , the PICnc does. Low cost isn't a huge concern for me, I'm more interested in small things that can run LinuxCNC that I can attach a custom purpose-built daughtercard to with hostmot2-like configureabillity. I was almost there with the mksocfpga which is an awesome idea, but I'd pretty much be stuck with MK and it's outdatedness and the embedded arm cores typically being a bit too weak.

I know nothing about writing firmware and such but I'm wondering if the PICnc project can be resurrected with a decent STM32 or PIC32. Is any of that code PICnc code portable to a more stout micro and an Rpi4? Is it something that the LinuxCNC code wizards would get behind?

Please Log in or Create an account to join the conversation.

More
04 Mar 2020 04:00 #159147 by BeagleBrainz
Replied by BeagleBrainz on topic Raspberry Pi 4
I was using MK on a BeagleBoneBlack with a homemade cape and 3.3v to 5v translator boards. The slow graphics on the backplot never seemed to be too much of an issue. The PRU step & direction was pretty good.....but Linuxcnc has better support and seems to have more active development.

Please Log in or Create an account to join the conversation.

More
04 Mar 2020 05:20 #159148 by blazini36
Replied by blazini36 on topic Raspberry Pi 4

I was using MK on a BeagleBoneBlack with a homemade cape and 3.3v to 5v translator boards. The slow graphics on the backplot never seemed to be too much of an issue. The PRU step & direction was pretty good.....but Linuxcnc has better support and seems to have more active development.

I made this for the de10-nano running mksocfpga
drive.google.com/file/d/1ih-1KqdshXeu-BH...Qf/view?usp=drivesdk

That worked great but I doubt anyone is going to move mksocfpga into linuxcnc, and MK seems like it's about a year from completely stalling out.

The stm32 dev boards are dirt cheap and an stm32 based on the cortex M4 is probably plenty fast for handling IO from a rpi over spi

Please Log in or Create an account to join the conversation.

More
04 Mar 2020 05:41 #159149 by BeagleBrainz
Replied by BeagleBrainz on topic Raspberry Pi 4
Someone forget to make that link shareable ? ;)

Yeah....lots of big ideas with MK, but not a lot of work done.

I saw a while ago that someone was working with the BBB, but bare metal, for cnc motion control. Tried look for the links, but to no avail.

Personally ATM I think the ol' X86 (_64) platform has the best long term viability. As long as the PC platform still has non-usb Ethernet running MESA Ethernet motion control is still a good long team option. Even more so for those that do commercial installations. Plus the fact I am unaware of the RPi being certified for industrial use.
Now what would be interesting is a BBB with similar specs to the RPi4 and still keeping the PRU subsystem.

Please Log in or Create an account to join the conversation.

More
04 Mar 2020 08:56 #159166 by tommylight
Replied by tommylight on topic Raspberry Pi 4
@Blazini,
Check PiDiCnc, they have stepper and servo +-10V boards for RPI3, so should work on RPI4.
I still have 2 of them, they do work nicely and are quite versatile. Also stackable, with IO boards available.
The stepper version has also 4 places for small drives directly on the board so it end up as a very small full control system.
I have used the stepper one for testing, a lot, it never failed.
Unfortunately, there are still no prices on their website, been told they should be around 80Euro, so very good price. The board and connector quality is top notch. And they provide 5V for the PI, so only 1 power supply needed.

Please Log in or Create an account to join the conversation.

More
04 Mar 2020 20:45 #159219 by MrGreg
Replied by MrGreg on topic Raspberry Pi 4
Hello
I have largely replicated the same latency results as tj-33 ( Tomp ) with similar settings & loadings.
(Pi4)
Briefly as follows; (1ms servo)
Start ~ 29us
9.5hrs ~ 51us with 4 x glxgears
Ditto + web browser ~ 168us
11.5hrs ~ 191us

Looking quite positive.
Thanks to all , especially GH for providing RT kernel & stuff.

Cheers
MrGreg

Please Log in or Create an account to join the conversation.

More
04 Mar 2020 21:46 #159225 by gtt38
Replied by gtt38 on topic Raspberry Pi 4

Someone forget to make that link shareable ? ;)

Yeah....lots of big ideas with MK, but not a lot of work done.

I saw a while ago that someone was working with the BBB, but bare metal, for cnc motion control. Tried look for the links, but to no avail.

Personally ATM I think the ol' X86 (_64) platform has the best long term viability. As long as the PC platform still has non-usb Ethernet running MESA Ethernet motion control is still a good long team option. Even more so for those that do commercial installations. Plus the fact I am unaware of the RPi being certified for industrial use.
Now what would be interesting is a BBB with similar specs to the RPi4 and still keeping the PRU subsystem.

That’s why I was talking about a STM32 which could be used as a PRU. Many packages available but a 64pin could be enough. I explored the possibility of porting Hostmot2 to a small CPLD too, it could be possible I think for Stepgen but I don’t think that it could support all the HM2 functions...

Please Log in or Create an account to join the conversation.

More
04 Mar 2020 21:50 #159226 by MrGreg
Replied by MrGreg on topic Raspberry Pi 4
@ blazini36 ( and indeed tommylight & all)

Yes as you may have guessed, I'm also V interested in reviving / resurrecting Picnc to run on Pi3 and prob more likely long term Pi4.

Re your comments Re Picnc on the MK forum, Guessing you mean this one?
groups.google.com/forum/#!topic/machinekit/wDCXCINWqTM

It's rather confused, the OP seems to have quite different intentions than his initial post suggested.

I think the subject is worthy of further discussion, but on a thread of its own. I will do that if there is any apparent further interest in the matter.

Re PiDiCnc ( Just saying for historical reference)
It has its roots in Picnc. The author/co author/whatever.. of PiDiCnc "Viktan" was quite active in the RPIforum topic where Picnc was started ( initially Linuxcnc)
See ( starts here & there 40+ pages of it, A Very long read)
www.raspberrypi.org/forums/viewtopic.php...ad3805e465d425241e2d
And referencing his driver here.
forum.linuxcnc.org/27-driver-boards/2974...stem?start=50#115691

The Author of Picnc is "kinsamanka" BTW

I was quite attracted to PiDiCnc, Have kept an eye in it over the last couple of years, but also have reservations about, lack of price info, future prospects, source? general inactivity on his website, to mention a few.
The reported price point of 80Euro does seem attractive and good value for money. As to whether it works on a Pi4? Best you ask them first.

I think I had better buy another Pi4 to do some more dedicated testing.

Cheers
MrGreg
The following user(s) said Thank You: tommylight

Please Log in or Create an account to join the conversation.

Time to create page: 0.130 seconds
Powered by Kunena Forum