Page 18 of 23 FirstFirst ... 891011121314151617181920212223 LastLast
Results 171 to 180 of 223

Thread: Beginning of an Automatic Climate Control System, all juiced up on Fusion

  1. #171
    FLAC
    Join Date
    Oct 2006
    Location
    Las Vegas
    Posts
    1,286
    I'm stumped.

    With time on my hands and roadblocks in the way, I went for the one way I thought would still do the job. Without the grace of custom function nodes, and fancy math, I just named the range for each bit, 2 functions per bit, one for on conditions and one for off conditions. It worked on my last approach, when fewer (26) bit combinations were required and the mistake of not accounting for all real numbers in the range was made.

    Here are three examples out of the 12 root functions I made, to give a visual reference.







    You can tell when it get's down to the alternating status of the LSB, things get tight. There was no way I could have done that in the configurator (in a days time and my available monitor space) so pretty much all of these 12 loops were built in xml, but tested in the configurator.

    So how does it run in MDX?
    The ouputs have the audacity to flicker and not even come close to the conditions perscribed by the 12 controlling root functions.

    Am I overloading FCC?

    Did I make a mistake in the code?

    Are there some simple fixes behind the scene in the code, that would fix all of these "problems" I am experiencing?

    Stay tuned!!!</saturday morning superhero cartoon suspenseful narration>

    I know this is either not related to the topic for many, and too related for others, and I am sorry, but these are the necessary and simple baby-steps required to get this going. And my hopes are that now that MDX is getting put to the fire, it will come out of this a better, more complete, and bulletproof package. I just didn't time my efforts very well with the designer's free time, I know. Patience is a virtue!

  2. #172
    FLAC
    Join Date
    Oct 2006
    Location
    Las Vegas
    Posts
    1,286
    Oh and here is my configuration file for the initial testing of the DAC bit outputs.
    FusionConfiguration.xml

  3. #173
    FLAC
    Join Date
    Oct 2006
    Location
    Las Vegas
    Posts
    1,286
    My mistake, ths method works well, I just had the wrong variable in each root function in the beginning.

    This method works for setting up bits to drive a DAC. I'll use it for all three dials.

    It does take up a lot of room in the skin file, the configurator takes a little while to load it to say the least. But it works, it's bulky, but it works. If a better way comes along, I will use it.

    Ok, now to finish this, set up my 0-100% variables on top of the 0-63 ones, build functions to restrict the controlling variables based on things like voltages for minimum fan speed, and voltages for discrete modes.

    And then controlling buttons and variables for recirc, Compressor-on, and defogger.

    Then I have to finishing my functions for my own sensors (Humidity, OEM temp, etc.) bringing those variables alive.

    I more polished HVAC control page to test everything in manual. And then for the fun stuff!!!

  4. #174
    FLAC
    Join Date
    Oct 2006
    Location
    Las Vegas
    Posts
    1,286
    I am in the market for a 4 channel rail to rail IO 5V opamp that goes up to 4.85V(output), if anyone knows of one. Mine (MCP609-I/P)appearantly only goes up to 4.75V. 14-DIP

    I am using a 1070(ouput to inverting) and 6810(inverting to common) ohm resitor on each channel for feedback. Is that what is limiting me?

    Edit:Looks like I need to reduce my Rg from 6810 to around 5760 (maybe a 33K in parallel). The datasheet says it's not limiting (the spec'd mV from rail is not what I'm seeing). Yep, I'm definately no expert.

  5. #175
    Fusion Brain Creator 2k1Toaster's Avatar
    Join Date
    Mar 2006
    Location
    Colorado, but Canadian!
    Posts
    10,053
    Well I read through, and I had a big post all ready to give suggestions on problems, but then it works!

    Anyways, one useful one, might be to make the logic timer something like 5000 so it takes 5 seconds between iterations of logic. That way in the debugging prompt you can see what is going on instead of the flickering. It is what I do if something isnt working correctly. Or just push pause in the debugger, but you cant really do that

    And just some things to note. When you do a <variable type="set"... type of thing, the variable is changed to that value absolutely and immediately at that set. So 2 in a row of variable = -3 and then variable = 5, the variable will be -3 (remember works from inside out, so first it sets to 5, then to -3 and then it hits to root or something). However, if you have these in the "then" area so it is <then><do set variable = -3><do set variable = 5>..., these are votes. These values are not commited to the variable until the next logic iteration where it sums all votes. And what happens is the variable will become the average of all votes of the highest set priority. So variable = variable + (vote[A] + vote[B] + vote[C] +...)/num_of_votes so if variable was 0, it is now (5 + -3)/2 = 1.

    So be careful where you use which. They come in handy at different times.

    I have to be in class in less than 8 hours, so I am going to bed.

    But it looks like you got it working, just in huge code Correct me if I am wrong
    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. #176
    FLAC
    Join Date
    Oct 2006
    Location
    Las Vegas
    Posts
    1,286
    Quote Originally Posted by 2k1Toaster View Post
    Well I read through, and I had a big post all ready to give suggestions on problems, but then it works!

    Anyways, one useful one, might be to make the logic timer something like 5000 so it takes 5 seconds between iterations of logic. That way in the debugging prompt you can see what is going on instead of the flickering. It is what I do if something isnt working correctly. Or just push pause in the debugger, but you cant really do that

    And just some things to note. When you do a <variable type="set"... type of thing, the variable is changed to that value absolutely and immediately at that set. So 2 in a row of variable = -3 and then variable = 5, the variable will be -3 (remember works from inside out, so first it sets to 5, then to -3 and then it hits to root or something). However, if you have these in the "then" area so it is <then><do set variable = -3><do set variable = 5>..., these are votes. These values are not commited to the variable until the next logic iteration where it sums all votes. And what happens is the variable will become the average of all votes of the highest set priority. So variable = variable + (vote[A] + vote[B] + vote[C] +...)/num_of_votes so if variable was 0, it is now (5 + -3)/2 = 1.

    So be careful where you use which. They come in handy at different times.

    I have to be in class in less than 8 hours, so I am going to bed.

    But it looks like you got it working, just in huge code Correct me if I am wrong
    Nope that's about where things are at.

    I'll have to give more thought to what you're saying about when variables are set, from within a function, and in the then statement. But it looks pretty clear, I just have to absorb it. Thanks for taking the time, I know you are busy.

    I'll be in a similar boat, come this spring.

  7. #177
    FLAC
    Join Date
    Oct 2006
    Location
    Las Vegas
    Posts
    1,286
    Ok, I have Analog outputs!!! It's been a long time.



    I need to get a few resistors to bump up the gain on my opamps tomorrow, before I start recording voltages for each step. As I stated before, The voltages the softtware sees are a bit off from the real voltages, so I can't go off what the screen says. But since it is consistant, if I keep things straight, it won't matter.

    A company called Calsonic Kansei makes a lot of the parts for Nissan vehicles, including the HVAC control head. And it appears they could have done a better job. When I push one of the buttons for recirc, compressor-on, or defog, the voltage at the sweep of the potentiometers swings from .05 to .25 volts (it's highest when the pot is at the mid-position. Looks like P/S loading. Well, if it works... But having a computer interface will amplify this wide margin a bit.

    Time to calibrate the sensors.

  8. #178
    FLAC
    Join Date
    Oct 2006
    Location
    Las Vegas
    Posts
    1,286
    I would like exponent & natural logrithm functions. But I'll do my best in the meantime.



    I've got to do something equivalent to using this:

    R2=Vinput*2200/5-Vinput

    and then

    Temp= -43.65*ln(R2)+412.73

    Edit:

    I suppose this will be accurate enough... I just used the resultant voltages and made a curve, a 3rd order polynomial follws the curve nicely, but I just don't think it will matter.


  9. #179
    Fusion Brain Creator 2k1Toaster's Avatar
    Join Date
    Mar 2006
    Location
    Colorado, but Canadian!
    Posts
    10,053
    Polynomials can approximate any curve with enough of them

    3 is easy enough.
    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

  10. #180
    FLAC
    Join Date
    Oct 2006
    Location
    Las Vegas
    Posts
    1,286
    Yeah, I realized I can just use several references to the same input or variable and the multiply function to do what I want.

    I'm seeing that my analog inputs on my last remaining old-style brain are catching at certain values, like the adc bits in the MCU are hanging up it consistantly stops at 2.5 and 3.75 volts. I can watch it go with the simple 3 pin pot, from 3.10 (ok), 3.11 (ok), and all of a sudden at 3.12Volts, the brain goes to 3.75V. I think I need to get another fancy color coded brain.

    My other voltage problems with the new brain are soething else, and I'm hunting it down now. But the ADC problem just isn't going to cut it. Look for my order soon.

Similar Threads

  1. AIMEE Climate Control POLL
    By Danceheaven in forum Software & Software Development
    Replies: 25
    Last Post: 01-14-2010, 09:38 AM
  2. Replies: 85
    Last Post: 07-09-2007, 04:44 AM
  3. Digital dash and climate control???
    By yamathegreat in forum General Hardware Discussion
    Replies: 3
    Last Post: 10-31-2005, 04:41 PM
  4. System control wire on amp
    By dudah85 in forum General Hardware Discussion
    Replies: 3
    Last Post: 09-13-2001, 08:09 AM
  5. Replies: 22
    Last Post: 08-13-2001, 01:42 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
  •