Hi Seb
On 2014-05-15 16:19, Sebastian Kuzminsky wrote: > On 05/15/2014 09:58 AM, Marius Liebenberg wrote: >> Andy >> please have a look at the attached file. I took supply.c and adjusted it >> as a basis to start working from. I am trying to get a pin to toggle in >> the update function (run_i2c) but it seems to ignore my pleas. Id I can >> get this sorted then I have a good start. > I'm not Andy, but the SCL pin toggles for me: No discrimination intended here :) >> halcmd: loadrt threads >> halcmd: loadrt i2c >> halcmd: show pin i2c >> Component Pins: >> Owner Type Dir Value Name >> 9 bit OUT TRUE i2c.0.SCL >> 9 bit OUT FALSE i2c.0.SDI >> 9 bit OUT FALSE i2c.0.SDO >> >> halcmd: addf i2c.0.update thread1 >> halcmd: start >> halcmd: show pin >> Component Pins: >> Owner Type Dir Value Name >> 9 bit OUT TRUE i2c.0.SCL >> 9 bit OUT FALSE i2c.0.SDI >> 9 bit OUT FALSE i2c.0.SDO >> >> halcmd: show pin >> Component Pins: >> Owner Type Dir Value Name >> 9 bit OUT FALSE i2c.0.SCL >> 9 bit OUT FALSE i2c.0.SDI >> 9 bit OUT FALSE i2c.0.SDO >> >> halcmd: show pin >> Component Pins: >> Owner Type Dir Value Name >> 9 bit OUT TRUE i2c.0.SCL >> 9 bit OUT FALSE i2c.0.SDI >> 9 bit OUT FALSE i2c.0.SDO >> >> halcmd: I used Halscope and the output just stayed high. What happens if you look at it with Halscope? > Looks good! > > Some feedback: > > The tb variable is shared by all instances, you should use *i2c->SCL > instead of tb in the run_i2c() function (like in the commented-out code > below). The tb variable was just for the test as I did not get any reaction . My intention is to use the commented-out code. > Isn't one of the SDI/SDO pins supposed to be an input into the comp? > Yes SDI is an input pin. I am very new to this section of LCNC but I am exited to get to know it better. -- Regards /Groete Marius D. Liebenberg +27 82 698 3251 +27 12 743 6064 QQ 1767394877 ------------------------------------------------------------------------------ "Accelerate Dev Cycles with Automated Cross-Browser Testing - For FREE Instantly run your Selenium tests across 300+ browser/OS combos. Get unparalleled scalability from the best Selenium testing platform available Simple to use. Nothing to install. Get started now for free." http://p.sf.net/sfu/SauceLabs _______________________________________________ Emc-developers mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/emc-developers
