Note: This version (UG ver2011) of user guide applies to devices with orginal (year 2011) software. If you have updated the software to latest version, use User guide which applies to latest software. --- Connectors1. +12V power input 2. (-) GND (both ground terminals are internally connected together) 3. Start-up input 4. +5V power output 5. Analog input 1 6. Analog input 2 7. Analog input 3 8. Analog input 4 9. Analog input 5 10. Analog input 6 11. Analog input 7 12. Analog input 8 13. Digital input 1 14. Digital input 2 15. VR-reference input (reserved for future use) 16. (-) GND (both ground terminals are internally connected together) --- Initial setup Minimal connection to operate the device is 12V power supply. Connect 12V power supply to the terminals: + = battery + terminal GND = battery - terminal, or clean chassis ground. It is preferred to take the supply from the 12V battery using separate wires or other 'clean' power supply. An 1A fuse in the battery end of the positive supply (in series) is recommended to protect the wiring. The device has an internal protection for electronics and 5V output, but higher than 100mA load from the output can cause false analog input readings. Note: Install RaceDAC as close as you can to the receiving device (mobilephone/PC/laptop/etc). To maximise RF-signal quality; leave ~50 mm space between RaceDAC and any flat metal surface. These are common BlueTooth and RF related issues, not just RaceDAC specific issues. Also, install RaceDAC; the side with the screws facing down; because then BT-antenna is facing upwards. --- Power supply input protection Power supply input has a voltage protection circuit against electrostatic discharges or other voltage spikes. Continuous high positive (higher than 16 V) or any negative input voltages (lower than -0.5 V) may cause internal fuse operation, device malfunction or even failure if very high voltage is applied. Internal fuse is a thermal type (PTC) and it is rated to 0.5A. If the fuse is 'blown', device power supply is internally kept disconnected until the failure cause is removed. It is also recommended to disconnect the power supply and let the fuse to cool down (min. 15 sec.) before reconnection and restart. --- On/Off-pushbutton Press On/Off-pushbutton gently (for approx 1 second) to start the device. --- Start-up input 12V signal connected to this input starts the RaceDAC. When signal is removed or level is low, RaceDAC will go off. On/Off-pushbutton is disabled when start-up signal is on. This enables that the RaceDAC can be placed more freely and operated with a remote switch, which gives 12V signal to the RaceDAC start-up terminal. --- Automatic start-up Automatic start-up can be enabled with a jumper inside the RaceDAC enclosure: Automatic start-up -jumper Then the device goes automatically on when the main 12V power supply is available. --- 5 V Power output 5 V / 100 mA output is available for external sensors or devices. Output is internally regulated and it has approximately 2.5ohm source impedance. If 100 mA is drawn from the output, voltage level may drop to 4.75 V. Shorting the output or taking too much current may cause device malfunction (short current spikes) or 'blowing' the internal fuse (longer period of overcurrent). --- Dip-switches Analog input range is selected using dip-switches on the printed circuit board. If the switch is ON, 0-5V range is selected. When the switch is OFF, input range is 0-15V. --- Analog inputs Analog inputs have two ranges of operation: Factory calibrated 0-5V input range and uncalibrated 0-15V range. Analog input impedance is about 106 kohm with 0-5 V range and about 320 kohm with 0-15V range. This high impedance makes the device sensitive to externally coupled noise. Keep the input wiring as short as possible and far from possible noise sources (spark plugs, ignition coils, fuel injectors, relays etc.). It is also recommended that the sensor source impedance is less than 1000 ohm. All unused analog input channels can be connected to one of the ground terminals to prevent noise at the output. It is preferred that user adjusts the channel output readings using u.offset, u.gain and u.divisor parameters. --- Analog input protection All analog inputs have separate input voltage protection circuits against electrostatic discharges or other voltage spikes. Continuous high positive (higher than 16 V) or any negative input voltages (lower than -0.5 V) may cause false output readings, other device malfunction or even failure. --- Digital inputs RaceDAC device has two digital inputs that are internally matched to 0-5 to 0-15V digital signal ranges. Operation mode 0 = RPM measurement Time period between successive rising input edges is measured using high frequency counter and result is converted to RPM value. Operation mode 1 = Frequency measurement Operation is about the same as in RPM measurement, now the time period is converted to Hz value and the result is multiplied by 10. Frequency resolution is then 0.1Hz. Output reading 1000 means frequency 100.0 Hz. Operation mode 2 = Impulse counter Each edge is counted, overflow to 0 after 65535. Operation mode 3 = Digital status input Digital input pin status is read directly In operation modes 0 and 1, user can change the reading range using u.offset, u.gain and u.divisor parameters. For example, if an external sensor gives 4 impulses per one engine rotation, u.divisor can be set to 4 to compensate the sensor output. --- Digital input protection Digital inputs have similar protection circuits as analog inputs. Input impedance is lower than in analog inputs, about 20kohm but inputs are still sensitive to noise spikes or other transients. In rpm, Hz and counter modes, inputs are rising edge sensitive, and in status mode input status is read directly from the input terminal. --- Start-up To start-up the device: Use On/Off-pushbutton, or 12V start-up signal, or Automatic start-up. Red led near the button will go on (indicating that the internal 3.3V power supply is on). Initially, both bluetooth leds start to blink, and after the module is initialised, only the second led from left is blinking. Then the device goes to firmware update mode for a while (user can configure the wait time for firmware update). The third led is on during the firmware update time. After the firmware update time has passed, third led goes off and bluetooth link leds start to blink again. After few seconds, the third led should begin blinking with rather high frequency indicating that the main software loop is running. Total RaceDAC start-up time is less than 10 seconds (plus the user configurable firmware update wait time, see firmware update chapter for further info). --- Stand-by Press on/off button gently (3 sec.). All indicator leds will go off and when you stop pressing the button, the device will go to stand-by. Or if you are using start-up input signal; when signal level is low, the device will go to stand-by. --- Initial connection PC with bluetooth connectivity and a terminal program is needed for configuration. At first, PC and RaceDAC bluetooth devices must be paired with default pin-code 1234. Then PC will install serial port device drivers, and after a while, it informs usually one or two serial port numbers that can be used to connect to the RaceDAC: For example "COM4", or "COM4" and "COM5". If two COM-ports are given, use the one with smaller number, in this case "COM4", to communicate with RaceDAC. Open terminal program. (See Links for alternative Client/Terminal SW's) For example: By default Windows XP PC has a sw called HyperTerminal (Click: Start - Programs - Accesories - Communications - HyperTerminal) The first time HyperTerminal is started; it asks for a phonenumber; input anything, it is not needed, it is just a happy windows -feature on the first run. Then give any name and icon for connection, and click "Ok" Connect using the COM-port which window installed for RaceDAC, for example COM4. (You may have to disconnect "the call" first before you are allowed to check the parameters. Click "Disconnect"-icon, or choose "Call" - "Disconnect" ) Set communication parameters to: - 115200Bd - 8data - 1stop - No parity - No handshake - Port "COM4" (or whatever you got at the device driver installation phase) Open the connection (Click "Call"-icon, or choose "Call" - "Call"; and HyperTerminal will connect to RaceDAC by using port COM4). and you should see data stream coming from the RaceDAC device to the terminal program screen ($RC1... or $RC2... message lines). --- CMD-mode Now you can enter to cmd-mode by writing letters: CMD into the terminal window and pressing enter. Note that there is no echo ("CMD" is not displayed on the screen) at this phase of communication. So just write the letters and press enter. Entering to the cmd-mode is indicated by a reply string: "RaceDac cmd mode" and the data acquisition is stopped. Now you can send configuration commands (press enter after each command). Note that there is no line edit function in the command interpreter: So if you type something wrong or give wrong parameter value, you must press enter and rewrite the whole command. --- Commands Enter to cmd mode: CMD Enter to data acquisition mode: DAC Read firmware id: ID Read factory parameters: FRx where x is analog input channel number returns f.offset, f.gain and f.divisor values Read user parameters: URx where x is channel number; 1...8 for analog channels 1...8, and 9...10 for digital channels 1...2 returns u.offset, u.gain, u.divisor, u.min, u.max and averaging mode values Clear user parameters UCLEAR clears all user parameters, and sets all values to default values. See User adjustment part for default values. --- Memory map: 0 Program startup counter, incremented automatically after each device startup 1 Output message format: 1=RC1, 2=RC2, other=RC2 2 Message output frequency; allowed values: 1, 2, 5, 10, 20, 50 and 100 (Hz) requires hw reset to be effective 3 Message baudrate: 0 = 115200, 1 = 57600, 2 = 38400, 3 = 19200, 4 = 9600 limits also automatically highest message frequency to 100, 50, 50, 20 and 10Hz respectively 4 Digital input 1 mode: 0=rpm, 1=Hz, 2=count, 3=status 5 Digital input 2 mode: 0=rpm, 1=Hz, 2=count, 3=status 6 Digital input timeout value, N*0.4seconds 7..30 reserved for future use 31 Firmware upload wait time --- Memory map: Factory calibration parameters 32..39 factory calibration f.offset values for analog channels 1...8 40..47 factory calibration f.gain values for analog channels 1...8 48..55 factory calibration f.divisor values for analog channels 1...8 56..63 reserved --- Memory map: User parameter area 64..71 user offset adjustment values for 8 analog channels (u.offset) 72..73 user offset adjustment values for 2 digital channels (u.offset) 74..81 user gain adjustment values for analog channels (u.gain) 82..83 user gain adjustment values for digital channels (u.gain) 84..91 user divisor adjustment values for analog channels (u.divisor) 92..93 user divisor adjustment values for digital channels (u.divisor) 94..101 reserved for user averaging modes for analog channels 102..103 user averaging modes for digital channels: 0= no average ( result=new measurement in each cycle), 1= simple rc type average ( result=(oldresult+new)/2), 2= average of 2 measurements (result=(new+previous)/2) 104..111 user max output limit values for analog channels (u.max) 112..113 user max output limit values for digital channels (u.max) 114..121 user min output limit values for analog channels (u.min) 122..123 user min output limit values for digital channels (u.min) 104..255 reserved for future use --- EEPROM read: ERx x is memory location 0..255 (see the Memory map above) Returns unsigned integer from eeprom memory. Note that optional negative values are converted to 38768...65535 (-32768...-1) Example: "ER4" will reply to you "Eeprom addr 4:0" indicating that; Digital input channel 1 mode is 0 = RPM --- EEPROM write: EWx,y x is memory location 0..255 (see the Memory map) (, is comma) y is data value as unsigned int 0...65535 Note that if you want to write negative values, they must be converted manually into the range 32768...65535 (-32768...-1) Example1: "EW1,1" will reply to you "Eeprom addr 1=1" indicating that you changed the output format to "$RC1" Example2: "EW2,1" will reply to you "Eeprom addr 2=1" indicating that you changed the Message output frequency to 1(Hz) --- Raw analog read: RAx where x is Analog channel number Example: RA4 will give raw, uncalibrated conversion result from Analog channel 4 --- Calibrated analog read: CAx where x is Analog channel number Example: CA6 will give result after calibration and user configuration from Analog channel 6 --- Extra analog read: XAx 1 = gnd reference 2 = 3v3 supply / 2 = 3700 3 = 1/11*12V supply = 2500 --- Factory calibration NOTE: Do not change the EEPROM factory calibration parameters unless you are absolutely sure what you are doing. For input range adjustment, use user parameter area in the EEPROM (see the Memory map/ User adjustment part below). 12-bit A/D conversion output range gives output values ranging from 0 to 4095. Analog channels have an individual internal offset and some gain variation that are compensated with factory calibration parameters. Factory calibration offset adjustment range: -512...+512 (f.offset) Factory calibration gain multiplier range: -32768...+32767 (f.gain) Factory calibration gain divisor range: 1...+32767 (f.divisor) Calculation formula: calibrated result = [ ( raw value - f.offset ) * f.gain] / f.divisor Calculation is made using long integer values but the result is truncated to 16- bit unsigned integer. The user must take care of the result overflow if improper parameter values are used. Analog channel specific calibration parameters are stored in the EEPROM memory. By default, 0-5V input range is factory calibrated to output value range 0- 5000. Default parameters are same for each analog channel: f.offset 0 f.gain 12210 (=5000*10000/4095) f.divisor 10000 Default parameters are changed during factory calibration and saved into the following EEPROM memory locations: 32..39 f.offset values for analog channels 1..8 40..47 f.gain values for analog channels 1..8 48..55 f.divisor values for analog channels 1..8 --- User adjustment User can change analog and digital channel output range using; user offset, gain, divisor, and min and max parameters. User adjustment offset adjustment range: -8192...+8192 (u.offset) User adjustment gain multiplier range: -32768...+32767 (u.gain) User adjustment gain divisor range: 1...+32767 (u.divisor) User adjustment min range: 0...+32767 (u.min) User adjustment max range: 0...+32767 (u.max) Calculation formula: Output result = [(calibrated value - u.offset ) * u.gain] / u.divisor if output result is more than u.max ; output result = u.max if output result is less than u.min ; output result = u.min Default parameters for all analog channels are: User offset: 0 User gain: 5 User divisor: 5 User min: 0 User max: 32767 User averaging mode: 0 (= No) Default parameters for both digital channels are: User offset: 0 User gain: 1 User divisor: 1 User min: 0 User max: 32767 User averaging mode: 0 (= No) User parameters are stored in the following EEPROM memory locations: 64..71 u.offset values for analog channels 1..8 72..73 u.offset values for digital channels 1..2 74..81 u.gain values for analog channels 1..8 82..83 u.gain values for digital channels 1..2 84..91 u.divisor values for analog channels 1..8 92..93 u.divisor values for digital channels 1..2 Example1: If you want to use 15V input range for channel 1: You must change the dip switch 1 to "OFF" position and change the u.gain parameter for analog channel 1 to 15. Command is: EW74,15 Example2: If you want to divide digital input 1 rpm result by 4 (sensor is giving 4 pulses per one engine cycle), you can change the u.divisor parameter to 4. Command is: EW92,4 --- Firmware update wait time Set firmware update wait time: FWUWx x = firmware update wait time in seconds Min. value is 0 (sec) Max. value is 60 (sec) Read firmware update wait time: FWUR returns firmware update time value --- Firmware update RaceDAC has an internal firmware update function. Immediately after device reset or initial power up, factory programmed bootloader function reads expansion pin status between pins 1 and 2: If they are shorted with a jumper, RaceDAC stays in the bootloader mode where it waits for the commands from firmware update program (PC terminal application). New firmware must be compatible with the bootloader or else the next firmware update cycle is not possible. If the jumper is not installed, firmware waits for the update commands according to the firmware update wait time parameter and jumps then to the previously loaded application firmware. This wait time allows firmware update even without the jumper installation. If user has configured wait time to 0, and there is no jumper, RaceDAC starts directly. --- Firmware update procedure: 1) Disconnect 12V power supply. 2) If firmware update wait time parameter is long enough, jumper is not needed. If you want to use jumper: Open RaceDAC enclosure and install jumper: Firmware-update-jumper 3) Connect power supply and start up the RaceDAC. 4) Go to the PC and locate your bluetooth serial port that is already paired with the RaceDAC (for example COM6), or do the pairing. 5) Locate FlashRDAC.exe software and put new firmwarename.hex -file in the same directory. For example; Make "rdac"-folder in your c:-drive root, and put FlashRDAC.exe and firmwarename.hex files to that folder. 6) Open windows command prompt: Click "Start" - "Run..." Write "cmd" and click "Ok". In command prompt window, go to your rdac -folder: For example write "cd c:\rdac" and press enter. Run FlashRDAC.exe with filename and -i -option for bluetooth communication port, for example: FlashRDAC firmwarename.hex -iCOM6 7) FlashRDAC software prints messages during firmware download. If it finds an error, an "Assertion failed" or other message is generated indicating the source of the error and the program is terminated. For example if the communication port is reserved for another program. 8) After succesful update: Disconnect power, remove jumper (if present) and close the enclosure. 9) Connect power supply. 10) Test the new software. Note: You may need to change some eeprom parameters before and/or after the new firmware is loaded. See firmware specific update notes. RaceDAC