Re: [Emc-users] Rpi 3b+ to 7i90hd

2021-01-12 Thread Ralph Stirling
I'm using the 3B+ and a tiny usb flash.  It handles unexpected power cycles 
fine, unlike the sd card.  Booting a 4B off usb is more difficult I believe, 
but my only 4B seems to be dead, so I'm progressing with the 3B+.

-- Ralph

On Jan 12, 2021 8:49 PM, Thaddeus Waldner  wrote:
CAUTION: This email originated from outside the Walla Walla University email 
system.


I’m wondering what you plan to use for flash memory on the Pi. Is the SD card a 
viable solution in this application? Would the Pi compute module with onboard 
flash memory be a workable solution?

One issue with onboard flash memory is that swapping out a pi in the case of a 
processor failure would be more difficult. Is there anything else that makes 
the compute modules a worse choice than the standard pi?

Of course this is just me wishing someone would hook up a basic MESA card with 
the Pi4 compute module headers.


> On Jan 12, 2021, at 2:33 PM, Ralph Stirling  
> wrote:
>
> Success at last!
>
> To summarize everything I've learned:
> - I was missing one ground (RPi pin 14)
> - mesaflash doesn't tell me that I have to
>  use --device 7i90, not 7i90hd.  I had to
>  look at the mesaflash source to figure that out.
> - my Fluke 179 dvm diode check does not
>   give me ~0.7v readings for fpga pins
> - I have to load the spi bit file with jtag
>
> I now have native RPi jtag using openocd
> working, so don't need the $50 Digilent
> HS2 dongle any more.  I edited the
> raspberrypi-native.cfg file to move the
> gpio pins from 11,25,10,9 to 17,27,22,5
> to avoid conflict with the 7i90's SPI pins.
>
> I will spin another version of my little adapter
> shim pcb to include the jtag header.  I'll be
> happy to share that design with the group
> when I get them back and tested.
>
> Thank you again!
> -- Ralph
>
>
>> Is there anything that needs to be done
>> differently on the RPi 3b+ to communicate
>> with the 7i90 via spi versus the 7c81?
>
> It should be identical, and AFAIK the mesaflash interface
> should be less picky since it runs at a lower clock speed
> than the default hm2-rpspi driver
>
> Are all RPI grounds connected to all 7I90 26 pin
> header grounds?
>
>
>>
>> Is the next step to cobble up some vhdl to
>> verify all the pins on the spi interface side
>> are functioning?  I suppose somewhere along
>> the line I might have blown a pin.
>
>
> If you blow a  pin, it will usually show as the
> protection diode being damaged. You can check
> this with a DVMs diode check function. Connect
> the DVMs positive lead to 7I90 ground and check
> the diode voltage drop on the SPI leads, they should
> all be ~.7V
>
>>
>
>> I'd really like to get this working, as I'm putting
>> together a standard package I can use for all
>> our custom controllers for machines and instruments.
>> Bioprinters, syringe pumps, bioreactors, routers,
>> pick & place, hotwire foam cutters.  I'm tired of
>> random castoff pc's.
>>
>> Thanks again,
>> -- Ralph
>> 
>> From: Peter C. Wallace [p...@mesanet.com]
>> Sent: Monday, January 11, 2021 4:34 PM
>> To: Enhanced Machine Controller (EMC)
>> Subject: Re: [Emc-users] Rpi 3b+ to 7i90hd
>>
>> CAUTION: This email originated from outside the Walla Walla University email 
>> system.
>>
>>
>>> On Mon, 11 Jan 2021, Ralph Stirling wrote:
>>>
>>> Date: Mon, 11 Jan 2021 23:48:56 +
>>> From: Ralph Stirling 
>>> Reply-To: "Enhanced Machine Controller (EMC)"
>>>
>>> To: "Enhanced Machine Controller (EMC)" 
>>> Subject: Re: [Emc-users] Rpi 3b+ to 7i90hd
>>>
>>> I've made a bit of progress now.  I found a Digilent HS2
>>> jtag dongle, and got to the point of (apparently) successfully
>>> loading an SPI bitstream to the 7I90 (chose 7i90_spi_svst4_8.bit).
>>>
>>> Running:
>>>
>>> $ mesaflash --device 7i90hd --addr /dev/spidev0.0 --spi --readhmid
>>>
>>> gives me the same "no 7I90HD board found" error though.  I tried
>>> adding a pullup resistor to the SDO pin, without change, which
>>> would seem to indicate the 7I90HD is actively driving it low.
>>>
>>> Is there a very simple blinky bitstream I can try loading to
>>> be sure the jtag loading is successful?  The /INIT yellow led
>>> flashes briefly, and /DONE red led does go on during the load
>>> and goes off afterward.
>>>
>>> Thanks again.
>>> -- Ralph
>>
>>
>> Theres no blinky light test bitfile but if you load the sserial
>> remote bitfile 7i90_ssremote.bit, The init LED should light once
>> configured (well 50 ms after configured indicating a watchdog timeout)
>>
>>> 
>>> From: Peter C. Wallace [p...@mesanet.com]
>>> Sent: Friday, January 8, 2021 1:22 PM
>>> To: Enhanced Machine Controller (EMC)
>>> Subject: Re: [Emc-users] Rpi 3b+ to 7i90hd
>>>
>>> CAUTION: This email originated from outside the Walla Walla University 
>>> email system.
>>>
>>>
 On Fri, 8 Jan 2021, Ralph Stirling wrote:
