Remora - ethernet NVEM / EC300 / EC500 cnc board

More
3 years 3 weeks ago #282766 by GeramyL

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
Code:
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][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.
The following user(s) said Thank You: chrstrvs

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

More
3 years 3 weeks ago - 3 years 3 weeks ago #282768 by PCW
If the step generator works like the Mesa step generator
(basically a velocity command  servo loop), you can compensate
for the time between position read and new velocity write
with the PID loops FF2 term (you set it to the time between
read and write in seconds, so if you have 100 usec between
read and write, you set FF2 to 0.0001)
Last edit: 3 years 3 weeks ago by PCW.

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

More
3 years 3 weeks ago #282775 by rbobey1989
Well guys, good news from what I have been able to test, the glitch filter works wonderfully, it filters very efficiently, but it does need adjustment according to the frequencies of channels A, B and Index and the frequency of the expected noise, these were the notes from the manual References that did the job:

• The Input Filter Sample Period (FILT_PER) should be set so that the sampling period is larger than the period of the expected noise. Doing this means that a noise spike will only corrupt one sample.
• The Input Filter Sample Count (FILT_CNT) should be chosen to reduce the probability of noisy samples causing an incorrect transition to be recognized. The probability of an incorrect transition is defined as the probability of an incorrect sample raised to the power of FILT_CNT+3.

I have left these two parameters configurable in the configuration file.

Right now the module instance in the configuration file looks like this:

{
     "Thread": "Base",
     "Type": "QDC",
         "Comment": "QDC Encoder A-IN11 B-IN12 I-IN14",
         "PV": 1,
          "Data Bit": 17.
         "ChA Pin": "P4_00",
         "ChB Pin": "P3_23",
         "Index Pin": "P4_15",
         "ENC No": 2,
         "Filter PER": 10,
         "Filter CNT": 4
},

I also have to say that my EC300 has come back to life (the white press button, haha) I pressed it for a few more seconds and bang, new EC300!!!!, so I can test the QDC module also on the EC300.

I'm going to make some commits to update changes, Github Repo , greetings.
The following user(s) said Thank You: tommylight, scotta

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

More
3 years 2 weeks ago #282789 by rbobey1989
Hello Scott, how can I read the board field from the configuration file to use it in the implementation of the Qdc module, I have tried some ideas but I can't read it, thanks in advance

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

More
3 years 2 weeks ago #282796 by GeramyL

If the step generator works like the Mesa step generator
(basically a velocity command  servo loop), you can compensate
for the time between position read and new velocity write
with the PID loops FF2 term (you set it to the time between
read and write in seconds, so if you have 100 usec between
read and write, you set FF2 to 0.0001)
I dont believe we have FF2 in the algorithm inside remora, unless FF2 is a linuxcnc variable and not remora specific? Remora Hal only has PGAIN and FF1 GAIN I believe not FF2, maybe i can look at that.

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

More
3 years 2 weeks ago - 3 years 2 weeks ago #282800 by BrysonW
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.
 
Last edit: 3 years 2 weeks ago by BrysonW.

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

Time to create page: 0.700 seconds
Powered by Kunena Forum