7i43 on EPP strange behavior I can't understand

More
03 Apr 2011 10:51 #8413 by kostas
I tried testing a MESA Electronics 7i43-U-4 board I just got, but I get a strange behavior I can't understand ..

probe_parport, hostmot2 and hm2_7i43 modules load ok, on board LEDs DONE & INIT shut off and everything seems fine. I connect an oscilloscope to one of the pins and give some "setp" commands that I think should change the state of the pin but nothing happens. All pins are always in ON (3.3V) state, no matter what I do. I also tried enabling some of the PWM pins and give them a 0.5 value, but with no results.

Tested it in two different computers, same behavior. Tried with USB power as well as an external 5V power supply.

hm2_7i43 module gets loaded like this:

"loadrt hm2_7i43 config="firmware=hm2/7i43/SVST4_4B.BIT" debug_epp=1"

I tried debug_epp=1 thinking I would see something useful in the logs, but nothing happens after firmware loading. Last lines I see are these:

...
...
Apr 3 12:57:44 emc2small kernel: [ 1377.792492] hm2_7i43: selected address 0x9000
Apr 3 12:57:44 emc2small kernel: [ 1377.792504] hm2_7i43: wrote data 0x00000000
Apr 3 12:57:44 emc2small kernel: [ 1377.792515] hm2_7i43: wrote data 0x00000000
Apr 3 12:57:44 emc2small kernel: [ 1377.792523] hm2_7i43: read status 0xFE
Apr 3 12:57:44 emc2small kernel: [ 1377.792533] hm2_7i43: selected address 0xC000
Apr 3 12:57:44 emc2small kernel: [ 1377.792544] hm2_7i43: wrote data 0x00000000
Apr 3 12:57:44 emc2small kernel: [ 1377.792555] hm2_7i43: wrote data 0x00000000
Apr 3 12:57:44 emc2small kernel: [ 1377.792567] hm2_7i43: wrote data 0x00000000
Apr 3 12:57:44 emc2small kernel: [ 1377.792578] hm2_7i43: wrote data 0x00000000
Apr 3 12:57:44 emc2small kernel: [ 1377.792585] hm2_7i43: read status 0xFE
Apr 3 12:57:44 emc2small kernel: [ 1377.792595] hm2_7i43: selected address 0xA000
Apr 3 12:57:44 emc2small kernel: [ 1377.792607] hm2_7i43: wrote data 0x00000000
Apr 3 12:57:44 emc2small kernel: [ 1377.792618] hm2_7i43: wrote data 0x00000000
Apr 3 12:57:44 emc2small kernel: [ 1377.792629] hm2_7i43: wrote data 0x00000000
Apr 3 12:57:44 emc2small kernel: [ 1377.792640] hm2_7i43: wrote data 0x00000000
Apr 3 12:57:44 emc2small kernel: [ 1377.792648] hm2_7i43: read status 0xFE
Apr 3 12:57:44 emc2small kernel: [ 1377.792656] hm2/hm2_7i43.0: 48 I/O Pins used:
Apr 3 12:57:44 emc2small kernel: [ 1377.792669] hm2/hm2_7i43.0: IO Pin 000 (P4-01): Encoder #1, pin B (Input)
Apr 3 12:57:44 emc2small kernel: [ 1377.792682] hm2/hm2_7i43.0: IO Pin 001 (P4-03): Encoder #1, pin A (Input)
Apr 3 12:57:44 emc2small kernel: [ 1377.792694] hm2/hm2_7i43.0: IO Pin 002 (P4-05): Encoder #0, pin B (Input)
Apr 3 12:57:44 emc2small kernel: [ 1377.792707] hm2/hm2_7i43.0: IO Pin 003 (P4-07): Encoder #0, pin A (Input)
Apr 3 12:57:44 emc2small kernel: [ 1377.792720] hm2/hm2_7i43.0: IO Pin 004 (P4-09): Encoder #1, pin Index (Input)
Apr 3 12:57:44 emc2small kernel: [ 1377.792733] hm2/hm2_7i43.0: IO Pin 005 (P4-11): Encoder #0, pin Index (Input)
Apr 3 12:57:44 emc2small kernel: [ 1377.792746] hm2/hm2_7i43.0: IO Pin 006 (P4-13): PWMGen #1, pin Out0 (PWM or Up) (Output)
Apr 3 12:57:44 emc2small kernel: [ 1377.792760] hm2/hm2_7i43.0: IO Pin 007 (P4-15): PWMGen #0, pin Out0 (PWM or Up) (Output)
Apr 3 12:57:44 emc2small kernel: [ 1377.792774] hm2/hm2_7i43.0: IO Pin 008 (P4-17): PWMGen #1, pin Out1 (Dir or Down) (Output)
Apr 3 12:57:44 emc2small kernel: [ 1377.792787] hm2/hm2_7i43.0: IO Pin 009 (P4-19): PWMGen #0, pin Out1 (Dir or Down) (Output)
Apr 3 12:57:44 emc2small kernel: [ 1377.792801] hm2/hm2_7i43.0: IO Pin 010 (P4-21): PWMGen #1, pin Not-Enable (Output)
Apr 3 12:57:44 emc2small kernel: [ 1377.792814] hm2/hm2_7i43.0: IO Pin 011 (P4-23): PWMGen #0, pin Not-Enable (Output)
Apr 3 12:57:44 emc2small kernel: [ 1377.792827] hm2/hm2_7i43.0: IO Pin 012 (P4-25): Encoder #3, pin B (Input)
Apr 3 12:57:44 emc2small kernel: [ 1377.792840] hm2/hm2_7i43.0: IO Pin 013 (P4-27): Encoder #3, pin A (Input)
Apr 3 12:57:44 emc2small kernel: [ 1377.792853] hm2/hm2_7i43.0: IO Pin 014 (P4-29): Encoder #2, pin B (Input)
Apr 3 12:57:44 emc2small kernel: [ 1377.792865] hm2/hm2_7i43.0: IO Pin 015 (P4-31): Encoder #2, pin A (Input)
Apr 3 12:57:44 emc2small kernel: [ 1377.792878] hm2/hm2_7i43.0: IO Pin 016 (P4-33): Encoder #3, pin Index (Input)
Apr 3 12:57:44 emc2small kernel: [ 1377.792891] hm2/hm2_7i43.0: IO Pin 017 (P4-35): Encoder #2, pin Index (Input)
Apr 3 12:57:44 emc2small kernel: [ 1377.792904] hm2/hm2_7i43.0: IO Pin 018 (P4-37): PWMGen #3, pin Out0 (PWM or Up) (Output)
Apr 3 12:57:44 emc2small kernel: [ 1377.792918] hm2/hm2_7i43.0: IO Pin 019 (P4-39): PWMGen #2, pin Out0 (PWM or Up) (Output)
Apr 3 12:57:44 emc2small kernel: [ 1377.792932] hm2/hm2_7i43.0: IO Pin 020 (P4-41): PWMGen #3, pin Out1 (Dir or Down) (Output)
Apr 3 12:57:44 emc2small kernel: [ 1377.792946] hm2/hm2_7i43.0: IO Pin 021 (P4-43): PWMGen #2, pin Out1 (Dir or Down) (Output)
Apr 3 12:57:44 emc2small kernel: [ 1377.792959] hm2/hm2_7i43.0: IO Pin 022 (P4-45): PWMGen #3, pin Not-Enable (Output)
Apr 3 12:57:44 emc2small kernel: [ 1377.792973] hm2/hm2_7i43.0: IO Pin 023 (P4-47): PWMGen #2, pin Not-Enable (Output)
Apr 3 12:57:44 emc2small kernel: [ 1377.792986] hm2/hm2_7i43.0: IO Pin 024 (P3-01): StepGen #0, pin Step (Output)
Apr 3 12:57:44 emc2small kernel: [ 1377.792999] hm2/hm2_7i43.0: IO Pin 025 (P3-03): StepGen #0, pin Direction (Output)
Apr 3 12:57:44 emc2small kernel: [ 1377.793010] hm2/hm2_7i43.0: IO Pin 026 (P3-05): IOPort
Apr 3 12:57:44 emc2small kernel: [ 1377.793020] hm2/hm2_7i43.0: IO Pin 027 (P3-07): IOPort
Apr 3 12:57:44 emc2small kernel: [ 1377.793030] hm2/hm2_7i43.0: IO Pin 028 (P3-09): IOPort
Apr 3 12:57:44 emc2small kernel: [ 1377.793040] hm2/hm2_7i43.0: IO Pin 029 (P3-11): IOPort
Apr 3 12:57:44 emc2small kernel: [ 1377.793052] hm2/hm2_7i43.0: IO Pin 030 (P3-13): StepGen #1, pin Step (Output)
Apr 3 12:57:44 emc2small kernel: [ 1377.793065] hm2/hm2_7i43.0: IO Pin 031 (P3-15): StepGen #1, pin Direction (Output)
Apr 3 12:57:44 emc2small kernel: [ 1377.793076] hm2/hm2_7i43.0: IO Pin 032 (P3-17): IOPort
Apr 3 12:57:44 emc2small kernel: [ 1377.793086] hm2/hm2_7i43.0: IO Pin 033 (P3-19): IOPort
Apr 3 12:57:44 emc2small kernel: [ 1377.793096] hm2/hm2_7i43.0: IO Pin 034 (P3-21): IOPort
Apr 3 12:57:44 emc2small kernel: [ 1377.793106] hm2/hm2_7i43.0: IO Pin 035 (P3-23): IOPort
Apr 3 12:57:44 emc2small kernel: [ 1377.793118] hm2/hm2_7i43.0: IO Pin 036 (P3-25): StepGen #2, pin Step (Output)
Apr 3 12:57:44 emc2small kernel: [ 1377.793131] hm2/hm2_7i43.0: IO Pin 037 (P3-27): StepGen #2, pin Direction (Output)
Apr 3 12:57:44 emc2small kernel: [ 1377.793142] hm2/hm2_7i43.0: IO Pin 038 (P3-29): IOPort
Apr 3 12:57:44 emc2small kernel: [ 1377.793152] hm2/hm2_7i43.0: IO Pin 039 (P3-31): IOPort
Apr 3 12:57:44 emc2small kernel: [ 1377.793162] hm2/hm2_7i43.0: IO Pin 040 (P3-33): IOPort
Apr 3 12:57:44 emc2small kernel: [ 1377.793172] hm2/hm2_7i43.0: IO Pin 041 (P3-35): IOPort
Apr 3 12:57:44 emc2small kernel: [ 1377.793184] hm2/hm2_7i43.0: IO Pin 042 (P3-37): StepGen #3, pin Step (Output)
Apr 3 12:57:44 emc2small kernel: [ 1377.793197] hm2/hm2_7i43.0: IO Pin 043 (P3-39): StepGen #3, pin Direction (Output)
Apr 3 12:57:44 emc2small kernel: [ 1377.793208] hm2/hm2_7i43.0: IO Pin 044 (P3-41): IOPort
Apr 3 12:57:44 emc2small kernel: [ 1377.793218] hm2/hm2_7i43.0: IO Pin 045 (P3-43): IOPort
Apr 3 12:57:44 emc2small kernel: [ 1377.793228] hm2/hm2_7i43.0: IO Pin 046 (P3-45): IOPort
Apr 3 12:57:44 emc2small kernel: [ 1377.793238] hm2/hm2_7i43.0: IO Pin 047 (P3-47): IOPort
Apr 3 12:57:44 emc2small kernel: [ 1377.793319] hm2/hm2_7i43.0: registered
Apr 3 12:57:44 emc2small kernel: [ 1377.793329] hm2_7i43.0: board at (ioaddr=0x0378, ioaddr_hi=0x0778, epp_wide ON) found