>>>
 Date: Fri, 8 Jan 2021 21:08:55 +
 From: Ralph Stirling 
 Reply-To: "Enhanced Machine C

Re: [Emc-users] Rpi 3b+ to 7i90hd

2021-01-12 Thread Thaddeus Waldner
I’m wondering what you plan to use for flash memory on the Pi. Is the SD card a 
viable solution in this application? Would the Pi compute module with onboard 
flash memory be a workable solution?

One issue with onboard flash memory is that swapping out a pi in the case of a 
processor failure would be more difficult. Is there anything else that makes 
the compute modules a worse choice than the standard pi?
 
Of course this is just me wishing someone would hook up a basic MESA card with 
the Pi4 compute module headers. 


> On Jan 12, 2021, at 2:33 PM, Ralph Stirling  
> wrote:
> 
> Success at last!
> 
> To summarize everything I've learned:
> - I was missing one ground (RPi pin 14)
> - mesaflash doesn't tell me that I have to 
>  use --device 7i90, not 7i90hd.  I had to
>  look at the mesaflash source to figure that out.
> - my Fluke 179 dvm diode check does not
>   give me ~0.7v readings for fpga pins
> - I have to load the spi bit file with jtag
> 
> I now have native RPi jtag using openocd
> working, so don't need the $50 Digilent
> HS2 dongle any more.  I edited the
> raspberrypi-native.cfg file to move the
> gpio pins from 11,25,10,9 to 17,27,22,5
> to avoid conflict with the 7i90's SPI pins.
> 
> I will spin another version of my little adapter
> shim pcb to include the jtag header.  I'll be
> happy to share that design with the group
> when I get them back and tested.
> 
> Thank you again!
> -- Ralph
> 
> 
>> Is there anything that needs to be done
>> differently on the RPi 3b+ to communicate
>> with the 7i90 via spi versus the 7c81?
> 
> It should be identical, and AFAIK the mesaflash interface
> should be less picky since it runs at a lower clock speed
> than the default hm2-rpspi driver
> 
> Are all RPI grounds connected to all 7I90 26 pin
> header grounds?
> 
> 
>> 
>> Is the next step to cobble up some vhdl to
>> verify all the pins on the spi interface side
>> are functioning?  I suppose somewhere along
>> the line I might have blown a pin.
> 
> 
> If you blow a  pin, it will usually show as the
> protection diode being damaged. You can check
> this with a DVMs diode check function. Connect
> the DVMs positive lead to 7I90 ground and check
> the diode voltage drop on the SPI leads, they should
> all be ~.7V
> 
>> 
> 
>> I'd really like to get this working, as I'm putting
>> together a standard package I can use for all
>> our custom controllers for machines and instruments.
>> Bioprinters, syringe pumps, bioreactors, routers,
>> pick & place, hotwire foam cutters.  I'm tired of
>> random castoff pc's.
>> 
>> Thanks again,
>> -- Ralph
>> 
>> From: Peter C. Wallace [p...@mesanet.com]
>> Sent: Monday, January 11, 2021 4:34 PM
>> To: Enhanced Machine Controller (EMC)
>> Subject: Re: [Emc-users] Rpi 3b+ to 7i90hd
>> 
>> CAUTION: This email originated from outside the Walla Walla University email 
>> system.
>> 
>> 
>>> On Mon, 11 Jan 2021, Ralph Stirling wrote:
>>> 
>>> Date: Mon, 11 Jan 2021 23:48:56 +
>>> From: Ralph Stirling 
>>> Reply-To: "Enhanced Machine Controller (EMC)"
>>>
>>> To: "Enhanced Machine Controller (EMC)" 
>>> Subject: Re: [Emc-users] Rpi 3b+ to 7i90hd
>>> 
>>> I've made a bit of progress now.  I found a Digilent HS2
>>> jtag dongle, and got to the point of (apparently) successfully
>>> loading an SPI bitstream to the 7I90 (chose 7i90_spi_svst4_8.bit).
>>> 
>>> Running:
>>> 
>>> $ mesaflash --device 7i90hd --addr /dev/spidev0.0 --spi --readhmid
>>> 
>>> gives me the same "no 7I90HD board found" error though.  I tried
>>> adding a pullup resistor to the SDO pin, without change, which
>>> would seem to indicate the 7I90HD is actively driving it low.
>>> 
>>> Is there a very simple blinky bitstream I can try loading to
>>> be sure the jtag loading is successful?  The /INIT yellow led
>>> flashes briefly, and /DONE red led does go on during the load
>>> and goes off afterward.
>>> 
>>> Thanks again.
>>> -- Ralph
>> 
>> 
>> Theres no blinky light test bitfile but if you load the sserial
>> remote bitfile 7i90_ssremote.bit, The init LED should light once
>> configured (well 50 ms after configured indicating a watchdog timeout)
>> 
>>> 
>>> From: Peter C. Wallace [p...@mesanet.com]
>>> Sent: Friday, January 8, 2021 1:22 PM
>>> To: Enhanced Machine Controller (EMC)
>>> Subject: Re: [Emc-users] Rpi 3b+ to 7i90hd
>>> 
>>> CAUTION: This email originated from outside the Walla Walla University 
>>> email system.
>>> 
>>> 
 On Fri, 8 Jan 2021, Ralph Stirling wrote:
