Knock sensing ideas and circuit designs

From DIY contraptions to sophisticated FreeEMS-specific designs! Plus general hardware development!
User avatar
AiToR51
QFP80 - Contributor
Posts: 80
Joined: Sun Aug 21, 2011 6:26 pm
Location: Spain

Re: Knock sensing ideas and circuit designs

Post by AiToR51 »

I want to work on this with FreeEMS, what do you recommend in firmware?

what I want to test:
-program by SPI at the begining the params

and then in each cycle make a read by spi
Sierra XR4i 2.0T
User avatar
russian
LQFP112 - Up with the play
Posts: 154
Joined: Fri Feb 01, 2013 4:18 pm
Location: Jersey City, USA

Re: Knock sensing ideas and circuit designs

Post by russian »

I have a hip9011 module design if anyone needs it but I do not have the time to solder & test this board :(

Image

KiCad project is available at https://svn.code.sf.net/p/rusefi/code/t ... ip9011.zip

oshpark project
User avatar
Fred
Moderator
Posts: 15431
Joined: Tue Jan 15, 2008 2:31 pm
Location: Home sweet home!
Contact:

Re: Knock sensing ideas and circuit designs

Post by Fred »

Aitor!! What do you mean "what do I recommend in firmware"? No entendido, tio :-)
DIYEFI.org - where Open Source means Open Source, and Free means Freedom
FreeEMS.org - the open source engine management system
FreeEMS dev diary and its comments thread and my turbo truck!
n00bs, do NOT PM or email tech questions! Use the forum!
The ever growing list of FreeEMS success stories!
User avatar
AiToR51
QFP80 - Contributor
Posts: 80
Joined: Sun Aug 21, 2011 6:26 pm
Location: Spain

Re: Knock sensing ideas and circuit designs

Post by AiToR51 »

:P

I wanted to ask advice about which source files do you recommend me I could modify to insert test code in order to do that things.
To the first programming should not be very hard, I've more doubts about when polling the device, as it varies with ign timing



PS: russian, your board looks good. I've to have a look to the schematics, I could be interested in one for my DIY build
Sierra XR4i 2.0T
User avatar
russian
LQFP112 - Up with the play
Posts: 154
Joined: Fri Feb 01, 2013 4:18 pm
Location: Jersey City, USA

Re: Knock sensing ideas and circuit designs

Post by russian »

It could be useful to begin with an independent test code which just establishes the connectivity and catches knock on some simulated signal before actually looking at modifying the existing firmware? Just my 2 cents.
User avatar
Fred
Moderator
Posts: 15431
Joined: Tue Jan 15, 2008 2:31 pm
Location: Home sweet home!
Contact:

Re: Knock sensing ideas and circuit designs

Post by Fred »

Ahh Iii TOR!!!

New files

knock.c
knock.h

Write the code you need to in knock.c
Place knock.h where you need to call into your knock.c functions and call into them there.

main.c
realtimeISRs.c

These are the most likely culprits for prototyping such code by calling into it.

You may want or need to have an interrupt service routine, too. If so you need to look at the other ISR files and headers and mimic that (including installing in the vector table).

Fred.
DIYEFI.org - where Open Source means Open Source, and Free means Freedom
FreeEMS.org - the open source engine management system
FreeEMS dev diary and its comments thread and my turbo truck!
n00bs, do NOT PM or email tech questions! Use the forum!
The ever growing list of FreeEMS success stories!
User avatar
AiToR51
QFP80 - Contributor
Posts: 80
Joined: Sun Aug 21, 2011 6:26 pm
Location: Spain

Re: Knock sensing ideas and circuit designs

Post by AiToR51 »

russian wrote:It could be useful to begin with an independent test code which just establishes the connectivity and catches knock on some simulated signal before actually looking at modifying the existing firmware? Just my 2 cents.
I did that with an arduino time ago. I was successful programming it and reading data through SPI. Tested it with generated frequencys by the computer's sound card..

So next is to test something similar with my FreeEMS
Sierra XR4i 2.0T
User avatar
AiToR51
QFP80 - Contributor
Posts: 80
Joined: Sun Aug 21, 2011 6:26 pm
Location: Spain

Re: Knock sensing ideas and circuit designs

Post by AiToR51 »

Fred wrote:Ahh Iii TOR!!!

New files

knock.c
knock.h

Write the code you need to in knock.c
Place knock.h where you need to call into your knock.c functions and call into them there.

main.c
realtimeISRs.c

These are the most likely culprits for prototyping such code by calling into it.

You may want or need to have an interrupt service routine, too. If so you need to look at the other ISR files and headers and mimic that (including installing in the vector table).

Fred.
Ok thanks. I will play a little with this when having free time
Sierra XR4i 2.0T
L98TPI
TO220 - Visibile
Posts: 11
Joined: Thu Aug 14, 2008 4:59 am

Re: Knock sensing ideas and circuit designs

Post by L98TPI »

Speaking of waking from the dead. Hi...
I have been doing everything but automotive stuff. I will be paying more attention here and trying to get up to speed with all the changes. I see TI still has the TPIC8101 listed as active. That is a good thing. For MCU my focus has changed to XMEGA now.

Mark
Any tool can be the right tool...
Post Reply