Welcome, Guest. Please login or register.
Did you miss your activation email?
May 24, 2012, 06:09:06 PM

Login with username, password and session length
Search:     Advanced search
* Home Help Search Calendar Links Login Register
+  Machsupport Forum
|-+  Mach Discussion
| |-+  Brains Development
| | |-+  My Brain Needs Help!!!
Pages: 1   Go Down
Print
Author Topic: My Brain Needs Help!!!  (Read 1190 times)
0 Members and 1 Guest are viewing this topic.
fourxfour2
Active Member

Offline Offline

Posts: 36


View Profile
« on: June 01, 2009, 01:54:22 AM »

I'm using a Pokeys analog input and while going threw a voltage divider it is very unstable..so what kind of code can one write to calm it down a little or other words buffer it.
Thanks for the help
Dave....
Logged
poppabear
S S SYSTEMS, LLC
Global Moderator
*
Offline Offline

Posts: 1,707


Briceville, TN, USA


View Profile WWW
« Reply #1 on: June 01, 2009, 10:50:28 AM »

In your case if I understand what your wanting to do, it may be easier to set up a DeadBand in the Macro pump for that input. First Map your MODBUS127 to a User DRO.

Brian = Mod127->noop->UDRO1500

Then in Macro pump: (for a 10 point dead band on a scale of 0-100, band in the middle)

AnaIN = GetUserDRO(1500)

if AnaIN < 55 and AnaIn > 45 Then
MyDeadbandValue = 50
SetUserDRO(1501, MyDeadbandValue) 'this could also be an OEM DRO if it is one that allows writing to it
else
SetUserDRO(1501, AnaIN)
end if

scott
Logged

Commercial Mach3: Screens (regular and flash), Wizards, Plug-ins, Brains, PLCs, Macros, ATC's, machine build, retrofit and Prototyping
http://sites.google.com/site/volunteerfablab/
fourxfour2
Active Member

Offline Offline

Posts: 36


View Profile
« Reply #2 on: June 02, 2009, 03:58:43 AM »

Thanks for the reply Scot,
A little more on what I'm doing...I'm using Matts DTHC concept with a Pokeys and to say at the least it works quite well
my only problem is (after talking to Bois) is that I must be getting noise though the usb cable....just enough to be annoying...I tried just about everything to fix it...so this is were I asked about buffering the signal...Yes I am using the brains that Matt wrote, they seem to work much better than mine..(as I am new to the brain thing)...and now I guess I will figure out the macro pump thing....if its VB then I will be really lost...any good threads on this.....can it done in a brain?.
After talking to Matt this might be a good thing to know in the future!!!!! ( to be added to a plug in Smiley
Thanks for your help!!!!
Dave
Logged
Pages: 1   Go Up
Print
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.16 | SMF © 2011, Simple Machines Valid XHTML 1.0! Valid CSS!