I guess I should see more of the debug_epp lines after changing pins states?

Versions are Ubuntu 10.04 with EMC 2.4.6 from the latest live CD and I have all the latest packages.

board jumper positions are:

W1: up
W2: up
W3: down (tried setting it up and all that changed was that all pins go to ON state before firmware upload, after that nothing changes)
W4, W5: down
W6: up or down, depending on the 5V supply source.
W7: up

Any ideas will be greatly appreciated!

Thanks in advance,
Kostas

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

More
03 Apr 2011 14:26 #8415 by PCW
Do the standard 7I43 HM2 sample hal/ini files work? It may be something as simple as improper watchdog setup/feeding (this will result in all pins being inputs, pulled up to 3.3V)

Also the debug addresses look a little weird, but I'm not sure what the A000, C000 etc mean. They certainly dont match the EPP port address (0x378)

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

More
03 Apr 2011 22:16 #8427 by andypugh
PCW wrote:

Do the standard 7I43 HM2 sample hal/ini files work? It may be something as simple as improper watchdog setup/feeding


What is the status of the hm2_7i43.0.watchdog.has-bit pin?

Do you have the realtime threads started, and the hm2_7i43.0.read and .write functions added to the threads?

If you are starting the card from the command line with Halrun it is easy to forget those steps.

loadrt threads
addf hm2_7i43.0.read thread1
addf hm2_7i43.0.write thread1
addf hm2_7i43.0.pet-watchdog thread1
start

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

More
04 Apr 2011 07:59 #8446 by kostas
Ok, now I'm feeling very stupid. You're right! I didn't add read and write functions to any threads! I don't think I'll ever forget this from now on!

Thanks!

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

More
04 Apr 2011 10:43 #8455 by andypugh
kostas wrote:

Ok, now I'm feeling very stupid. You're right! I didn't add read and write functions to any threads! I don't think I'll ever forget this from now on!


Oh, you will :-) I still forget rather regularly.

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

Moderators: PCWjmelson
Time to create page: 0.081 seconds
Powered by Kunena Forum