>>> 
 Date: Fri, 8 Jan 2021 21:08:55 +
 From: Ralph Stirling 
 Reply-To: "Enhanced Machine Controller (EMC)"

 To: "Enhanced Machine Controller (EMC)" 
 Subject: Re: [Emc-users] Rpi 3b+ to 7i90hd
 
 Not having Xilinx Impact tool on the Rpi (or anywhere
 at the moment), I found a tutorial on setting up
 OpenOCD for jtag on the Rpi.  I have installed OpenOCD
 on my RPi 3B+ and connected 

Re: [Emc-users] Rpi 3b+ to 7i90hd

2021-01-12 Thread Ralph Stirling
Success at last!

To summarize everything I've learned:
- I was missing one ground (RPi pin 14)
- mesaflash doesn't tell me that I have to 
  use --device 7i90, not 7i90hd.  I had to
  look at the mesaflash source to figure that out.
- my Fluke 179 dvm diode check does not
   give me ~0.7v readings for fpga pins
- I have to load the spi bit file with jtag

I now have native RPi jtag using openocd
working, so don't need the $50 Digilent
HS2 dongle any more.  I edited the
raspberrypi-native.cfg file to move the
gpio pins from 11,25,10,9 to 17,27,22,5
to avoid conflict with the 7i90's SPI pins.

I will spin another version of my little adapter
shim pcb to include the jtag header.  I'll be
happy to share that design with the group
when I get them back and tested.

Thank you again!
-- Ralph


> Is there anything that needs to be done
> differently on the RPi 3b+ to communicate
> with the 7i90 via spi versus the 7c81?

It should be identical, and AFAIK the mesaflash interface
should be less picky since it runs at a lower clock speed
than the default hm2-rpspi driver

Are all RPI grounds connected to all 7I90 26 pin
header grounds?


>
> Is the next step to cobble up some vhdl to
> verify all the pins on the spi interface side
> are functioning?  I suppose somewhere along
> the line I might have blown a pin.


If you blow a  pin, it will usually show as the
protection diode being damaged. You can check
this with a DVMs diode check function. Connect
the DVMs positive lead to 7I90 ground and check
the diode voltage drop on the SPI leads, they should
all be ~.7V

>

