Results 1 to 7 of 7

Thread: Suggested reading to better understand graphical interface

  1. #1
    Newbie
    Join Date
    Aug 2008
    Location
    Woodstock, Ontario, Canada
    Posts
    8

    Suggested reading to better understand graphical interface

    Iíve been planning to use the FB for home automation. I have figured out the logic end of things I want to do & how they relate to inputs and outputs, but now it is time to put it all in action. I am having a hard time understanding some of the terms. If I could get better knowledge of what the terms mean & their relations I might be able to get to the next step easier. Any books you could suggest that will give me a ground up on what is being done here with the fusion Brain. Iíve ordered another brain to make 2 to my collection & the input output ideas are growing, but Iím stuck on the graphical interface organizing the logic due to my lack of experience with Digital logic that is probably second nature to yourselves. I just need a good book to cover the elementary objects to get a good grasp on things
    Thanx in advance. Keep up all the good work

  2. #2
    FLAC
    Join Date
    Oct 2006
    Location
    Las Vegas
    Posts
    1,286
    Radio shack had a really good book for an introduction to digital logic, I have it somewhere....
    I think this isn't it, but I think it's the predecessor to the one I have.
    http://cgi.ebay.com/ENGINEER-MINI-NO...08112012r21521

    Forrest Mims did a lot of books on electronics for radio shack, back when it wasn't a cell-phone kiosk.

    I'll look up the one I have tomorrow.

    I'm assuming that you're talking about the MDX software, and you're looking to build loops with the configurator?

    The first thing you should know is that each function you are building is a statement, that get's read in by the MDX software. With one exception, all of the statements are IF statements. They all follow the standard format IF(expression) THEN DO (something) ELSE{anti-THEN} DO (something else)

    You don't see that part when you're building the functions, the whitespace that you see is where you start writing your expression.

    Expressions can be simple, or they can be very complicated. The main goal of an expression is to produce a boolean result that is either true or false. If the result is true, then the statements that are in your "then" list get executed. That last sentence is the english equivalent of what the function does. If you need more help with that, any introductory programming book will do the job. {CODE, by Microsoft Press is a fun little book to read}.

    The THEN statements are not as flexible as the IF statement. There is a window that pops up with list-boxes allowing you to set a variable to a value or increment a variable up and down or, turn on or off outputs, and some other things. But you don't get too much custom control over that statement.

    The IF statements are where you can and should do almost anything. It's not exactly like a boolean logic diagram, but it reads very similar.

    I could go on about IF statements if you like, but it's mostly programming. So I'd pick up a book on the particular code you want to learn VB, BASIC, C, C++, C#, etc. and start there. It will probably be more useful to you than any digital logic book, in the long run. However digital logic is a good brick in that foundation. As long as the programming book is truely introductory, it will introduce you in to thinking in code. And because MDX skinning isn't truely coding, you'll be able to do many things rather quickly. I'm no code-slinger, but I feel I'm learning to express my thoughts in MDX more and more freely by the day.

    I'm guessing you have some ideas of what you want your brain to do like:

    I want my shower to turn on and automatically adjust to the pre-set temperature when my alarm clock goes off, but only if I'm in my bed and only on weekdays, and I want the temperature in the shower to vary depending on what temperature the air in the house is, and I want the A/C to turn off for a few minutes at the end so I don't shiver when I get out.

    (Sure, it would be nice if calender items like date and time were available to use for this, but they're not yet, so we'll use a digital input and find a wire in the alarm clock that goes to ground when the alarm clock is alarming).

    Turning something like that ridiculous thought into logic is something along the lines of what I think you want to be able to do easily.

    So I've planned out the inputs and sensors I want to use, and I have a cool electronically controlled shower valve I have to put in, but that's the easy part.

    Aside from the calendar stuff, it's all something you can do with the functions in MDX. And functions are a form of code, I'd get a programming book.

    "Thinking in C" was a pretty good course. I'm not sure if you can find that anymore though. There's tons of books out there though. You won't have to learn to be an expert programmer to do what you want here, not by a long shot.

    I'm sure there's some more people than just me that would jump in and try to help you through some examples you provide, so that you can get the hang of it.

    There's more, but I'll hold off.

  3. #3
    Newbie
    Join Date
    Aug 2008
    Location
    Woodstock, Ontario, Canada
    Posts
    8
    Exactly, Yes. Iíll take up the fight to Chapters (indigo) and see what is available. The graphical interface of MDX is why I started here & the fact that a lot of car enthusiasts arenít computer code writes either. Since I work on passenger elevators a lifetime, the relay logic is their, but the code isnít. Elevators have moved to MPCís & is now the ďblack Box ďfor most mechanics, this will give me an inside look, as far as career improvement goes.
    Thanx again.

  4. #4
    FLAC
    Join Date
    Oct 2006
    Location
    Las Vegas
    Posts
    1,286
    Well, if your proficient at relay logic, then building functions to support what you want will not be a far step for you. Ladder Logic was intended to make it easier for old school electricians, trained in old-style controllers, to be more comfortable in the new world of microprocessors. Ladder logic isn't available for MDX, but it is esentially the same behind the scenes. 'Or' is a parallel, 'And' is series. Some of the analog stuff doesn't apply that way... but it's just math.

    And knowing that little bit more about you, I now think you'd really enjoy CODE by Charles Petzold, Microsoft Press

  5. #5
    Fusion Brain Creator 2k1Toaster's Avatar
    Join Date
    Mar 2006
    Location
    Colorado, but Canadian!
    Posts
    10,053
    Well an AND and OR logic gate inside your CPU does essentially just that.... Except with a few transistors nanometres wide and 3 billion times a second without the clicking.

    But really they are NAND usually to make everything but that is a different story.

    It is easy once you understand it.

    AND: Both have to be true for the output to be true. I would buy a panda if it was legal and I had a bamboo forest in my backyard. If pandas are illegal to own I would not buy one regardless of whether or not I had a bamboo forest in my yard. Also I would not buy a panda if I did not have a bamboo forest in my back yard even if pandas were 100% legal to buy. Obviously if both statements are false, I would not buy a panda either.




    OR: One condition has to be true for the output to be true. I will get angry if someone steals my lawn gnome or if my TV breaks. If someone steals my lawn gnome, I will be angry. If my TV breaks, I will be angry. If someone steals my lawn gnome and my TV breaks, I will be angry. If neither happens, I will not get angry.




    NOT: Input is opposite of the output. Just like in english, I will go to the store means you are going. I will not go to the store means you dont.




    NAND: If both statements are true, output is false. Otherwise true. The house will be comfy if I get a cat nand a dog. If I have a cat, the house will be quiet. If I get a dog, the house will be quiet. If I get neither it will be quiet. If I get both, it will be chaos.





    NOR: If both inputs are false, then output is true. Otherwise output is false. I will make mash potatoes if I have neither made macaroni nor have I made lasagna. So if I have made macaroni, or have made lasagna, or have made both, I will not make mashed potatoes. If I have made neither, then I will make potatoes.




    XOR: If the inputs are the same, then the output is false. Believe it or not, there is no English phrase that you can represent this with. "Or" in english means inclusive or (up above) meaning one, the other, or both. Exclusive or means one or the other. Not both, and not either.



    Now the numerical operands, I think you know, they are just math.

    Ask if you have any questions.

    -- Nick
    Fusion Brain Version 6 Released!
    1.9in x 2.9in -- 47mm x 73mm
    30 Digital Outputs -- Directly drive a relay
    15 Analogue Inputs -- Read sensors like temperature, light, distance, acceleration, and more
    Buy now in the MP3Car.com Store

  6. #6
    Newbie
    Join Date
    Aug 2008
    Location
    Woodstock, Ontario, Canada
    Posts
    8
    I like your quote "Logic was intended to make it easier for old school electricians", and it applies here. Thanx for the explaination, it has helped. I have 3 books on order & will let all know how usefull thay are. Used from Chapters $6-$13 each & lots of them in stock should anyone else need to educate themselves. I expect them to arrive soon & I will follow up with the ISDN #'s & thier respective usefullness.

  7. #7
    Fusion Brain Creator 2k1Toaster's Avatar
    Join Date
    Mar 2006
    Location
    Colorado, but Canadian!
    Posts
    10,053
    Quote Originally Posted by Dagwood View Post
    I like your quote "Logic was intended to make it easier for old school electricians", and it applies here. Thanx for the explaination, it has helped. I have 3 books on order & will let all know how usefull thay are. Used from Chapters $6-$13 each & lots of them in stock should anyone else need to educate themselves. I expect them to arrive soon & I will follow up with the ISDN #'s & thier respective usefullness.
    Cool beans.

    I did have a typo on the NOR, I just fixed. The table was correct, but it should (and now does) read "Otherwise outputs are true."

    If you found this useful, then I will think of making this a sticky for others.
    Fusion Brain Version 6 Released!
    1.9in x 2.9in -- 47mm x 73mm
    30 Digital Outputs -- Directly drive a relay
    15 Analogue Inputs -- Read sensors like temperature, light, distance, acceleration, and more
    Buy now in the MP3Car.com Store

Similar Threads

  1. New FM USB module, maybe good for our carputers?
    By skywise in forum Road Runner
    Replies: 60
    Last Post: 01-04-2011, 08:44 PM
  2. Whats the easiest to use interface? need help
    By ultraz in forum Software & Software Development
    Replies: 1
    Last Post: 09-14-2006, 08:47 AM
  3. Help with A/C Control Interface
    By TheDeepFryedBoo in forum General MP3Car Discussion
    Replies: 2
    Last Post: 04-10-2006, 01:18 PM
  4. Help prequired for reading serial port data !!
    By tolisn in forum Road Runner
    Replies: 28
    Last Post: 07-06-2005, 04:04 PM
  5. Replies: 7
    Last Post: 07-01-2005, 03:29 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •