Miata Turbo Forum - Boost cars, acquire cats.

Miata Turbo Forum - Boost cars, acquire cats. (https://www.miataturbo.net/)
-   MEGAsquirt (https://www.miataturbo.net/megasquirt-18/)
-   -   What is port a port b & port c in MLV? (https://www.miataturbo.net/megasquirt-18/what-port-port-b-port-c-mlv-23522/)

StarGehzer 07-14-2008 01:59 PM

What is port a port b & port c in MLV?
 
What is port a port b & port c in MLV's graphs ?

Joe Perez 07-14-2008 03:05 PM

They're data registers inside the CPU chip itself. Useful for people modifying and debugging the assembly code, not of much value for the average user. At a technical level, they represent the states of the various general-purpose I/O pins on the CPU, and are expressed in the logs as binary-coded-decimal. By decoding the numerical values into raw binary, one can determine whether any particular output pin on the CPU is on or off, or whether an input pin is high or low, at any moment in time.

By looking at the datasheet for the M68HC908GP32 microprocessor, you can see that all of the I/O pins are organized into groups of 8, with each group being a port. Each port has a one byte register, with each bit representing one pin. To turn a pin on or off, you write a 1 or 0 into whichever bit of that register corresponds to the pin you want to control.

For example, the idle valve is connected to pin 34 of the CPU, which is PTA1 (port A, bit 1). So when MS wants the idle valve open, it shifts a logic 1 into the second bit position of port A (remember, they're numbered 0-7).

Braineack 07-14-2008 03:45 PM

now that this is answered....what's "bit 7: Y/N" and "bit 8: Y/N"

Joe Perez 07-14-2008 03:59 PM

According to the notes in source code, bit 7 is the !sync indicator in the tooth_decode2 subroutine. If sync is lost, then that bit goes true.

Bit 8 is a little more vague. It appears to be related to the !operational status of the TargetAFR routine, however I can't quite determine the exact logic of how it's set.

StarGehzer 07-14-2008 05:08 PM

Thanks.
That is an answer & 1/2!


All times are GMT -4. The time now is 05:53 AM.


© 2024 MH Sub I, LLC dba Internet Brands