> I'd really like to get this working, as I'm putting
> together a standard package I can use for all
> our custom controllers for machines and instruments.
> Bioprinters, syringe pumps, bioreactors, routers,
> pick & place, hotwire foam cutters.  I'm tired of
> random castoff pc's.
>
> Thanks again,
> -- Ralph
> 
> From: Peter C. Wallace [p...@mesanet.com]
> Sent: Monday, January 11, 2021 4:34 PM
> To: Enhanced Machine Controller (EMC)
> Subject: Re: [Emc-users] Rpi 3b+ to 7i90hd
>
> CAUTION: This email originated from outside the Walla Walla University email 
> system.
>
>
> On Mon, 11 Jan 2021, Ralph Stirling wrote:
>
>> Date: Mon, 11 Jan 2021 23:48:56 +
>> From: Ralph Stirling 
>> Reply-To: "Enhanced Machine Controller (EMC)"
>> 
>> To: "Enhanced Machine Controller (EMC)" 
>> Subject: Re: [Emc-users] Rpi 3b+ to 7i90hd
>>
>> I've made a bit of progress now.  I found a Digilent HS2
>> jtag dongle, and got to the point of (apparently) successfully
>> loading an SPI bitstream to the 7I90 (chose 7i90_spi_svst4_8.bit).
>>
>> Running:
>>
>> $ mesaflash --device 7i90hd --addr /dev/spidev0.0 --spi --readhmid
>>
>> gives me the same "no 7I90HD board found" error though.  I tried
>> adding a pullup resistor to the SDO pin, without change, which
>> would seem to indicate the 7I90HD is actively driving it low.
>>
>> Is there a very simple blinky bitstream I can try loading to
>> be sure the jtag loading is successful?  The /INIT yellow led
>> flashes briefly, and /DONE red led does go on during the load
>> and goes off afterward.
>>
>> Thanks again.
>> -- Ralph
>
>
> Theres no blinky light test bitfile but if you load the sserial
> remote bitfile 7i90_ssremote.bit, The init LED should light once
> configured (well 50 ms after configured indicating a watchdog timeout)
>
>> 
>> From: Peter C. Wallace [p...@mesanet.com]
>> Sent: Friday, January 8, 2021 1:22 PM
>> To: Enhanced Machine Controller (EMC)
>> Subject: Re: [Emc-users] Rpi 3b+ to 7i90hd
>>
>> CAUTION: This email originated from outside the Walla Walla University email 
>> system.
>>
>>
>> On Fri, 8 Jan 2021, Ralph Stirling wrote:
>>
>>> Date: Fri, 8 Jan 2021 21:08:55 +
>>> From: Ralph Stirling 
>>> Reply-To: "Enhanced Machine Controller (EMC)"
>>> 
>>> To: "Enhanced Machine Controller (EMC)" 
>>> Subject: Re: [Emc-users] Rpi 3b+ to 7i90hd
>>>
>>> Not having Xilinx Impact tool on the Rpi (or anywhere
>>> at the moment), I found a tutorial on setting up
>>> OpenOCD for jtag on the Rpi.  I have installed OpenOCD
>>> on my RPi 3B+ and connected the gpio to the JTAG pins
>>> on the 7i90HD, following this tutorial:
>>>
>>> https://nam12.safelinks.protection.outlook.com/?url=https%3A%2F%2Fmovr0.com%2F2016%2F09%2F02%2Fuse-raspberry-pi-23-as-a-jtagswd-adapter%2F&data=04%7C01%7Cralph.stirling%40wallawalla.edu%7C4feb8a1bac6e4697cd8308d8b69a8eef%7Cd958f048e43142779c8debfb75e7aa64%7C0%7C0%7C637460122239287153%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&sdata=iap%2BTsn6u%2F0IHsUt9EIMTWXTY7lyroW19dK7Ds0H8s0%3D&reserved=0
>>>
>>> The last step seems to be to make a configuration
>>> file for the target device.  The EEPROMs are WInbond
>>> 25Q16JVNIQ as best I can read the chip labels.  OpenOCD
>>> doesn't have anything that looks directly applicable.
>>> I also don't know whe

Re: [Emc-users] two requests

2021-01-12 Thread Gene Heskett
On Monday 11 January 2021 06:22:22 Gene Heskett wrote:

I have this at the moment for AXIS_A and JOINT_3 in my .ini file
#
# Axis A
#
[AXIS_A]
MAX_VELOCITY= 30.000
MAX_ACCELERATION= 500.00

[JOINT_3]
TYPE= ANGULAR
HOME= 0.0
HOME_SEQUENCE   = 3
HOME_SEARCH_VEL = 9.0
HOME_LATCH_VEL  = -1.0
HOME_FINAL_VEL  = 30
HOME_OFFSET = 4.498500
VOLATILE_HOME   = 1
FERROR  = 0.50
MIN_FERROR  = 0.25
MAX_VELOCITY= 30.000
MAX_ACCELERATION= 500.00
P   = 6000
I   = 0.500
D   = 0.500
FF0 = 0
FF1 = 21.5
FF2 = 0.55
BIAS= 0
DEADBAND= 0.00015
BACKLASH= .1
MAX_OUTPUT  = 750.
SERVO_SCALE = 666.7
PWMGEN_TYPE = 2

But as you can see, error noise is still being a problem, and the ACCEL 
is best described as leasurely, taking about 3 seconds to get to around 
850 degrees a minute.  And trying to limit the windup by restricting 
MAX_OUTPUT is making the windup very obvious, taking that same 3 seconds 
to stop after the key is released once it gets up to cruising speed.

For this same reason, I have to use very slow homing searches else it 
sails right by the switch going false for around 9 degrees and keeps on 
going forever.

The motor is pretty much doing what its being told to do by motion 
according to halscope.

Can anyone see whats wrong?

Thanks.

Cheers, Gene Heskett
-- 
"There are four boxes to be used in defense of liberty:
 soap, ballot, jury, and ammo. Please use in that order."
-Ed Howdershelt (Author)
If we desire respect for the law, we must first make the law respectable.
 - Louis D. Brandeis
Genes Web page 


___
Emc-users mailing list
Emc-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-users