View Single Post
Old 02-01-2017, 07:25 PM   #76 (permalink)
skybolt
deviant
 
Join Date: Oct 2016
Location: Seattle, WA
Posts: 69

s2k - '02 Honda s2000
Thanks: 12
Thanked 47 Times in 35 Posts
Thumbs up

Quote:
Is the pi code failing to properly interpret any <BR> or CRLF combination within the quotes?
The d3.js library strips any characters it doesn't like from the text field, as it applies all HTML tags itself. (This is probably to keep people from breaking it by inserting custom tags). The d3.v3.min.js is about 7800 lines of code, so I've been putting off trying to pull it apart and understand its whitelist/blacklist approach. The main issue is 'subtitle' is a single field, and it only assigns HTML tags outside of fields. Reasonable, but it doesn't help us.

Quote:
I am wondering if you could use I2C ...
Not knowing what I2C is, I looked it up. Ah, now I see where you're headed. No, it's not a one-to-many (or one-to-two) issue. The Arduino already accepts uploads via the serial port which as far as I can tell is the same whether it's connected via FTDI or just a wire. I looked up programming the Arduino over the Rx port and it has to do with boot time - the first .n or N seconds after boot (configurable, I think and coded into the each bootloader), the Arduino bootloader will look for an incoming sketch. (This is only true if you have not deployed a sketch via ISP, which overwrites the bootloader). The trick is to programmatically send the RST pin a LOW as the first part of the upload process, OR hit the Arduino reset button like a monkey and hope you get the timing right). Now that I have a pi/duino combo in the car I have an incentive to explore this, as I could simply use dropbox to sync source code, then use the Arduino IDE to deploy directly from the car. No wires, not even a laptop required.

Quote:
MPGuino reads the signal from only one injector for an engine, but modern port fuel injection engines have one injector per cylinder. The numberOfInjectors parameter tells MPGuino to account for that in its calculation of usec/gallon.
I see, that makes sense. I am glad that you alter the value in the displayed uSec, it made it easier to understand what was going on.

So, ... if I understand correctly, injector size and pressure must be for fuel use by pure calculation rather than tuning by observation, trial and error. I've noticed that changing # of cylinders alters the uSec saved value, but this doesn't extend to injector size, injector delay and fuel pressure. If I modify injector size and fuel pressure, shouldn't it change the saved value in uSec? Perhaps it has and I haven't noticed. If I have injectors set to 1, and change uSec to value N, and leave injector size at 246, should I expect to have it change fuel pressure to reflect the change in uSec? If so, your calculations must get a bit ... involved. Perhaps changing injector size/pressure overwrites uSec but manually setting uSec in essence overrides size/pressure?

Quote:
What version are you using?
0116. I try and use your most recent code base unless I'm working on any changes (like I am know with the JSON output), and even then if my modified code just drops in place I'd move to the newer version. I assume I can send you a modified copy of your code and you can easily do a diff to see what's changed. Let me know if it's not the case. I'm trying to follow your conventions and comment styles to make it easier for you to deal with.


In other news, I've tested my old modified Meelis code (on a Meelis mpguino) back-to-back with your 0116 code on an 8MHz Pro Mini attached to a raspi prototype board. It's ugly, but it's one piece. uSec, pulses per mile and injector delay were set the same.

Results were identical!

I intend to move to the new code base in the car as soon as I can cobble together a second prototype shield. Parameter programming is easy, I made a pro-mini to LCD harness, with buttons. Reset is trivial since I view resets directly on the Pi screen, so I remove the LCD harness once it's been configured, leaving only the buttons.
  Reply With Quote
The Following User Says Thank You to skybolt For This Useful Post:
t vago (02-02-2017)