Advanced Search

Search Results (Searched for: raspberry)

13 Oct 2023 10:46

lcec_conf: ERROR: couldn't allocate user/RT shared memory

Category: EtherCAT

I am trying to build a deb based on github.com/rodw-au/linuxcnc-ethercat. I will notify you if it works. However, the chip on my development board is not quite the same as the Raspberry Pi, but it should be usable.
13 Oct 2023 09:51

lcec_conf: ERROR: couldn't allocate user/RT shared memory

Category: EtherCAT

A couple of things
1. This repo of mine should compile and create a deb file of the linuxcnc-ethercat driver.
github.com/rodw-au/linuxcnc-ethercat
I had a bit of help here from one of the ethercat developers.
I did this so I could package it for AMD64 and host it. Then the repositories are preinstalled in my installer in the installing linuxcnc section here (as a sticky). forum.linuxcnc.org/9-installing-linuxcnc...or-linuxcnc-x86-only

I have thought of building it for the pi4 and hosting it too.
It should compile on ARM, Please let me now if it does.

2. The ethercat guys now have a repository and support the Raspberry Pi, Please open the spoilers for details here
forum.linuxcnc.org/ethercat/45336-etherc...-how-to-step-by-step 



 
12 Oct 2023 19:33

Remora - ethernet NVEM / EC300 / EC500 cnc board

Category: Computers and Hardware

Hello, I'm hoping I can get some help here.  I'm beyond frustrated at this point trying to get my board flashed, Ive been at this for 8 hours at this point and am about to give up, a hammer to this ec500 I've got sitting here may be the best solution at this point.  I'm pretty sure I got my st link flashed using the CMSIS-DAP file from the repository.  But it seems no matter what I do I cannot get the pyocd command to flash the board I keep getting the Message, Import Error: No module named abc.  I know its referring to the collections library but have no idea how to fix it to move forward.  Google doesn't seem to have any idea either, other than its a default library that comes with python that seems to be missing something.  The computer I'm working on has a fresh install of linuxcnc on it, and this is the only linux machine I've got to work with here at home.  I've also tried doing all of this using my windows laptop thinking that may help.  Haven't gotten any further there, can't get the pyocd command to work on the command line there.  Im sure something is missing from the PATH variable on that machine.  There again trying to find anything useful online hasn't been much help.  I think I'm missing something simple.  I think I may have finally gotten it.  Downgrading the python version on the windows machine seemed to work.

 

I use my windows machine for flashing and development work. So it is possible to get it working, but as you said this looks to be a python issue. I'd check to see which pythong version etc.

It should be as simple as
python -m pip install -U pyocd
pyocd flash .\remora-rt1052.axf --target mimxrt1050_quadspi

The Raspberry Pi Pico Probe has shown to the easiest out of the box solution for flashing.
12 Oct 2023 12:34

Remora - ethernet NVEM / EC300 / EC500 cnc board

Category: Computers and Hardware

Hey, Scott (or any volunteer)!

Have you had the time to look at my config files that are causing the following errors? I use the remora-nvem-basic config from github.com/scottalford75/Remora-NVEM/tree/main/LinuxCNC, also attached to this message.
Hi, I've had a look at your config files and they are identical to mine, and I can run with a 1000% feed override without following errors....

Now I'm really scratching my head to understand what could be going on. Do you have the serial debug output connected? It would be interesting to see if there are any issues on the board.
 

Let me explain exactly what I have done. Maybe you can spot something that I've done wrong.
- Full chip erase on NVEM using STM32 ST-LINK Utility
- Flash NVEM with Remora-NVEM-STM32-1.0.0.bin from github.com/scottalford75/Remora-NVEM/tree/main/Firmware using STM32 ST-LINK Utility
- Install Raspberry Pi OS (Legacy) 32 bit
- Install LinuxCNC and realtime Kernel according to forum.linuxcnc.org/9-installing-linuxcnc...n-raspberry-pi-3b-pi
- Copy github.com/scottalford75/Remora-NVEM/tre...es/remora-nvem-basic to /home/pi/linuxcnc/configs
- Copy github.com/scottalford75/Remora-NVEM/tre...Components/Remora-nv to /home/pi/linuxcnc/components
- Install remora-nv component using
sudo halcompile --install remora-nv.c
- Install pyocd using [code]pip3 install pyocd
- Write config to NVEM using [code]python3 upload_config.py config.txt

And that's it I think. Can you spot anything I might have done wrong?

I do not have the serial debug output connected, but I can do that if there is a guide I can follow. Do you happen to have one? [img]/media/kunena/emoticons/smile.png[/img]
[/code][/code]

[code][code][url=https://github.com/scottalford75/Remora-NVEM/tree/main/LinuxCNC/Components/Remora-nv][code][code][code]Ping response times are longer than I'm getting though, averaging around 0.17ms. Do you have a router in between the NVEM and computer?
 
No router. 2 meter cable directly from the Pi to the NVEM. Is the response time high enough to cause these errors you think?



As the response time becomes worse it changes the amount of pre-anticipation the linuxcnc software has to take in the algorithm hence PGain in order to make up for it. High ping time can cause ferror, but also can not having enough response time from the cpu on linuxcnc itself. I highly recommend you make sure your linuxcnc setup is correct and your following all recommendations by linuxcnc, also older kernels are slower and have worse response time in the real time kernel, so if linuxcnc has a timer thats supposed to go off every 1ms and the raspberrypi cpu timer goes off at 1.1ms and then the response time on the board is 0.3ms or up to 0.6ms now you are 1.13 to 1.16ms out of sync.
[/code][/code][/url][/code][/code][/code]
 

Thanks a lot for your explanation! I knew LinuxCNC wouldn't be easy, but this is just something else...

I did a quick search for LinuxCNC PID, and there are a lot of parameters to use, but I would guess that not all are used. Do you, or anyone else, happen to have a small demo of what it would look like if I were to implement it?

You wrote something about disabling background services in Debian. Could you elaborate? I'm pretty much completely new when it comes to Linux, so I wouldn't know what services to disable, or how to disable them.

I will also give a go at installing Debian 12 and the latest realtime kernel if I can figure out how to install it. So far I've been relying on other people's step-by-step guides on this forum.
12 Oct 2023 03:47

Debian 12 - 2.10 master branch image for the Raspberry Pi 4b/400

Category: Installing LinuxCNC

Hi Rod,
Thanks for creating the image. Last night I installed it and even managed to change the Linux GUI to Cinnamon. It’s easier for me to navigate with.
Over the weekend I’ll have a crack at configuring it for my Taig Mill.

Cheers
Peter

Thanks Peter, I'll be keen to hear how you get on.

Now you've made it to the dark side, how about becoming a Mesa Distributor Down under? The closest one is in NZ which is not terribly convenient.
12 Oct 2023 02:57

Ethercat installation summary

Category: EtherCAT

Ok, I'll do some reading before continuing.

As an update, it looks like I'm pretty close.
The only changes I applied so fare are to the cia402 component:
- I wait for the ECT60 to confirm homing
if (home) {
opmode = OPMODE_HOMING;
if (opmode_homing) {
controlword |= (home << 4);
}
}

- I lie with the current position to linuxcnc during homing

[code]//home states
if (opmode_homing) {
// hack
pos_fb = pos_cmd;
stat_homed = ((statusword >> 10) & 1) && ((statusword >> 12) & 1);
stat_homing = !stat_homed && !((statusword >> 10) & 1);
}


Current tested behavior is:
- I press "home all"
- joint sets cia402 home (joint.0.index-enable => cia402.0.home)
- the drive follows the homing sequence and finds the edge of the home sensor
- the drive exits the homing mode
- at that point, the next "write all" sends again the current pos_cmd and the drive moves back to the position before the homing started

I'll study homing.c - I was hoping to find a solution that didn't involve rebuilding linuxcnc (I'm running off of the 2.8.1 raspberry pi image right now).
[/code]
 

So I picked up where you left off here. I decided to ignore the following error issue and just set the following error limits to a large value and focus on the jumping after homing.

I removed the "
[code]pos_fb = pos_cmd;" and still noticed jumping. After looking at some Halscope traces it became apparent that the drive was being put back into cyclic position mode before the position register was cleared from homing. I made a small change in order of a few lines of code forcing the homing procedure in the drive to finish before setting the drive back to position mode. 
[/code]
  // OP Mode
  // set to position mode
  if (stat_voltage_enabled && !home ) {
    opmode = OPMODE_CYCLIC_POSITION;
  }
  // set velo mode
  if (stat_voltage_enabled && !pos_mode && !home) {
    opmode = OPMODE_CYCLIC_VELOCITY;
  }
 
  // reset home command  
  if (home && (stat_homed && !stat_homed_old) && opmode_homing) {
    home = 0;  
  }

This works well, and the motor no longer jumps. I then decided to make a hacky solution for the following error. I added a couple of input pins to the CIA402 component to store the standard following error parameters from the INI file, and a couple of output pins to set the current following error. The component keeps the output pins equal to the input pins except during homing. During homing the output following error pins are set to a high value, 1e38. 

Then you just connect up the following error output pins to the following error pins and result is Linuxcnc ignoring following error during homing, but not at other times without modifying the Linuxcnc code. 

you can see the example config attached. I changed the CIA402 component name to CIA402JAG just to I could do side by side comparison of the two components on my system.

What do you think? To hacky?
11 Oct 2023 21:19

Debian 12 - 2.10 master branch image for the Raspberry Pi 4b/400

Category: Installing LinuxCNC

Hi Rod,
Thanks for creating the image. Last night I installed it and even managed to change the Linux GUI to Cinnamon. It’s easier for me to navigate with.
Over the weekend I’ll have a crack at configuring it for my Taig Mill.

Cheers
Peter
11 Oct 2023 18:27

Remora - ethernet NVEM / EC300 / EC500 cnc board

Category: Computers and Hardware

Hey, Scott (or any volunteer)!

Have you had the time to look at my config files that are causing the following errors? I use the remora-nvem-basic config from github.com/scottalford75/Remora-NVEM/tree/main/LinuxCNC, also attached to this message.
Hi, I've had a look at your config files and they are identical to mine, and I can run with a 1000% feed override without following errors....

Now I'm really scratching my head to understand what could be going on. Do you have the serial debug output connected? It would be interesting to see if there are any issues on the board.
 

Let me explain exactly what I have done. Maybe you can spot something that I've done wrong.
- Full chip erase on NVEM using STM32 ST-LINK Utility
- Flash NVEM with Remora-NVEM-STM32-1.0.0.bin from github.com/scottalford75/Remora-NVEM/tree/main/Firmware using STM32 ST-LINK Utility
- Install Raspberry Pi OS (Legacy) 32 bit
- Install LinuxCNC and realtime Kernel according to forum.linuxcnc.org/9-installing-linuxcnc...n-raspberry-pi-3b-pi
- Copy github.com/scottalford75/Remora-NVEM/tre...es/remora-nvem-basic to /home/pi/linuxcnc/configs
- Copy github.com/scottalford75/Remora-NVEM/tre...Components/Remora-nv to /home/pi/linuxcnc/components
- Install remora-nv component using
sudo halcompile --install remora-nv.c
- Install pyocd using [code]pip3 install pyocd
- Write config to NVEM using [code]python3 upload_config.py config.txt

And that's it I think. Can you spot anything I might have done wrong?

I do not have the serial debug output connected, but I can do that if there is a guide I can follow. Do you happen to have one? [img]/media/kunena/emoticons/smile.png[/img]
[/code][/code]

[code][code]Ping response times are longer than I'm getting though, averaging around 0.17ms. Do you have a router in between the NVEM and computer?
 
No router. 2 meter cable directly from the Pi to the NVEM. Is the response time high enough to cause these errors you think?
[/code][/code]

As the response time becomes worse it changes the amount of pre-anticipation the linuxcnc software has to take in the algorithm hence PGain in order to make up for it. High ping time can cause ferror, but also can not having enough response time from the cpu on linuxcnc itself. I highly recommend you make sure your linuxcnc setup is correct and your following all recommendations by linuxcnc, also older kernels are slower and have worse response time in the real time kernel, so if linuxcnc has a timer thats supposed to go off every 1ms and the raspberrypi cpu timer goes off at 1.1ms and then the response time on the board is 0.3ms or up to 0.6ms now you are 1.13 to 1.16ms out of sync.
11 Oct 2023 17:07

Notes from installation of ethercat on Raspberry Pi 4

Category: EtherCAT

The video looks great! Can you let me know please what components you use in set-up: motors, drivers, motion cards, etc. I have servo motors with Ethercat. Can you recommend a motion card that may work?
Thank you!
11 Oct 2023 14:54

Remora - ethernet NVEM / EC300 / EC500 cnc board

Category: Computers and Hardware

Hey, Scott (or any volunteer)!

Have you had the time to look at my config files that are causing the following errors? I use the remora-nvem-basic config from github.com/scottalford75/Remora-NVEM/tree/main/LinuxCNC, also attached to this message.
Hi, I've had a look at your config files and they are identical to mine, and I can run with a 1000% feed override without following errors....

Now I'm really scratching my head to understand what could be going on. Do you have the serial debug output connected? It would be interesting to see if there are any issues on the board.
 

Let me explain exactly what I have done. Maybe you can spot something that I've done wrong.
- Full chip erase on NVEM using STM32 ST-LINK Utility
- Flash NVEM with Remora-NVEM-STM32-1.0.0.bin from github.com/scottalford75/Remora-NVEM/tree/main/Firmware using STM32 ST-LINK Utility
- Install Raspberry Pi OS (Legacy) 32 bit
- Install LinuxCNC and realtime Kernel according to forum.linuxcnc.org/9-installing-linuxcnc...n-raspberry-pi-3b-pi
- Copy github.com/scottalford75/Remora-NVEM/tre...es/remora-nvem-basic to /home/pi/linuxcnc/configs
- Copy github.com/scottalford75/Remora-NVEM/tre...Components/Remora-nv to /home/pi/linuxcnc/components
- Install remora-nv component using
sudo halcompile --install remora-nv.c
- Install pyocd using
pip3 install pyocd
- Write config to NVEM using
python3 upload_config.py config.txt

And that's it I think. Can you spot anything I might have done wrong?

I do not have the serial debug output connected, but I can do that if there is a guide I can follow. Do you happen to have one?

Ping response times are longer than I'm getting though, averaging around 0.17ms. Do you have a router in between the NVEM and computer?
 

No router. 2 meter cable directly from the Pi to the NVEM. Is the response time high enough to cause these errors you think?
11 Oct 2023 12:50

Debian 12 - 2.10 master branch image for the Raspberry Pi 4b/400

Category: Installing LinuxCNC

Glad you like it. The changes don't really affect the user. Originally, we built Linuxcnc master branch to get the gpio driver. But that was pushed back into 2.9 branch so that is what we build now as that will be released in the very short term.

Then there was an upgrade to the raspberry kernel which we incorporated. That is meaningless to the user.

Hopefully, the next version will be on the linuxcnc downloads page!
11 Oct 2023 11:51

Debian 12 - 2.10 master branch image for the Raspberry Pi 4b/400

Category: Installing LinuxCNC

Been running this on the bench and it's working fine. Thanks.

My only comment is that I can't see any release notes to see what has changed between the versions.

 
10 Oct 2023 12:57

Machine Limits not showing in Linuxcnc 2.8.4

Category: AXIS

Hi,
I have the same problem with Linuxcnc 2.8.4 not showing the machine limits. I have also installed a Raspberry Pi and the problem does not exist there. No solution found, so I reinstalled Linuxcnc 2.7.14.
10 Oct 2023 10:27 - 10 Oct 2023 13:09

LinuxCNC + Orange Pi (allwincnc)

Category: Computers and Hardware

[code]I hope to get some guidance on the issue regarding the ARISC driver.

I am currently adapting a new development board, which is similar to the Raspberry Pi and Orange Pi. I am not quite sure how to configure some of the settings in the `api.h` file. Where should I obtain these configuration details from in the chip's manual?


[code][code][code]#ifndef _API_H
#define _API_H

...
#define ARISC_CPU_FREQ          450000000 // Hz
#define ARISC_FW_BASE           (0x00040000) // for ARM CPU it's 0x00040000
#define ARISC_FW_SIZE           ((8+8+32)*1024)
#define ARISC_SHM_SIZE          (4096)
#define ARISC_SHM_BASE          (ARISC_FW_BASE + ARISC_FW_SIZE - ARISC_SHM_SIZE)
#define GPIO_BASE               0x01c20800
#define GPIO_R_BASE             0x01f02c00
#define GPIO_BANK_SIZE          0x24

#define GPIO_PORTS_MAX_CNT      8
#define GPIO_PINS_MAX_CNT       24
#define PWM_CH_MAX_CNT 16
#define PWM_WASTED_TICKS (160/2) // number of ARISC ticks wasted for calculations
...


static inline
void shmem_deinit(void)
{
    munmap(_shm_vrt_addr, ARISC_SHM_SIZE);
    munmap(_gpio_vrt_addr, 4096);
    munmap(_r_gpio_vrt_addr, 4096);
}

#endif


Are there any additional configuration changes needed apart from the ones mentioned above?

Thank you for your help.




06 Oct 2023 03:10

Getting an error when using gmoccapy.

Category: Installing LinuxCNC

I temporarily resolved this issue, which was caused by a configuration file error. Now, I'm facing a new problem with my development board, which has an interface similar to the Raspberry Pi's 40-pin GPIO header. I noticed the Orange Pi project from allwincnc, where they use ARISC drivers to control the 40-pin GPIO pins. However, I couldn't find any relevant usage documentation in the LinuxCNC documentation. Could you provide me with some guidance?Here is the definition of the 40-pin interface on my development board:


Displaying 1021 - 1035 out of 1062 results.
Time to create page: 1.506 seconds
Powered by Kunena Forum